LIEF: Library to Instrument Executable Formats Version 0.17.0
Loading...
Searching...
No Matches
arm/registers.hpp
Go to the documentation of this file.
1/* Copyright 2022 - 2024 R. Thomas
2 *
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15#ifndef LIEF_ASM_ARM_REGISTER_H
16#define LIEF_ASM_ARM_REGISTER_H
17namespace LIEF {
18namespace assembly {
19namespace arm {
20enum class REG;
21const char* get_register_name(REG r);
22
23enum class REG {
25 APSR = 1,
27 CPSR = 3,
29 FPCXTS = 5,
30 FPEXC = 6,
31 FPINST = 7,
32 FPSCR = 8,
35 FPSID = 11,
36 ITSTATE = 12,
37 LR = 13,
38 PC = 14,
40 SP = 16,
41 SPSR = 17,
42 VPR = 18,
43 ZR = 19,
44 D0 = 20,
45 D1 = 21,
46 D2 = 22,
47 D3 = 23,
48 D4 = 24,
49 D5 = 25,
50 D6 = 26,
51 D7 = 27,
52 D8 = 28,
53 D9 = 29,
54 D10 = 30,
55 D11 = 31,
56 D12 = 32,
57 D13 = 33,
58 D14 = 34,
59 D15 = 35,
60 D16 = 36,
61 D17 = 37,
62 D18 = 38,
63 D19 = 39,
64 D20 = 40,
65 D21 = 41,
66 D22 = 42,
67 D23 = 43,
68 D24 = 44,
69 D25 = 45,
70 D26 = 46,
71 D27 = 47,
72 D28 = 48,
73 D29 = 49,
74 D30 = 50,
75 D31 = 51,
76 FPINST2 = 52,
77 MVFR0 = 53,
78 MVFR1 = 54,
79 MVFR2 = 55,
80 P0 = 56,
81 Q0 = 57,
82 Q1 = 58,
83 Q2 = 59,
84 Q3 = 60,
85 Q4 = 61,
86 Q5 = 62,
87 Q6 = 63,
88 Q7 = 64,
89 Q8 = 65,
90 Q9 = 66,
91 Q10 = 67,
92 Q11 = 68,
93 Q12 = 69,
94 Q13 = 70,
95 Q14 = 71,
96 Q15 = 72,
97 R0 = 73,
98 R1 = 74,
99 R2 = 75,
100 R3 = 76,
101 R4 = 77,
102 R5 = 78,
103 R6 = 79,
104 R7 = 80,
105 R8 = 81,
106 R9 = 82,
107 R10 = 83,
108 R11 = 84,
109 R12 = 85,
110 S0 = 86,
111 S1 = 87,
112 S2 = 88,
113 S3 = 89,
114 S4 = 90,
115 S5 = 91,
116 S6 = 92,
117 S7 = 93,
118 S8 = 94,
119 S9 = 95,
120 S10 = 96,
121 S11 = 97,
122 S12 = 98,
123 S13 = 99,
124 S14 = 100,
125 S15 = 101,
126 S16 = 102,
127 S17 = 103,
128 S18 = 104,
129 S19 = 105,
130 S20 = 106,
131 S21 = 107,
132 S22 = 108,
133 S23 = 109,
134 S24 = 110,
135 S25 = 111,
136 S26 = 112,
137 S27 = 113,
138 S28 = 114,
139 S29 = 115,
140 S30 = 116,
141 S31 = 117,
142 D0_D2 = 118,
143 D1_D3 = 119,
144 D2_D4 = 120,
145 D3_D5 = 121,
146 D4_D6 = 122,
147 D5_D7 = 123,
148 D6_D8 = 124,
149 D7_D9 = 125,
150 D8_D10 = 126,
151 D9_D11 = 127,
152 D10_D12 = 128,
153 D11_D13 = 129,
154 D12_D14 = 130,
155 D13_D15 = 131,
156 D14_D16 = 132,
157 D15_D17 = 133,
158 D16_D18 = 134,
159 D17_D19 = 135,
160 D18_D20 = 136,
161 D19_D21 = 137,
162 D20_D22 = 138,
163 D21_D23 = 139,
164 D22_D24 = 140,
165 D23_D25 = 141,
166 D24_D26 = 142,
167 D25_D27 = 143,
168 D26_D28 = 144,
169 D27_D29 = 145,
170 D28_D30 = 146,
171 D29_D31 = 147,
172 Q0_Q1 = 148,
173 Q1_Q2 = 149,
174 Q2_Q3 = 150,
175 Q3_Q4 = 151,
176 Q4_Q5 = 152,
177 Q5_Q6 = 153,
178 Q6_Q7 = 154,
179 Q7_Q8 = 155,
180 Q8_Q9 = 156,
181 Q9_Q10 = 157,
182 Q10_Q11 = 158,
183 Q11_Q12 = 159,
184 Q12_Q13 = 160,
185 Q13_Q14 = 161,
186 Q14_Q15 = 162,
200 R0_R1 = 176,
201 R2_R3 = 177,
202 R4_R5 = 178,
203 R6_R7 = 179,
204 R8_R9 = 180,
205 R10_R11 = 181,
206 R12_SP = 182,
207 D0_D1_D2 = 183,
208 D1_D2_D3 = 184,
209 D2_D3_D4 = 185,
210 D3_D4_D5 = 186,
211 D4_D5_D6 = 187,
212 D5_D6_D7 = 188,
213 D6_D7_D8 = 189,
214 D7_D8_D9 = 190,
237 D0_D2_D4 = 213,
238 D1_D3_D5 = 214,
239 D2_D4_D6 = 215,
240 D3_D5_D7 = 216,
241 D4_D6_D8 = 217,
242 D5_D7_D9 = 218,
291 D1_D2 = 267,
292 D3_D4 = 268,
293 D5_D6 = 269,
294 D7_D8 = 270,
295 D9_D10 = 271,
296 D11_D12 = 272,
297 D13_D14 = 273,
298 D15_D16 = 274,
299 D17_D18 = 275,
300 D19_D20 = 276,
301 D21_D22 = 277,
302 D23_D24 = 278,
303 D25_D26 = 279,
304 D27_D28 = 280,
305 D29_D30 = 281,
321};
322
323}
324}
325}
326#endif
ARM architecture-related namespace.
Definition arm/Instruction.hpp:25
const char * get_register_name(REG r)
REG
Definition arm/registers.hpp:23
@ D21
Definition arm/registers.hpp:65
@ D5_D7
Definition arm/registers.hpp:147
@ MVFR0
Definition arm/registers.hpp:77
@ D26_D28
Definition arm/registers.hpp:168
@ D17_D18_D19
Definition arm/registers.hpp:224
@ Q10
Definition arm/registers.hpp:91
@ FPSID
Definition arm/registers.hpp:35
@ D21_D22_D23
Definition arm/registers.hpp:228
@ D18_D19_D20
Definition arm/registers.hpp:225
@ Q2_Q3_Q4_Q5
Definition arm/registers.hpp:189
@ D16_D18_D20
Definition arm/registers.hpp:253
@ D0_D2
Definition arm/registers.hpp:142
@ D14_D16
Definition arm/registers.hpp:156
@ D16_D18_D20_D22
Definition arm/registers.hpp:281
@ FPSCR_NZCV
Definition arm/registers.hpp:33
@ D8_D10_D12_D14
Definition arm/registers.hpp:273
@ D15
Definition arm/registers.hpp:59
@ D9_D10_D11
Definition arm/registers.hpp:216
@ D27_D28_D29_D30
Definition arm/registers.hpp:319
@ S12
Definition arm/registers.hpp:122
@ D11_D13
Definition arm/registers.hpp:153
@ D0
Definition arm/registers.hpp:44
@ D25_D27
Definition arm/registers.hpp:167
@ D17_D18_D19_D20
Definition arm/registers.hpp:314
@ D7_D8_D9_D10
Definition arm/registers.hpp:309
@ D13_D15_D17
Definition arm/registers.hpp:250
@ D10_D11_D12
Definition arm/registers.hpp:217
@ Q10_Q11_Q12_Q13
Definition arm/registers.hpp:197
@ D19_D20_D21_D22
Definition arm/registers.hpp:315
@ Q9_Q10_Q11_Q12
Definition arm/registers.hpp:196
@ D20_D21_D22
Definition arm/registers.hpp:227
@ D11_D12
Definition arm/registers.hpp:296
@ R12
Definition arm/registers.hpp:109
@ P0
Definition arm/registers.hpp:80
@ D29
Definition arm/registers.hpp:73
@ Q11_Q12
Definition arm/registers.hpp:183
@ D18
Definition arm/registers.hpp:62
@ Q8
Definition arm/registers.hpp:89
@ D24_D26
Definition arm/registers.hpp:166
@ APSR_NZCV
Definition arm/registers.hpp:26
@ Q1_Q2
Definition arm/registers.hpp:173
@ D17_D19_D21_D23
Definition arm/registers.hpp:282
@ D19_D21
Definition arm/registers.hpp:161
@ D4
Definition arm/registers.hpp:48
@ S10
Definition arm/registers.hpp:120
@ R0
Definition arm/registers.hpp:97
@ D17
Definition arm/registers.hpp:61
@ S23
Definition arm/registers.hpp:133
@ D7_D9_D11
Definition arm/registers.hpp:244
@ ITSTATE
Definition arm/registers.hpp:36
@ D3_D4_D5_D6
Definition arm/registers.hpp:307
@ CPSR
Definition arm/registers.hpp:27
@ D17_D18
Definition arm/registers.hpp:299
@ D7_D8_D9
Definition arm/registers.hpp:214
@ D11_D12_D13_D14
Definition arm/registers.hpp:311
@ R10
Definition arm/registers.hpp:107
@ D22_D24_D26
Definition arm/registers.hpp:259
@ D5_D6_D7
Definition arm/registers.hpp:212
@ D5_D6
Definition arm/registers.hpp:293
@ D30
Definition arm/registers.hpp:74
@ Q13_Q14
Definition arm/registers.hpp:185
@ R12_SP
Definition arm/registers.hpp:206
@ D16_D18
Definition arm/registers.hpp:158
@ Q6_Q7_Q8_Q9
Definition arm/registers.hpp:193
@ D22_D24
Definition arm/registers.hpp:164
@ FPINST
Definition arm/registers.hpp:31
@ D4_D5_D6
Definition arm/registers.hpp:211
@ Q2
Definition arm/registers.hpp:83
@ NUM_TARGET_REGS
Definition arm/registers.hpp:320
@ D3_D4
Definition arm/registers.hpp:292
@ S19
Definition arm/registers.hpp:129
@ D4_D6_D8
Definition arm/registers.hpp:241
@ D0_D2_D4_D6
Definition arm/registers.hpp:265
@ D1_D2_D3_D4
Definition arm/registers.hpp:306
@ S26
Definition arm/registers.hpp:136
@ D19_D21_D23
Definition arm/registers.hpp:256
@ D14_D16_D18_D20
Definition arm/registers.hpp:279
@ D7_D9_D11_D13
Definition arm/registers.hpp:272
@ Q1_Q2_Q3_Q4
Definition arm/registers.hpp:188
@ R6_R7
Definition arm/registers.hpp:203
@ S27
Definition arm/registers.hpp:137
@ FPSCR_NZCVQC
Definition arm/registers.hpp:34
@ D1
Definition arm/registers.hpp:45
@ SPSR
Definition arm/registers.hpp:41
@ D5_D7_D9
Definition arm/registers.hpp:242
@ D4_D6
Definition arm/registers.hpp:146
@ Q3
Definition arm/registers.hpp:84
@ ZR
Definition arm/registers.hpp:43
@ RA_AUTH_CODE
Definition arm/registers.hpp:39
@ Q7
Definition arm/registers.hpp:88
@ D2_D4
Definition arm/registers.hpp:144
@ D6_D8_D10_D12
Definition arm/registers.hpp:271
@ D19
Definition arm/registers.hpp:63
@ D21_D22
Definition arm/registers.hpp:301
@ D22
Definition arm/registers.hpp:66
@ R2_R3
Definition arm/registers.hpp:201
@ Q15
Definition arm/registers.hpp:96
@ D23_D25
Definition arm/registers.hpp:165
@ Q0_Q1
Definition arm/registers.hpp:172
@ D13_D14
Definition arm/registers.hpp:297
@ S7
Definition arm/registers.hpp:117
@ D12_D14_D16
Definition arm/registers.hpp:249
@ D7_D9
Definition arm/registers.hpp:149
@ R3
Definition arm/registers.hpp:100
@ D10_D12_D14_D16
Definition arm/registers.hpp:275
@ D13_D15_D17_D19
Definition arm/registers.hpp:278
@ Q4_Q5_Q6_Q7
Definition arm/registers.hpp:191
@ D8_D10_D12
Definition arm/registers.hpp:245
@ D0_D1_D2
Definition arm/registers.hpp:207
@ D3_D5_D7_D9
Definition arm/registers.hpp:268
@ D13_D14_D15
Definition arm/registers.hpp:220
@ D6_D8_D10
Definition arm/registers.hpp:243
@ D25_D26
Definition arm/registers.hpp:303
@ R8_R9
Definition arm/registers.hpp:204
@ D21_D23_D25_D27
Definition arm/registers.hpp:286
@ Q11_Q12_Q13_Q14
Definition arm/registers.hpp:198
@ D17_D19
Definition arm/registers.hpp:159
@ D24_D25_D26
Definition arm/registers.hpp:231
@ D9_D10
Definition arm/registers.hpp:295
@ SP
Definition arm/registers.hpp:40
@ D28_D30
Definition arm/registers.hpp:170
@ S1
Definition arm/registers.hpp:111
@ Q12
Definition arm/registers.hpp:93
@ S13
Definition arm/registers.hpp:123
@ Q12_Q13
Definition arm/registers.hpp:184
@ S31
Definition arm/registers.hpp:141
@ S16
Definition arm/registers.hpp:126
@ Q2_Q3
Definition arm/registers.hpp:174
@ Q9_Q10
Definition arm/registers.hpp:181
@ D16
Definition arm/registers.hpp:60
@ D25_D26_D27
Definition arm/registers.hpp:232
@ D31
Definition arm/registers.hpp:75
@ S15
Definition arm/registers.hpp:125
@ S22
Definition arm/registers.hpp:132
@ D12
Definition arm/registers.hpp:56
@ D10
Definition arm/registers.hpp:54
@ D27
Definition arm/registers.hpp:71
@ D10_D12
Definition arm/registers.hpp:152
@ D20_D22_D24
Definition arm/registers.hpp:257
@ S5
Definition arm/registers.hpp:115
@ D5_D6_D7_D8
Definition arm/registers.hpp:308
@ Q7_Q8
Definition arm/registers.hpp:179
@ S21
Definition arm/registers.hpp:131
@ D3_D4_D5
Definition arm/registers.hpp:210
@ D9_D11_D13_D15
Definition arm/registers.hpp:274
@ S11
Definition arm/registers.hpp:121
@ D25
Definition arm/registers.hpp:69
@ R11
Definition arm/registers.hpp:108
@ D7_D8
Definition arm/registers.hpp:294
@ Q7_Q8_Q9_Q10
Definition arm/registers.hpp:194
@ FPCXTNS
Definition arm/registers.hpp:28
@ R4
Definition arm/registers.hpp:101
@ D8_D9_D10
Definition arm/registers.hpp:215
@ Q5
Definition arm/registers.hpp:86
@ Q1
Definition arm/registers.hpp:82
@ PC
Definition arm/registers.hpp:38
@ D4_D6_D8_D10
Definition arm/registers.hpp:269
@ D14_D15_D16
Definition arm/registers.hpp:221
@ FPCXTS
Definition arm/registers.hpp:29
@ R2
Definition arm/registers.hpp:99
@ D23_D25_D27_D29
Definition arm/registers.hpp:288
@ D15_D16_D17_D18
Definition arm/registers.hpp:313
@ R9
Definition arm/registers.hpp:106
@ D8_D10
Definition arm/registers.hpp:150
@ D15_D17_D19
Definition arm/registers.hpp:252
@ D18_D20_D22
Definition arm/registers.hpp:255
@ LR
Definition arm/registers.hpp:37
@ D29_D30
Definition arm/registers.hpp:305
@ D7
Definition arm/registers.hpp:51
@ S25
Definition arm/registers.hpp:135
@ D12_D14
Definition arm/registers.hpp:154
@ D23_D25_D27
Definition arm/registers.hpp:260
@ VPR
Definition arm/registers.hpp:42
@ Q4
Definition arm/registers.hpp:85
@ D27_D29_D31
Definition arm/registers.hpp:264
@ D26_D27_D28
Definition arm/registers.hpp:233
@ D0_D2_D4
Definition arm/registers.hpp:237
@ R4_R5
Definition arm/registers.hpp:202
@ D21_D23
Definition arm/registers.hpp:163
@ Q8_Q9_Q10_Q11
Definition arm/registers.hpp:195
@ D6_D8
Definition arm/registers.hpp:148
@ D20_D22
Definition arm/registers.hpp:162
@ S24
Definition arm/registers.hpp:134
@ Q8_Q9
Definition arm/registers.hpp:180
@ MVFR1
Definition arm/registers.hpp:78
@ S6
Definition arm/registers.hpp:116
@ D12_D13_D14
Definition arm/registers.hpp:219
@ Q9
Definition arm/registers.hpp:90
@ D1_D2_D3
Definition arm/registers.hpp:208
@ D3
Definition arm/registers.hpp:47
@ D22_D23_D24
Definition arm/registers.hpp:229
@ D23_D24_D25_D26
Definition arm/registers.hpp:317
@ Q5_Q6_Q7_Q8
Definition arm/registers.hpp:192
@ D29_D31
Definition arm/registers.hpp:171
@ Q12_Q13_Q14_Q15
Definition arm/registers.hpp:199
@ S29
Definition arm/registers.hpp:139
@ D17_D19_D21
Definition arm/registers.hpp:254
@ D1_D3_D5_D7
Definition arm/registers.hpp:266
@ S20
Definition arm/registers.hpp:130
@ D24
Definition arm/registers.hpp:68
@ D25_D27_D29
Definition arm/registers.hpp:262
@ D24_D26_D28_D30
Definition arm/registers.hpp:289
@ D23
Definition arm/registers.hpp:67
@ D15_D16
Definition arm/registers.hpp:298
@ D3_D5_D7
Definition arm/registers.hpp:240
@ D9
Definition arm/registers.hpp:53
@ R10_R11
Definition arm/registers.hpp:205
@ D16_D17_D18
Definition arm/registers.hpp:223
@ S8
Definition arm/registers.hpp:118
@ NoRegister
Definition arm/registers.hpp:24
@ D9_D11_D13
Definition arm/registers.hpp:246
@ D11_D13_D15_D17
Definition arm/registers.hpp:276
@ D8
Definition arm/registers.hpp:52
@ Q14
Definition arm/registers.hpp:95
@ D28
Definition arm/registers.hpp:72
@ D28_D29_D30
Definition arm/registers.hpp:235
@ Q11
Definition arm/registers.hpp:92
@ Q5_Q6
Definition arm/registers.hpp:177
@ D15_D16_D17
Definition arm/registers.hpp:222
@ D14
Definition arm/registers.hpp:58
@ R7
Definition arm/registers.hpp:104
@ S2
Definition arm/registers.hpp:112
@ D26_D28_D30
Definition arm/registers.hpp:263
@ R0_R1
Definition arm/registers.hpp:200
@ D25_D26_D27_D28
Definition arm/registers.hpp:318
@ D13
Definition arm/registers.hpp:57
@ D1_D3_D5
Definition arm/registers.hpp:238
@ D14_D16_D18
Definition arm/registers.hpp:251
@ D1_D2
Definition arm/registers.hpp:291
@ D11
Definition arm/registers.hpp:55
@ D22_D24_D26_D28
Definition arm/registers.hpp:287
@ S30
Definition arm/registers.hpp:140
@ Q4_Q5
Definition arm/registers.hpp:176
@ D15_D17_D19_D21
Definition arm/registers.hpp:280
@ D2
Definition arm/registers.hpp:46
@ D19_D20_D21
Definition arm/registers.hpp:226
@ MVFR2
Definition arm/registers.hpp:79
@ S28
Definition arm/registers.hpp:138
@ Q3_Q4
Definition arm/registers.hpp:175
@ D11_D12_D13
Definition arm/registers.hpp:218
@ D19_D21_D23_D25
Definition arm/registers.hpp:284
@ D19_D20
Definition arm/registers.hpp:300
@ FPSCR
Definition arm/registers.hpp:32
@ D15_D17
Definition arm/registers.hpp:157
@ R1
Definition arm/registers.hpp:98
@ D27_D28_D29
Definition arm/registers.hpp:234
@ D26
Definition arm/registers.hpp:70
@ D25_D27_D29_D31
Definition arm/registers.hpp:290
@ R8
Definition arm/registers.hpp:105
@ D2_D3_D4
Definition arm/registers.hpp:209
@ D3_D5
Definition arm/registers.hpp:145
@ FPINST2
Definition arm/registers.hpp:76
@ Q6_Q7
Definition arm/registers.hpp:178
@ S4
Definition arm/registers.hpp:114
@ D1_D3
Definition arm/registers.hpp:143
@ D21_D23_D25
Definition arm/registers.hpp:258
@ Q0_Q1_Q2_Q3
Definition arm/registers.hpp:187
@ D9_D10_D11_D12
Definition arm/registers.hpp:310
@ D13_D14_D15_D16
Definition arm/registers.hpp:312
@ FPEXC
Definition arm/registers.hpp:30
@ D10_D12_D14
Definition arm/registers.hpp:247
@ D6
Definition arm/registers.hpp:50
@ D21_D22_D23_D24
Definition arm/registers.hpp:316
@ R5
Definition arm/registers.hpp:102
@ S3
Definition arm/registers.hpp:113
@ D23_D24
Definition arm/registers.hpp:302
@ D18_D20
Definition arm/registers.hpp:160
@ D11_D13_D15
Definition arm/registers.hpp:248
@ D2_D4_D6
Definition arm/registers.hpp:239
@ D29_D30_D31
Definition arm/registers.hpp:236
@ S18
Definition arm/registers.hpp:128
@ S14
Definition arm/registers.hpp:124
@ Q13
Definition arm/registers.hpp:94
@ Q10_Q11
Definition arm/registers.hpp:182
@ D5
Definition arm/registers.hpp:49
@ Q14_Q15
Definition arm/registers.hpp:186
@ D20
Definition arm/registers.hpp:64
@ D27_D29
Definition arm/registers.hpp:169
@ D13_D15
Definition arm/registers.hpp:155
@ D20_D22_D24_D26
Definition arm/registers.hpp:285
@ D24_D26_D28
Definition arm/registers.hpp:261
@ S17
Definition arm/registers.hpp:127
@ Q0
Definition arm/registers.hpp:81
@ R6
Definition arm/registers.hpp:103
@ D5_D7_D9_D11
Definition arm/registers.hpp:270
@ Q6
Definition arm/registers.hpp:87
@ D2_D4_D6_D8
Definition arm/registers.hpp:267
@ D23_D24_D25
Definition arm/registers.hpp:230
@ D9_D11
Definition arm/registers.hpp:151
@ D18_D20_D22_D24
Definition arm/registers.hpp:283
@ D12_D14_D16_D18
Definition arm/registers.hpp:277
@ D27_D28
Definition arm/registers.hpp:304
@ S9
Definition arm/registers.hpp:119
@ S0
Definition arm/registers.hpp:110
@ D6_D7_D8
Definition arm/registers.hpp:213
@ Q3_Q4_Q5_Q6
Definition arm/registers.hpp:190
@ APSR
Definition arm/registers.hpp:25
Namespace related to assembly/disassembly support.
Definition Abstract/Binary.hpp:43
LIEF namespace.
Definition Abstract/Binary.hpp:36