[llvm-readobj] - Simplify stack-sizes.test test case.
[llvm-complete.git] / test / MC / ARM / basic-thumb2-instructions.s
blob59f64afb2dde8e7e0595c804ea81795f5c729fcc
1 @ RUN: llvm-mc -triple=thumbv7-apple-darwin -mcpu=cortex-a8 -show-encoding < %s | FileCheck %s
2 @ RUN: llvm-mc -triple=thumbebv7-unknown-unknown -mcpu=cortex-a8 -show-encoding < %s | FileCheck --check-prefix=CHECK-BE %s
3 .syntax unified
4 .globl _func
6 @ Check that the assembler can handle the documented syntax from the ARM ARM.
7 @ For complex constructs like shifter operands, check more thoroughly for them
8 @ once then spot check that following instructions accept the form generally.
9 @ This gives us good coverage while keeping the overall size of the test
10 @ more reasonable.
13 @ FIXME: Some 3-operand instructions have a 2-operand assembly syntax.
15 _func:
16 @ CHECK: _func
18 @------------------------------------------------------------------------------
19 @ ADC (immediate)
20 @------------------------------------------------------------------------------
21 adc r0, r1, #4
22 adcs r0, r1, #0
23 adc r1, r2, #255
24 adc r3, r7, #0x00550055
25 adc r8, r12, #0xaa00aa00
26 adc r9, r7, #0xa5a5a5a5
27 adc r5, r3, #0x87000000
28 adc r4, r2, #0x7f800000
29 adc r4, r2, #0x00000680
31 @ CHECK: adc r0, r1, #4 @ encoding: [0x41,0xf1,0x04,0x00]
32 @ CHECK: adcs r0, r1, #0 @ encoding: [0x51,0xf1,0x00,0x00]
33 @ CHECK: adc r1, r2, #255 @ encoding: [0x42,0xf1,0xff,0x01]
34 @ CHECK: adc r3, r7, #5570645 @ encoding: [0x47,0xf1,0x55,0x13]
35 @ CHECK: adc r8, r12, #2852170240 @ encoding: [0x4c,0xf1,0xaa,0x28]
36 @ CHECK: adc r9, r7, #2779096485 @ encoding: [0x47,0xf1,0xa5,0x39]
37 @ CHECK: adc r5, r3, #2264924160 @ encoding: [0x43,0xf1,0x07,0x45]
38 @ CHECK: adc r4, r2, #2139095040 @ encoding: [0x42,0xf1,0xff,0x44]
39 @ CHECK: adc r4, r2, #1664 @ encoding: [0x42,0xf5,0xd0,0x64]
41 @------------------------------------------------------------------------------
42 @ ADC (register)
43 @------------------------------------------------------------------------------
44 adc r4, r5, r6
45 adcs r4, r5, r6
46 adc.w r9, r1, r3
47 adcs.w r9, r1, r3
48 adc r0, r1, r3, ror #4
49 adcs r0, r1, r3, lsl #7
50 adc.w r0, r1, r3, lsr #31
51 adcs.w r0, r1, r3, asr #32
53 @ CHECK: adc.w r4, r5, r6 @ encoding: [0x45,0xeb,0x06,0x04]
54 @ CHECK: adcs.w r4, r5, r6 @ encoding: [0x55,0xeb,0x06,0x04]
55 @ CHECK: adc.w r9, r1, r3 @ encoding: [0x41,0xeb,0x03,0x09]
56 @ CHECK: adcs.w r9, r1, r3 @ encoding: [0x51,0xeb,0x03,0x09]
57 @ CHECK: adc.w r0, r1, r3, ror #4 @ encoding: [0x41,0xeb,0x33,0x10]
58 @ CHECK: adcs.w r0, r1, r3, lsl #7 @ encoding: [0x51,0xeb,0xc3,0x10]
59 @ CHECK: adc.w r0, r1, r3, lsr #31 @ encoding: [0x41,0xeb,0xd3,0x70]
60 @ CHECK: adcs.w r0, r1, r3, asr #32 @ encoding: [0x51,0xeb,0x23,0x00]
63 @------------------------------------------------------------------------------
64 @ ADD (immediate)
65 @------------------------------------------------------------------------------
66 itet eq
67 addeq r1, r2, #4
68 addwne r5, r3, #1023
69 addeq r4, r5, #293
70 add r2, sp, #1024
71 add r2, r8, #0xff00
72 add r2, r3, #257
73 addw r2, r3, #257
74 add r12, r6, #0x100
75 addw r12, r6, #0x100
76 adds r1, r2, #0x1f0
77 add r2, #1
78 add r0, r0, #32
79 adds r2, r2, #56
80 adds r2, #56
81 add r1, r7, #0xcbcbcbcb
82 add sp, sp, #0x1fe0000
84 adds.w r2, #-16
85 adds.w r2, r2, #-16
86 addw r2, #-16
87 addw r2, #-16
88 addw r2, r2, #-16
90 @ CHECK: itet eq @ encoding: [0x0a,0xbf]
91 @ CHECK: addeq r1, r2, #4 @ encoding: [0x11,0x1d]
92 @ CHECK: addwne r5, r3, #1023 @ encoding: [0x03,0xf2,0xff,0x35]
93 @ CHECK: addweq r4, r5, #293 @ encoding: [0x05,0xf2,0x25,0x14]
94 @ CHECK: add.w r2, sp, #1024 @ encoding: [0x0d,0xf5,0x80,0x62]
95 @ CHECK: add.w r2, r8, #65280 @ encoding: [0x08,0xf5,0x7f,0x42]
96 @ CHECK: addw r2, r3, #257 @ encoding: [0x03,0xf2,0x01,0x12]
97 @ CHECK: addw r2, r3, #257 @ encoding: [0x03,0xf2,0x01,0x12]
98 @ CHECK: add.w r12, r6, #256 @ encoding: [0x06,0xf5,0x80,0x7c]
99 @ CHECK: addw r12, r6, #256 @ encoding: [0x06,0xf2,0x00,0x1c]
100 @ CHECK: adds.w r1, r2, #496 @ encoding: [0x12,0xf5,0xf8,0x71]
101 @ CHECK: add.w r2, r2, #1 @ encoding: [0x02,0xf1,0x01,0x02]
102 @ CHECK: add.w r0, r0, #32 @ encoding: [0x00,0xf1,0x20,0x00]
103 @ CHECK: adds r2, #56 @ encoding: [0x38,0x32]
104 @ CHECK: adds r2, #56 @ encoding: [0x38,0x32]
105 @ CHECK: add.w r1, r7, #3419130827 @ encoding: [0x07,0xf1,0xcb,0x31]
106 @ CHECK: add.w sp, sp, #33423360 @ encoding: [0x0d,0xf1,0xff,0x7d]
108 @ CHECK: subs.w r2, r2, #16 @ encoding: [0xb2,0xf1,0x10,0x02]
109 @ CHECK: subs.w r2, r2, #16 @ encoding: [0xb2,0xf1,0x10,0x02]
110 @ CHECK: subw r2, r2, #16 @ encoding: [0xa2,0xf2,0x10,0x02]
111 @ CHECK: subw r2, r2, #16 @ encoding: [0xa2,0xf2,0x10,0x02]
112 @ CHECK: subw r2, r2, #16 @ encoding: [0xa2,0xf2,0x10,0x02]
115 @------------------------------------------------------------------------------
116 @ ADD (register, not SP) A8.8.6
117 @------------------------------------------------------------------------------
118 add r1, r2, r8
119 add r5, r9, r2, asr #32
120 adds r7, r3, r1, lsl #31
121 adds.w r0, r3, r6, lsr #25
122 add.w r4, r8, r1, ror #12
123 adds r1, r1, r7 // T1
124 it eq
125 addeq r1, r3, r5 // T1
126 it eq
127 addeq r1, r1, r5 // T1
128 it eq
129 addseq r1, r3, r5 // T3
130 it eq
131 addseq r1, r1, r5 // T3
132 add r10, r8
133 add r10, r10, r8
134 it eq
135 addeq r1, r10 // T2
136 it eq
137 addseq r1, r10 // T3
139 @ CHECK: add.w r1, r2, r8 @ encoding: [0x02,0xeb,0x08,0x01]
140 @ CHECK: add.w r5, r9, r2, asr #32 @ encoding: [0x09,0xeb,0x22,0x05]
141 @ CHECK: adds.w r7, r3, r1, lsl #31 @ encoding: [0x13,0xeb,0xc1,0x77]
142 @ CHECK: adds.w r0, r3, r6, lsr #25 @ encoding: [0x13,0xeb,0x56,0x60]
143 @ CHECK: add.w r4, r8, r1, ror #12 @ encoding: [0x08,0xeb,0x31,0x34]
144 @ CHECK: adds r1, r1, r7 @ encoding: [0xc9,0x19]
145 @ CHECK: it eq @ encoding: [0x08,0xbf]
146 @ CHECK: addeq r1, r3, r5 @ encoding: [0x59,0x19]
147 @ CHECK: it eq @ encoding: [0x08,0xbf]
148 @ CHECK: addeq r1, r1, r5 @ encoding: [0x49,0x19]
149 @ CHECK: it eq @ encoding: [0x08,0xbf]
150 @ CHECK: addseq.w r1, r3, r5 @ encoding: [0x13,0xeb,0x05,0x01]
151 @ CHECK: it eq @ encoding: [0x08,0xbf]
152 @ CHECK: addseq.w r1, r1, r5 @ encoding: [0x11,0xeb,0x05,0x01]
153 @ CHECK: add r10, r8 @ encoding: [0xc2,0x44]
154 @ CHECK: add r10, r8 @ encoding: [0xc2,0x44]
155 @ CHECK: it eq @ encoding: [0x08,0xbf]
156 @ CHECK: addeq r1, r10 @ encoding: [0x51,0x44]
157 @ CHECK: it eq @ encoding: [0x08,0xbf]
158 @ CHECK: addseq.w r1, r1, r10 @ encoding: [0x11,0xeb,0x0a,0x01]
160 @------------------------------------------------------------------------------
161 @ ADD (SP plus immediate) A8.8.9
162 @------------------------------------------------------------------------------
163 it eq
164 @ CHECK: it eq @ encoding: [0x08,0xbf]
165 addeq r7, sp, #1020 // T1
166 @ CHECK: addeq r7, sp, #1020 @ encoding: [0xff,0xaf]
168 it eq
169 @ CHECK: it eq @ encoding: [0x08,0xbf]
170 addeq sp, sp, #508 // T2
171 @ FIXME: ARMARM says 'addeq sp, sp, #508'
172 @ CHECK: addeq sp, #508 @ encoding: [0x7f,0xb0]
174 add r7, sp, #15 // T3
175 @ CHECK: add.w r7, sp, #15 @ encoding: [0x0d,0xf1,0x0f,0x07]
176 adds r7, sp, #16 // T3
177 @ CHECK: adds.w r7, sp, #16 @ encoding: [0x1d,0xf1,0x10,0x07]
178 add r8, sp, #16 // T3
179 @ CHECK: add.w r8, sp, #16 @ encoding: [0x0d,0xf1,0x10,0x08]
181 addw r6, sp, #1020 // T4
182 @ CHECK: addw r6, sp, #1020 @ encoding: [0x0d,0xf2,0xfc,0x36]
183 add r6, sp, #1019 // T4
184 @ CHECK: addw r6, sp, #1019 @ encoding: [0x0d,0xf2,0xfb,0x36]
186 @------------------------------------------------------------------------------
187 @ ADD (SP plus register) A8.8.10
188 @------------------------------------------------------------------------------
189 it eq
190 @ CHECK: it eq @ encoding: [0x08,0xbf]
191 addeq r8, sp, r8 // T1
192 @ CHECK: addeq r8, sp, r8 @ encoding: [0xe8,0x44]
193 it eq
194 @ CHECK: it eq @ encoding: [0x08,0xbf]
195 addeq r8, sp // T1
196 @ CHECK: addeq r8, sp @ encoding: [0xe8,0x44]
198 it eq
199 @ CHECK: it eq @ encoding: [0x08,0xbf]
200 addeq sp, r9 // T2
201 @ CHECK: addeq sp, r9 @ encoding: [0xcd,0x44]
203 add r2, sp, ip // T3
204 @ CHECK: add.w r2, sp, r12 @ encoding: [0x0d,0xeb,0x0c,0x02]
205 it eq
206 @ CHECK: it eq @ encoding: [0x08,0xbf]
207 addeq r2, sp, ip // T3
208 @ CHECK: addeq.w r2, sp, r12 @ encoding: [0x0d,0xeb,0x0c,0x02]
211 @------------------------------------------------------------------------------
212 @ FIXME: ADR
213 @------------------------------------------------------------------------------
215 subw r11, pc, #3270
216 adr.w r2, #3
217 adr.w r11, #-826
218 adr.w r1, #-0x0
220 @ CHECK: subw r11, pc, #3270 @ encoding: [0xaf,0xf6,0xc6,0x4b]
221 @ CHECK: adr.w r2, #3 @ encoding: [0x0f,0xf2,0x03,0x02]
222 @ CHECK: adr.w r11, #-826 @ encoding: [0xaf,0xf2,0x3a,0x3b]
223 @ CHECK: adr.w r1, #-0 @ encoding: [0xaf,0xf2,0x00,0x01]
225 @------------------------------------------------------------------------------
226 @ AND (immediate)
227 @------------------------------------------------------------------------------
228 and r2, r5, #0xff000
229 ands r3, r12, #0xf
230 and r1, #0xff
231 and r1, r1, #0xff
232 and r5, r4, #0xffffffff
233 ands r1, r9, #0xffffffff
235 @ CHECK: and r2, r5, #1044480 @ encoding: [0x05,0xf4,0x7f,0x22]
236 @ CHECK: ands r3, r12, #15 @ encoding: [0x1c,0xf0,0x0f,0x03]
237 @ CHECK: and r1, r1, #255 @ encoding: [0x01,0xf0,0xff,0x01]
238 @ CHECK: and r1, r1, #255 @ encoding: [0x01,0xf0,0xff,0x01]
239 @ CHECK: and r5, r4, #4294967295 @ encoding: [0x04,0xf0,0xff,0x35]
240 @ CHECK: ands r1, r9, #4294967295 @ encoding: [0x19,0xf0,0xff,0x31]
242 @------------------------------------------------------------------------------
243 @ AND (register)
244 @------------------------------------------------------------------------------
245 and r4, r9, r8
246 and r1, r4, r8, asr #3
247 ands r2, r1, r7, lsl #1
248 ands.w r4, r5, r2, lsr #20
249 and.w r9, r12, r1, ror #17
251 @ CHECK: and.w r4, r9, r8 @ encoding: [0x09,0xea,0x08,0x04]
252 @ CHECK: and.w r1, r4, r8, asr #3 @ encoding: [0x04,0xea,0xe8,0x01]
253 @ CHECK: ands.w r2, r1, r7, lsl #1 @ encoding: [0x11,0xea,0x47,0x02]
254 @ CHECK: ands.w r4, r5, r2, lsr #20 @ encoding: [0x15,0xea,0x12,0x54]
255 @ CHECK: and.w r9, r12, r1, ror #17 @ encoding: [0x0c,0xea,0x71,0x49]
257 @------------------------------------------------------------------------------
258 @ ASR (immediate)
259 @------------------------------------------------------------------------------
260 asr r2, r3, #12
261 asrs r8, r3, #32
262 asrs.w r2, r3, #1
263 asr r2, r3, #4
264 asrs r2, r12, #15
266 asr r3, #19
267 asrs r8, #2
268 asrs.w r7, #5
269 asr.w r12, #21
271 asrs r1, r2, #1
272 itt eq
273 asrseq r1, r2, #1
274 asreq r1, r2, #1
276 @ CHECK: asr.w r2, r3, #12 @ encoding: [0x4f,0xea,0x23,0x32]
277 @ CHECK: asrs.w r8, r3, #32 @ encoding: [0x5f,0xea,0x23,0x08]
278 @ CHECK: asrs.w r2, r3, #1 @ encoding: [0x5f,0xea,0x63,0x02]
279 @ CHECK: asr.w r2, r3, #4 @ encoding: [0x4f,0xea,0x23,0x12]
280 @ CHECK: asrs.w r2, r12, #15 @ encoding: [0x5f,0xea,0xec,0x32]
282 @ CHECK: asr.w r3, r3, #19 @ encoding: [0x4f,0xea,0xe3,0x43]
283 @ CHECK: asrs.w r8, r8, #2 @ encoding: [0x5f,0xea,0xa8,0x08]
284 @ CHECK: asrs.w r7, r7, #5 @ encoding: [0x5f,0xea,0x67,0x17]
285 @ CHECK: asr.w r12, r12, #21 @ encoding: [0x4f,0xea,0x6c,0x5c]
287 @ CHECK: asrs r1, r2, #1 @ encoding: [0x51,0x10]
288 @ CHECK: itt eq @ encoding: [0x04,0xbf]
289 @ CHECK: asrseq.w r1, r2, #1 @ encoding: [0x5f,0xea,0x62,0x01]
290 @ CHECK: asreq r1, r2, #1 @ encoding: [0x51,0x10]
292 @------------------------------------------------------------------------------
293 @ ASR (register)
294 @------------------------------------------------------------------------------
295 asr r3, r4, r2
296 asr.w r1, r2
297 asrs r3, r4, r8
299 @ CHECK: asr.w r3, r4, r2 @ encoding: [0x44,0xfa,0x02,0xf3]
300 @ CHECK: asr.w r1, r1, r2 @ encoding: [0x41,0xfa,0x02,0xf1]
301 @ CHECK: asrs.w r3, r4, r8 @ encoding: [0x54,0xfa,0x08,0xf3]
304 @------------------------------------------------------------------------------
306 @------------------------------------------------------------------------------
307 b.w _bar
308 beq.w _bar
309 it eq
310 beq.w _bar
311 bmi.w #-183396
313 @ CHECK: b.w _bar @ encoding: [A,0xf0'A',A,0x90'A']
314 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_uncondbranch
315 @ CHECK-BE: b.w _bar @ encoding: [0xf0'A',A,0x90'A',A]
316 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_uncondbranch
317 @ CHECK: beq.w _bar @ encoding: [A,0xf0'A',A,0x80'A']
318 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_condbranch
319 @ CHECK-BE: beq.w _bar @ encoding: [0xf0'A',A,0x80'A',A]
320 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_condbranch
321 @ CHECK: it eq @ encoding: [0x08,0xbf]
322 @ CHECK: beq.w _bar @ encoding: [A,0xf0'A',A,0x90'A']
323 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_uncondbranch
324 @ CHECK-BE: beq.w _bar @ encoding: [0xf0'A',A,0x90'A',A]
325 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_uncondbranch
326 @ CHECK: bmi.w #-183396 @ encoding: [0x13,0xf5,0xce,0xa9]
329 @------------------------------------------------------------------------------
330 @ BFC
331 @------------------------------------------------------------------------------
332 bfc r5, #3, #17
333 it lo
334 bfccc r5, #3, #17
336 @ CHECK: bfc r5, #3, #17 @ encoding: [0x6f,0xf3,0xd3,0x05]
337 @ CHECK: it lo @ encoding: [0x38,0xbf]
338 @ CHECK: bfclo r5, #3, #17 @ encoding: [0x6f,0xf3,0xd3,0x05]
341 @------------------------------------------------------------------------------
342 @ BFI
343 @------------------------------------------------------------------------------
344 bfi r5, r2, #3, #17
345 it ne
346 bfine r5, r2, #3, #17
348 @ CHECK: bfi r5, r2, #3, #17 @ encoding: [0x62,0xf3,0xd3,0x05]
349 @ CHECK: it ne @ encoding: [0x18,0xbf]
350 @ CHECK: bfine r5, r2, #3, #17 @ encoding: [0x62,0xf3,0xd3,0x05]
353 @------------------------------------------------------------------------------
354 @ BIC
355 @------------------------------------------------------------------------------
356 bic r10, r1, #0xf
357 bic r5, r2, #0xffffffff
358 bics r11, r10, #0xffffffff
359 bic r12, r3, r6
360 bic r11, r2, r6, lsl #12
361 bic r8, r4, r1, lsr #11
362 bic r7, r5, r7, lsr #15
363 bic r6, r7, r9, asr #32
364 bic r5, r6, r8, ror #1
366 @ destination register is optional
367 bic r1, #0xf
368 bic r1, r1
369 bic r4, r2, lsl #31
370 bic r6, r3, lsr #12
371 bic r7, r4, lsr #7
372 bic r8, r5, asr #15
373 bic r12, r6, ror #29
375 @ CHECK: bic r10, r1, #15 @ encoding: [0x21,0xf0,0x0f,0x0a]
376 @ CHECK: bic r5, r2, #4294967295 @ encoding: [0x22,0xf0,0xff,0x35]
377 @ CHECK: bics r11, r10, #4294967295 @ encoding: [0x3a,0xf0,0xff,0x3b]
378 @ CHECK: bic.w r12, r3, r6 @ encoding: [0x23,0xea,0x06,0x0c]
379 @ CHECK: bic.w r11, r2, r6, lsl #12 @ encoding: [0x22,0xea,0x06,0x3b]
380 @ CHECK: bic.w r8, r4, r1, lsr #11 @ encoding: [0x24,0xea,0xd1,0x28]
381 @ CHECK: bic.w r7, r5, r7, lsr #15 @ encoding: [0x25,0xea,0xd7,0x37]
382 @ CHECK: bic.w r6, r7, r9, asr #32 @ encoding: [0x27,0xea,0x29,0x06]
383 @ CHECK: bic.w r5, r6, r8, ror #1 @ encoding: [0x26,0xea,0x78,0x05]
385 @ CHECK: bic r1, r1, #15 @ encoding: [0x21,0xf0,0x0f,0x01]
386 @ CHECK: bic.w r1, r1, r1 @ encoding: [0x21,0xea,0x01,0x01]
387 @ CHECK: bic.w r4, r4, r2, lsl #31 @ encoding: [0x24,0xea,0xc2,0x74]
388 @ CHECK: bic.w r6, r6, r3, lsr #12 @ encoding: [0x26,0xea,0x13,0x36]
389 @ CHECK: bic.w r7, r7, r4, lsr #7 @ encoding: [0x27,0xea,0xd4,0x17]
390 @ CHECK: bic.w r8, r8, r5, asr #15 @ encoding: [0x28,0xea,0xe5,0x38]
391 @ CHECK: bic.w r12, r12, r6, ror #29 @ encoding: [0x2c,0xea,0x76,0x7c]
393 @------------------------------------------------------------------------------
394 @ BKPT
395 @------------------------------------------------------------------------------
396 it pl
397 bkpt #234
399 @ CHECK: it pl @ encoding: [0x58,0xbf]
400 @ CHECK: bkpt #234 @ encoding: [0xea,0xbe]
402 @------------------------------------------------------------------------------
403 @ BXJ
404 @------------------------------------------------------------------------------
405 bxj r5
406 it ne
407 bxjne r7
409 @ CHECK: bxj r5 @ encoding: [0xc5,0xf3,0x00,0x8f]
410 @ CHECK: it ne @ encoding: [0x18,0xbf]
411 @ CHECK: bxjne r7 @ encoding: [0xc7,0xf3,0x00,0x8f]
414 @------------------------------------------------------------------------------
415 @ CBZ/CBNZ
416 @------------------------------------------------------------------------------
417 cbnz r7, #6
418 cbnz r7, #12
419 cbz r6, _bar
420 cbnz r6, _bar
422 @ CHECK: cbnz r7, #6 @ encoding: [0x1f,0xb9]
423 @ CHECK: cbnz r7, #12 @ encoding: [0x37,0xb9]
424 @ CHECK: cbz r6, _bar @ encoding: [0x06'A',0xb1'A']
425 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_arm_thumb_cb
426 @ CHECK-BE: cbz r6, _bar @ encoding: [0xb1'A',0x06'A']
427 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_arm_thumb_cb
428 @ CHECK: cbnz r6, _bar @ encoding: [0x06'A',0xb9'A']
429 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_arm_thumb_cb
430 @ CHECK-BE: cbnz r6, _bar @ encoding: [0xb9'A',0x06'A']
431 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_arm_thumb_cb
434 @------------------------------------------------------------------------------
435 @ CDP/CDP2
436 @------------------------------------------------------------------------------
437 cdp p7, #1, c1, c1, c1, #4
438 cdp2 p7, #1, c1, c1, c1, #4
440 @ CHECK: cdp p7, #1, c1, c1, c1, #4 @ encoding: [0x11,0xee,0x81,0x17]
441 @ CHECK: cdp2 p7, #1, c1, c1, c1, #4 @ encoding: [0x11,0xfe,0x81,0x17]
444 @------------------------------------------------------------------------------
445 @ CLREX
446 @------------------------------------------------------------------------------
447 clrex
448 it ne
449 clrexne
451 @ CHECK: clrex @ encoding: [0xbf,0xf3,0x2f,0x8f]
452 @ CHECK: it ne @ encoding: [0x18,0xbf]
453 @ CHECK: clrexne @ encoding: [0xbf,0xf3,0x2f,0x8f]
456 @------------------------------------------------------------------------------
457 @ CLZ
458 @------------------------------------------------------------------------------
459 clz r1, r2
460 it eq
461 clzeq r1, r2
463 @ CHECK: clz r1, r2 @ encoding: [0xb2,0xfa,0x82,0xf1]
464 @ CHECK: it eq @ encoding: [0x08,0xbf]
465 @ CHECK: clzeq r1, r2 @ encoding: [0xb2,0xfa,0x82,0xf1]
468 @------------------------------------------------------------------------------
469 @ CMN
470 @------------------------------------------------------------------------------
471 cmn r1, #0xf
472 cmn r8, r6
473 cmn r1, r6, lsl #10
474 cmn r1, r6, lsr #10
475 cmn sp, r6, lsr #10
476 cmn r1, r6, asr #10
477 cmn r1, r6, ror #10
479 @ CHECK: cmn.w r1, #15 @ encoding: [0x11,0xf1,0x0f,0x0f]
480 @ CHECK: cmn.w r8, r6 @ encoding: [0x18,0xeb,0x06,0x0f]
481 @ CHECK: cmn.w r1, r6, lsl #10 @ encoding: [0x11,0xeb,0x86,0x2f]
482 @ CHECK: cmn.w r1, r6, lsr #10 @ encoding: [0x11,0xeb,0x96,0x2f]
483 @ CHECK: cmn.w sp, r6, lsr #10 @ encoding: [0x1d,0xeb,0x96,0x2f]
484 @ CHECK: cmn.w r1, r6, asr #10 @ encoding: [0x11,0xeb,0xa6,0x2f]
485 @ CHECK: cmn.w r1, r6, ror #10 @ encoding: [0x11,0xeb,0xb6,0x2f]
488 @------------------------------------------------------------------------------
489 @ CMP
490 @------------------------------------------------------------------------------
491 cmp r5, #0xff00
492 cmp.w r4, r12
493 cmp r9, r6, lsl #12
494 cmp r3, r7, lsr #31
495 cmp sp, r6, lsr #1
496 cmp r2, r5, asr #24
497 cmp r1, r4, ror #15
498 cmp r2, #-2
499 cmp r9, #1
501 @ CHECK: cmp.w r5, #65280 @ encoding: [0xb5,0xf5,0x7f,0x4f]
502 @ CHECK: cmp.w r4, r12 @ encoding: [0xb4,0xeb,0x0c,0x0f]
503 @ CHECK: cmp.w r9, r6, lsl #12 @ encoding: [0xb9,0xeb,0x06,0x3f]
504 @ CHECK: cmp.w r3, r7, lsr #31 @ encoding: [0xb3,0xeb,0xd7,0x7f]
505 @ CHECK: cmp.w sp, r6, lsr #1 @ encoding: [0xbd,0xeb,0x56,0x0f]
506 @ CHECK: cmp.w r2, r5, asr #24 @ encoding: [0xb2,0xeb,0x25,0x6f]
507 @ CHECK: cmp.w r1, r4, ror #15 @ encoding: [0xb1,0xeb,0xf4,0x3f]
508 @ CHECK: cmn.w r2, #2 @ encoding: [0x12,0xf1,0x02,0x0f]
509 @ CHECK: cmp.w r9, #1 @ encoding: [0xb9,0xf1,0x01,0x0f]
511 @------------------------------------------------------------------------------
512 @ CPS
513 @------------------------------------------------------------------------------
515 cpsie f
516 cpsid a
517 cpsie.w f
518 cpsid.w a
519 cpsie i, #3
520 cpsie.w i, #3
521 cpsid f, #9
522 cpsid.w f, #9
523 cps #0
524 cps.w #0
526 @ CHECK: cpsie f @ encoding: [0x61,0xb6]
527 @ CHECK: cpsid a @ encoding: [0x74,0xb6]
528 @ CHECK: cpsie.w f @ encoding: [0xaf,0xf3,0x20,0x84]
529 @ CHECK: cpsid.w a @ encoding: [0xaf,0xf3,0x80,0x86]
530 @ CHECK: cpsie i, #3 @ encoding: [0xaf,0xf3,0x43,0x85]
531 @ CHECK: cpsie i, #3 @ encoding: [0xaf,0xf3,0x43,0x85]
532 @ CHECK: cpsid f, #9 @ encoding: [0xaf,0xf3,0x29,0x87]
533 @ CHECK: cpsid f, #9 @ encoding: [0xaf,0xf3,0x29,0x87]
534 @ CHECK: cps #0 @ encoding: [0xaf,0xf3,0x00,0x81]
535 @ CHECK: cps #0 @ encoding: [0xaf,0xf3,0x00,0x81]
537 @------------------------------------------------------------------------------
538 @ DBG
539 @------------------------------------------------------------------------------
540 dbg #5
541 dbg #0
542 dbg #15
544 @ CHECK: dbg #5 @ encoding: [0xaf,0xf3,0xf5,0x80]
545 @ CHECK: dbg #0 @ encoding: [0xaf,0xf3,0xf0,0x80]
546 @ CHECK: dbg #15 @ encoding: [0xaf,0xf3,0xff,0x80]
549 @------------------------------------------------------------------------------
550 @ DMB
551 @------------------------------------------------------------------------------
552 dmb #0xf
553 dmb #0xe
554 dmb #0xd
555 dmb #0xc
556 dmb #0xb
557 dmb #0xa
558 dmb #0x9
559 dmb #0x8
560 dmb #0x7
561 dmb #0x6
562 dmb #0x5
563 dmb #0x4
564 dmb #0x3
565 dmb #0x2
566 dmb #0x1
567 dmb #0x0
569 dmb sy
570 dmb st
571 dmb sh
572 dmb ish
573 dmb shst
574 dmb ishst
575 dmb un
576 dmb nsh
577 dmb unst
578 dmb nshst
579 dmb osh
580 dmb oshst
583 @ CHECK: dmb sy @ encoding: [0xbf,0xf3,0x5f,0x8f]
584 @ CHECK: dmb st @ encoding: [0xbf,0xf3,0x5e,0x8f]
585 @ CHECK: dmb #0xd @ encoding: [0xbf,0xf3,0x5d,0x8f]
586 @ CHECK: dmb #0xc @ encoding: [0xbf,0xf3,0x5c,0x8f]
587 @ CHECK: dmb ish @ encoding: [0xbf,0xf3,0x5b,0x8f]
588 @ CHECK: dmb ishst @ encoding: [0xbf,0xf3,0x5a,0x8f]
589 @ CHECK: dmb #0x9 @ encoding: [0xbf,0xf3,0x59,0x8f]
590 @ CHECK: dmb #0x8 @ encoding: [0xbf,0xf3,0x58,0x8f]
591 @ CHECK: dmb nsh @ encoding: [0xbf,0xf3,0x57,0x8f]
592 @ CHECK: dmb nshst @ encoding: [0xbf,0xf3,0x56,0x8f]
593 @ CHECK: dmb #0x5 @ encoding: [0xbf,0xf3,0x55,0x8f]
594 @ CHECK: dmb #0x4 @ encoding: [0xbf,0xf3,0x54,0x8f]
595 @ CHECK: dmb osh @ encoding: [0xbf,0xf3,0x53,0x8f]
596 @ CHECK: dmb oshst @ encoding: [0xbf,0xf3,0x52,0x8f]
597 @ CHECK: dmb #0x1 @ encoding: [0xbf,0xf3,0x51,0x8f]
598 @ CHECK: dmb #0x0 @ encoding: [0xbf,0xf3,0x50,0x8f]
600 @ CHECK: dmb sy @ encoding: [0xbf,0xf3,0x5f,0x8f]
601 @ CHECK: dmb st @ encoding: [0xbf,0xf3,0x5e,0x8f]
602 @ CHECK: dmb ish @ encoding: [0xbf,0xf3,0x5b,0x8f]
603 @ CHECK: dmb ish @ encoding: [0xbf,0xf3,0x5b,0x8f]
604 @ CHECK: dmb ishst @ encoding: [0xbf,0xf3,0x5a,0x8f]
605 @ CHECK: dmb ishst @ encoding: [0xbf,0xf3,0x5a,0x8f]
606 @ CHECK: dmb nsh @ encoding: [0xbf,0xf3,0x57,0x8f]
607 @ CHECK: dmb nsh @ encoding: [0xbf,0xf3,0x57,0x8f]
608 @ CHECK: dmb nshst @ encoding: [0xbf,0xf3,0x56,0x8f]
609 @ CHECK: dmb nshst @ encoding: [0xbf,0xf3,0x56,0x8f]
610 @ CHECK: dmb osh @ encoding: [0xbf,0xf3,0x53,0x8f]
611 @ CHECK: dmb oshst @ encoding: [0xbf,0xf3,0x52,0x8f]
612 @ CHECK: dmb sy @ encoding: [0xbf,0xf3,0x5f,0x8f]
615 @------------------------------------------------------------------------------
616 @ DSB
617 @------------------------------------------------------------------------------
618 dsb #0xf
619 dsb #0xe
620 dsb #0xd
621 dsb #0xc
622 dsb #0xb
623 dsb #0xa
624 dsb #0x9
625 dsb #0x8
626 dsb #0x7
627 dsb #0x6
628 dsb #0x5
629 dsb #0x4
630 dsb #0x3
631 dsb #0x2
632 dsb #0x1
633 dsb #0x0
635 dsb sy
636 dsb st
637 dsb sh
638 dsb ish
639 dsb shst
640 dsb ishst
641 dsb un
642 dsb nsh
643 dsb unst
644 dsb nshst
645 dsb osh
646 dsb oshst
649 @ CHECK: dsb sy @ encoding: [0xbf,0xf3,0x4f,0x8f]
650 @ CHECK: dsb st @ encoding: [0xbf,0xf3,0x4e,0x8f]
651 @ CHECK: dsb #0xd @ encoding: [0xbf,0xf3,0x4d,0x8f]
652 @ CHECK: dsb #0xc @ encoding: [0xbf,0xf3,0x4c,0x8f]
653 @ CHECK: dsb ish @ encoding: [0xbf,0xf3,0x4b,0x8f]
654 @ CHECK: dsb ishst @ encoding: [0xbf,0xf3,0x4a,0x8f]
655 @ CHECK: dsb #0x9 @ encoding: [0xbf,0xf3,0x49,0x8f]
656 @ CHECK: dsb #0x8 @ encoding: [0xbf,0xf3,0x48,0x8f]
657 @ CHECK: dsb nsh @ encoding: [0xbf,0xf3,0x47,0x8f]
658 @ CHECK: dsb nshst @ encoding: [0xbf,0xf3,0x46,0x8f]
659 @ CHECK: dsb #0x5 @ encoding: [0xbf,0xf3,0x45,0x8f]
660 @ CHECK: pssbb @ encoding: [0xbf,0xf3,0x44,0x8f]
661 @ CHECK: dsb osh @ encoding: [0xbf,0xf3,0x43,0x8f]
662 @ CHECK: dsb oshst @ encoding: [0xbf,0xf3,0x42,0x8f]
663 @ CHECK: dsb #0x1 @ encoding: [0xbf,0xf3,0x41,0x8f]
664 @ CHECK: ssbb @ encoding: [0xbf,0xf3,0x40,0x8f]
666 @ CHECK: dsb sy @ encoding: [0xbf,0xf3,0x4f,0x8f]
667 @ CHECK: dsb st @ encoding: [0xbf,0xf3,0x4e,0x8f]
668 @ CHECK: dsb ish @ encoding: [0xbf,0xf3,0x4b,0x8f]
669 @ CHECK: dsb ish @ encoding: [0xbf,0xf3,0x4b,0x8f]
670 @ CHECK: dsb ishst @ encoding: [0xbf,0xf3,0x4a,0x8f]
671 @ CHECK: dsb ishst @ encoding: [0xbf,0xf3,0x4a,0x8f]
672 @ CHECK: dsb nsh @ encoding: [0xbf,0xf3,0x47,0x8f]
673 @ CHECK: dsb nsh @ encoding: [0xbf,0xf3,0x47,0x8f]
674 @ CHECK: dsb nshst @ encoding: [0xbf,0xf3,0x46,0x8f]
675 @ CHECK: dsb nshst @ encoding: [0xbf,0xf3,0x46,0x8f]
676 @ CHECK: dsb osh @ encoding: [0xbf,0xf3,0x43,0x8f]
677 @ CHECK: dsb oshst @ encoding: [0xbf,0xf3,0x42,0x8f]
678 @ CHECK: dsb sy @ encoding: [0xbf,0xf3,0x4f,0x8f]
681 @------------------------------------------------------------------------------
682 @ EOR
683 @------------------------------------------------------------------------------
684 eor r4, r5, #0xf000
685 eor r4, r5, r6
686 eor r4, r5, r6, lsl #5
687 eor r4, r5, r6, lsr #5
688 eor r4, r5, r6, lsr #5
689 eor r4, r5, r6, asr #5
690 eor r4, r5, r6, ror #5
692 @ CHECK: eor r4, r5, #61440 @ encoding: [0x85,0xf4,0x70,0x44]
693 @ CHECK: eor.w r4, r5, r6 @ encoding: [0x85,0xea,0x06,0x04]
694 @ CHECK: eor.w r4, r5, r6, lsl #5 @ encoding: [0x85,0xea,0x46,0x14]
695 @ CHECK: eor.w r4, r5, r6, lsr #5 @ encoding: [0x85,0xea,0x56,0x14]
696 @ CHECK: eor.w r4, r5, r6, lsr #5 @ encoding: [0x85,0xea,0x56,0x14]
697 @ CHECK: eor.w r4, r5, r6, asr #5 @ encoding: [0x85,0xea,0x66,0x14]
698 @ CHECK: eor.w r4, r5, r6, ror #5 @ encoding: [0x85,0xea,0x76,0x14]
701 @------------------------------------------------------------------------------
702 @ ISB
703 @------------------------------------------------------------------------------
704 isb sy
706 isb #15
707 isb #1
709 @ CHECK: isb sy @ encoding: [0xbf,0xf3,0x6f,0x8f]
710 @ CHECK: isb sy @ encoding: [0xbf,0xf3,0x6f,0x8f]
711 @ CHECK: isb sy @ encoding: [0xbf,0xf3,0x6f,0x8f]
712 @ CHECK: isb #0x1 @ encoding: [0xbf,0xf3,0x61,0x8f]
715 @------------------------------------------------------------------------------
716 @ IT
717 @------------------------------------------------------------------------------
718 @ Test encodings of a few full IT blocks, not just the IT instruction
720 iteet eq
721 addeq r0, r1, r2
722 nopne
723 subne r5, r6, r7
724 addeq r1, r2, #4
726 @ CHECK: iteet eq @ encoding: [0x0d,0xbf]
727 @ CHECK: addeq r0, r1, r2 @ encoding: [0x88,0x18]
728 @ CHECK: nopne @ encoding: [0x00,0xbf]
729 @ CHECK: subne r5, r6, r7 @ encoding: [0xf5,0x1b]
730 @ CHECK: addeq r1, r2, #4 @ encoding: [0x11,0x1d]
732 @ Should also work for UPPER CASE condition codes.
734 ITEET EQ
735 ADDEQ R0, R1, R2
736 NOPNE
737 SUBNE R5, R6, R7
738 ADDEQ R1, R2, #4
740 @ CHECK: iteet eq @ encoding: [0x0d,0xbf]
741 @ CHECK: addeq r0, r1, r2 @ encoding: [0x88,0x18]
742 @ CHECK: nopne @ encoding: [0x00,0xbf]
743 @ CHECK: subne r5, r6, r7 @ encoding: [0xf5,0x1b]
744 @ CHECK: addeq r1, r2, #4 @ encoding: [0x11,0x1d]
746 @------------------------------------------------------------------------------
747 @ LDC{L}/LDC2{L}
748 @------------------------------------------------------------------------------
749 ldc2 p0, c8, [r1, #4]
750 ldc2 p1, c7, [r2]
751 ldc2 p2, c6, [r3, #-224]
752 ldc2 p3, c5, [r4, #-120]!
753 ldc2 p4, c4, [r5], #16
754 ldc2 p5, c3, [r6], #-72
755 ldc2l p6, c2, [r7, #4]
756 ldc2l p7, c1, [r8]
757 ldc2l p8, c0, [r9, #-224]
758 ldc2l p9, c1, [r10, #-120]!
759 ldc2l p0, c2, [r11], #16
760 ldc2l p1, c3, [r12], #-72
762 ldc p12, c4, [r0, #4]
763 ldc p13, c5, [r1]
764 ldc p14, c6, [r2, #-224]
765 ldc p15, c7, [r3, #-120]!
766 ldc p5, c8, [r4], #16
767 ldc p4, c9, [r5], #-72
768 ldcl p3, c10, [r6, #4]
769 ldcl p2, c11, [r7]
770 ldcl p1, c12, [r8, #-224]
771 ldcl p0, c13, [r9, #-120]!
772 ldcl p6, c14, [r10], #16
773 ldcl p7, c15, [r11], #-72
775 ldc2 p2, c8, [r1], { 25 }
777 @ CHECK: ldc2 p0, c8, [r1, #4] @ encoding: [0x91,0xfd,0x01,0x80]
778 @ CHECK: ldc2 p1, c7, [r2] @ encoding: [0x92,0xfd,0x00,0x71]
779 @ CHECK: ldc2 p2, c6, [r3, #-224] @ encoding: [0x13,0xfd,0x38,0x62]
780 @ CHECK: ldc2 p3, c5, [r4, #-120]! @ encoding: [0x34,0xfd,0x1e,0x53]
781 @ CHECK: ldc2 p4, c4, [r5], #16 @ encoding: [0xb5,0xfc,0x04,0x44]
782 @ CHECK: ldc2 p5, c3, [r6], #-72 @ encoding: [0x36,0xfc,0x12,0x35]
783 @ CHECK: ldc2l p6, c2, [r7, #4] @ encoding: [0xd7,0xfd,0x01,0x26]
784 @ CHECK: ldc2l p7, c1, [r8] @ encoding: [0xd8,0xfd,0x00,0x17]
785 @ CHECK: ldc2l p8, c0, [r9, #-224] @ encoding: [0x59,0xfd,0x38,0x08]
786 @ CHECK: ldc2l p9, c1, [r10, #-120]! @ encoding: [0x7a,0xfd,0x1e,0x19]
787 @ CHECK: ldc2l p0, c2, [r11], #16 @ encoding: [0xfb,0xfc,0x04,0x20]
788 @ CHECK: ldc2l p1, c3, [r12], #-72 @ encoding: [0x7c,0xfc,0x12,0x31]
790 @ CHECK: ldc p12, c4, [r0, #4] @ encoding: [0x90,0xed,0x01,0x4c]
791 @ CHECK: ldc p13, c5, [r1] @ encoding: [0x91,0xed,0x00,0x5d]
792 @ CHECK: ldc p14, c6, [r2, #-224] @ encoding: [0x12,0xed,0x38,0x6e]
793 @ CHECK: ldc p15, c7, [r3, #-120]! @ encoding: [0x33,0xed,0x1e,0x7f]
794 @ CHECK: ldc p5, c8, [r4], #16 @ encoding: [0xb4,0xec,0x04,0x85]
795 @ CHECK: ldc p4, c9, [r5], #-72 @ encoding: [0x35,0xec,0x12,0x94]
796 @ CHECK: ldcl p3, c10, [r6, #4] @ encoding: [0xd6,0xed,0x01,0xa3]
797 @ CHECK: ldcl p2, c11, [r7] @ encoding: [0xd7,0xed,0x00,0xb2]
798 @ CHECK: ldcl p1, c12, [r8, #-224] @ encoding: [0x58,0xed,0x38,0xc1]
799 @ CHECK: ldcl p0, c13, [r9, #-120]! @ encoding: [0x79,0xed,0x1e,0xd0]
800 @ CHECK: ldcl p6, c14, [r10], #16 @ encoding: [0xfa,0xec,0x04,0xe6]
801 @ CHECK: ldcl p7, c15, [r11], #-72 @ encoding: [0x7b,0xec,0x12,0xf7]
803 @ CHECK: ldc2 p2, c8, [r1], {25} @ encoding: [0x91,0xfc,0x19,0x82]
806 @------------------------------------------------------------------------------
807 @ LDMIA
808 @------------------------------------------------------------------------------
809 ldmia.w r4, {r4, r5, r8, r9}
810 ldmia.w r4, {r5, r6}
811 ldmia.w r5!, {r3, r8}
812 ldm.w r4, {r4, r5, r8, r9}
813 ldm.w r4, {r5, r6}
814 ldm.w r5!, {r3, r8}
815 ldm.w r5!, {r1, r2}
816 ldm.w r2, {r1, r2}
818 ldmia r4, {r4, r5, r8, r9}
819 ldmia r4, {r5, r6}
820 ldmia r5!, {r3, r8}
821 ldm r4, {r4, r5, r8, r9}
822 ldm r4, {r5, r6}
823 ldm r5!, {r3, r8}
824 ldmfd r5!, {r3, r8}
825 ldmia sp!, {r4-r11, pc}
827 @ CHECK: ldm.w r4, {r4, r5, r8, r9} @ encoding: [0x94,0xe8,0x30,0x03]
828 @ CHECK: ldm.w r4, {r5, r6} @ encoding: [0x94,0xe8,0x60,0x00]
829 @ CHECK: ldm.w r5!, {r3, r8} @ encoding: [0xb5,0xe8,0x08,0x01]
830 @ CHECK: ldm.w r4, {r4, r5, r8, r9} @ encoding: [0x94,0xe8,0x30,0x03]
831 @ CHECK: ldm.w r4, {r5, r6} @ encoding: [0x94,0xe8,0x60,0x00]
832 @ CHECK: ldm.w r5!, {r3, r8} @ encoding: [0xb5,0xe8,0x08,0x01]
833 @ CHECK: ldm.w r5!, {r1, r2} @ encoding: [0xb5,0xe8,0x06,0x00]
834 @ CHECK: ldm.w r2, {r1, r2} @ encoding: [0x92,0xe8,0x06,0x00]
836 @ CHECK: ldm.w r4, {r4, r5, r8, r9} @ encoding: [0x94,0xe8,0x30,0x03]
837 @ CHECK: ldm.w r4, {r5, r6} @ encoding: [0x94,0xe8,0x60,0x00]
838 @ CHECK: ldm.w r5!, {r3, r8} @ encoding: [0xb5,0xe8,0x08,0x01]
839 @ CHECK: ldm.w r4, {r4, r5, r8, r9} @ encoding: [0x94,0xe8,0x30,0x03]
840 @ CHECK: ldm.w r4, {r5, r6} @ encoding: [0x94,0xe8,0x60,0x00]
841 @ CHECK: ldm.w r5!, {r3, r8} @ encoding: [0xb5,0xe8,0x08,0x01]
842 @ CHECK: ldm.w r5!, {r3, r8} @ encoding: [0xb5,0xe8,0x08,0x01]
843 @ CHECK: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc} @ encoding: [0xbd,0xe8,0xf0,0x8f]
846 @------------------------------------------------------------------------------
847 @ LDMDB
848 @------------------------------------------------------------------------------
849 ldmdb r4, {r4, r5, r8, r9}
850 ldmdb r4, {r5, r6}
851 ldmdb r5!, {r3, r8}
852 ldmea r5!, {r3, r8}
853 ldmdb.w r4, {r5, r6}
854 ldmdb.w r5!, {r3, r8}
856 @ CHECK: ldmdb r4, {r4, r5, r8, r9} @ encoding: [0x14,0xe9,0x30,0x03]
857 @ CHECK: ldmdb r4, {r5, r6} @ encoding: [0x14,0xe9,0x60,0x00]
858 @ CHECK: ldmdb r5!, {r3, r8} @ encoding: [0x35,0xe9,0x08,0x01]
859 @ CHECK: ldmdb r5!, {r3, r8} @ encoding: [0x35,0xe9,0x08,0x01]
860 @ CHECK: ldmdb r4, {r5, r6} @ encoding: [0x14,0xe9,0x60,0x00]
861 @ CHECK: ldmdb r5!, {r3, r8} @ encoding: [0x35,0xe9,0x08,0x01]
864 @------------------------------------------------------------------------------
865 @ LDR(immediate)
866 @------------------------------------------------------------------------------
867 ldr r5, [r5, #-4]
868 ldr r5, [r6, #32]
869 ldr r5, [r6, #33]
870 ldr r5, [r6, #257]
871 ldr.w pc, [r7, #257]
872 ldr r2, [r4, #255]!
873 ldr r8, [sp, #4]!
874 ldr lr, [sp, #-4]!
875 ldr r2, [r4], #255
876 ldr r8, [sp], #4
877 ldr lr, [sp], #-4
879 @ CHECK: ldr r5, [r5, #-4] @ encoding: [0x55,0xf8,0x04,0x5c]
880 @ CHECK: ldr r5, [r6, #32] @ encoding: [0x35,0x6a]
881 @ CHECK: ldr.w r5, [r6, #33] @ encoding: [0xd6,0xf8,0x21,0x50]
882 @ CHECK: ldr.w r5, [r6, #257] @ encoding: [0xd6,0xf8,0x01,0x51]
883 @ CHECK: ldr.w pc, [r7, #257] @ encoding: [0xd7,0xf8,0x01,0xf1]
884 @ CHECK: ldr r2, [r4, #255]! @ encoding: [0x54,0xf8,0xff,0x2f]
885 @ CHECK: ldr r8, [sp, #4]! @ encoding: [0x5d,0xf8,0x04,0x8f]
886 @ CHECK: ldr lr, [sp, #-4]! @ encoding: [0x5d,0xf8,0x04,0xed]
887 @ CHECK: ldr r2, [r4], #255 @ encoding: [0x54,0xf8,0xff,0x2b]
888 @ CHECK: ldr r8, [sp], #4 @ encoding: [0x5d,0xf8,0x04,0x8b]
889 @ CHECK: ldr lr, [sp], #-4 @ encoding: [0x5d,0xf8,0x04,0xe9]
892 @------------------------------------------------------------------------------
893 @ LDR(literal)
894 @------------------------------------------------------------------------------
895 ldr.w r5, _foo
896 ldr lr, (_strcmp-4)
897 ldr sp, _foo
898 ldr pc, _foo
900 @ CHECK: ldr.w r5, _foo @ encoding: [0x5f'A',0xf8'A',A,0x50'A']
901 @ CHECK: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
902 @ CHECK-BE: ldr.w r5, _foo @ encoding: [0xf8'A',0x5f'A',0x50'A',A]
903 @ CHECK-BE: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
904 @ CHECK: ldr.w lr, _strcmp-4 @ encoding: [0x5f'A',0xf8'A',A,0xe0'A']
905 @ CHECK: @ fixup A - offset: 0, value: _strcmp-4, kind: fixup_t2_ldst_pcrel_12
906 @ CHECK-BE: ldr.w lr, _strcmp-4 @ encoding: [0xf8'A',0x5f'A',0xe0'A',A]
907 @ CHECK-BE: @ fixup A - offset: 0, value: _strcmp-4, kind: fixup_t2_ldst_pcrel_12
908 @ CHECK: ldr.w sp, _foo @ encoding: [0x5f'A',0xf8'A',A,0xd0'A']
909 @ CHECK: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
910 @ CHECK-BE: ldr.w sp, _foo @ encoding: [0xf8'A',0x5f'A',0xd0'A',A]
911 @ CHECK-BE: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
912 @ CHECK: ldr.w pc, _foo @ encoding: [0x5f'A',0xf8'A',A,0xf0'A']
913 @ CHECK: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
914 @ CHECK-BE: ldr.w pc, _foo @ encoding: [0xf8'A',0x5f'A',0xf0'A',A]
915 @ CHECK-BE: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
917 ldr r7, [pc, #8]
918 ldr.n r7, [pc, #8]
919 ldr.w r7, [pc, #8]
920 ldr r4, [pc, #1020]
921 ldr r3, [pc, #-1020]
922 ldr r6, [pc, #1024]
923 ldr r0, [pc, #-1024]
924 ldr r2, [pc, #4095]
925 ldr r1, [pc, #-4095]
926 ldr r8, [pc, #132]
927 ldr pc, [pc, #256]
928 ldr pc, [pc, #-400]
929 ldr sp, [pc, #4]
931 @ CHECK: ldr r7, [pc, #8] @ encoding: [0x02,0x4f]
932 @ CHECK: ldr r7, [pc, #8] @ encoding: [0x02,0x4f]
933 @ CHECK: ldr.w r7, [pc, #8] @ encoding: [0xdf,0xf8,0x08,0x70]
934 @ CHECK: ldr r4, [pc, #1020] @ encoding: [0xff,0x4c]
935 @ CHECK: ldr.w r3, [pc, #-1020] @ encoding: [0x5f,0xf8,0xfc,0x33]
936 @ CHECK: ldr.w r6, [pc, #1024] @ encoding: [0xdf,0xf8,0x00,0x64]
937 @ CHECK: ldr.w r0, [pc, #-1024] @ encoding: [0x5f,0xf8,0x00,0x04]
938 @ CHECK: ldr.w r2, [pc, #4095] @ encoding: [0xdf,0xf8,0xff,0x2f]
939 @ CHECK: ldr.w r1, [pc, #-4095] @ encoding: [0x5f,0xf8,0xff,0x1f]
940 @ CHECK: ldr.w r8, [pc, #132] @ encoding: [0xdf,0xf8,0x84,0x80]
941 @ CHECK: ldr.w pc, [pc, #256] @ encoding: [0xdf,0xf8,0x00,0xf1]
942 @ CHECK: ldr.w pc, [pc, #-400] @ encoding: [0x5f,0xf8,0x90,0xf1]
943 @ CHECK: ldr.w sp, [pc, #4] @ encoding: [0xdf,0xf8,0x04,0xd0]
945 ldrb r9, [pc, #-0]
946 ldrsb r11, [pc, #-0]
947 ldrh r10, [pc, #-0]
948 ldrsh r1, [pc, #-0]
949 ldr r5, [pc, #-0]
951 @ CHECK: ldrb.w r9, [pc, #-0] @ encoding: [0x1f,0xf8,0x00,0x90]
952 @ CHECK: ldrsb.w r11, [pc, #-0] @ encoding: [0x1f,0xf9,0x00,0xb0]
953 @ CHECK: ldrh.w r10, [pc, #-0] @ encoding: [0x3f,0xf8,0x00,0xa0]
954 @ CHECK: ldrsh.w r1, [pc, #-0] @ encoding: [0x3f,0xf9,0x00,0x10]
955 @ CHECK: ldr.w r5, [pc, #-0] @ encoding: [0x5f,0xf8,0x00,0x50]
957 @------------------------------------------------------------------------------
958 @ LDR(register)
959 @------------------------------------------------------------------------------
960 ldr r1, [r8, r1]
961 ldr.w r4, [r5, r2]
962 ldr r6, [r0, r2, lsl #3]
963 ldr r8, [r8, r2, lsl #2]
964 ldr r7, [sp, r2, lsl #1]
965 ldr r7, [sp, r2, lsl #0]
967 @ CHECK: ldr.w r1, [r8, r1] @ encoding: [0x58,0xf8,0x01,0x10]
968 @ CHECK: ldr.w r4, [r5, r2] @ encoding: [0x55,0xf8,0x02,0x40]
969 @ CHECK: ldr.w r6, [r0, r2, lsl #3] @ encoding: [0x50,0xf8,0x32,0x60]
970 @ CHECK: ldr.w r8, [r8, r2, lsl #2] @ encoding: [0x58,0xf8,0x22,0x80]
971 @ CHECK: ldr.w r7, [sp, r2, lsl #1] @ encoding: [0x5d,0xf8,0x12,0x70]
972 @ CHECK: ldr.w r7, [sp, r2] @ encoding: [0x5d,0xf8,0x02,0x70]
975 @------------------------------------------------------------------------------
976 @ LDRB(immediate)
977 @------------------------------------------------------------------------------
978 ldrb r5, [r5, #-4]
979 ldrb r5, [r6, #32]
980 ldrb r5, [r6, #33]
981 ldrb r5, [r6, #257]
982 ldrb.w lr, [r7, #257]
983 ldrb r5, [r8, #255]!
984 ldrb r2, [r5, #4]!
985 ldrb r1, [r4, #-4]!
986 ldrb lr, [r3], #255
987 ldrb r9, [r2], #4
988 ldrb r3, [sp], #-4
990 @ CHECK: ldrb r5, [r5, #-4] @ encoding: [0x15,0xf8,0x04,0x5c]
991 @ CHECK: ldrb.w r5, [r6, #32] @ encoding: [0x96,0xf8,0x20,0x50]
992 @ CHECK: ldrb.w r5, [r6, #33] @ encoding: [0x96,0xf8,0x21,0x50]
993 @ CHECK: ldrb.w r5, [r6, #257] @ encoding: [0x96,0xf8,0x01,0x51]
994 @ CHECK: ldrb.w lr, [r7, #257] @ encoding: [0x97,0xf8,0x01,0xe1]
995 @ CHECK: ldrb r5, [r8, #255]! @ encoding: [0x18,0xf8,0xff,0x5f]
996 @ CHECK: ldrb r2, [r5, #4]! @ encoding: [0x15,0xf8,0x04,0x2f]
997 @ CHECK: ldrb r1, [r4, #-4]! @ encoding: [0x14,0xf8,0x04,0x1d]
998 @ CHECK: ldrb lr, [r3], #255 @ encoding: [0x13,0xf8,0xff,0xeb]
999 @ CHECK: ldrb r9, [r2], #4 @ encoding: [0x12,0xf8,0x04,0x9b]
1000 @ CHECK: ldrb r3, [sp], #-4 @ encoding: [0x1d,0xf8,0x04,0x39]
1003 @------------------------------------------------------------------------------
1004 @ LDRB(register)
1005 @------------------------------------------------------------------------------
1006 ldrb r1, [r8, r1]
1007 ldrb.w r4, [r5, r2]
1008 ldrb r6, [r0, r2, lsl #3]
1009 ldrb r8, [r8, r2, lsl #2]
1010 ldrb r7, [sp, r2, lsl #1]
1011 ldrb r7, [sp, r2, lsl #0]
1013 @ CHECK: ldrb.w r1, [r8, r1] @ encoding: [0x18,0xf8,0x01,0x10]
1014 @ CHECK: ldrb.w r4, [r5, r2] @ encoding: [0x15,0xf8,0x02,0x40]
1015 @ CHECK: ldrb.w r6, [r0, r2, lsl #3] @ encoding: [0x10,0xf8,0x32,0x60]
1016 @ CHECK: ldrb.w r8, [r8, r2, lsl #2] @ encoding: [0x18,0xf8,0x22,0x80]
1017 @ CHECK: ldrb.w r7, [sp, r2, lsl #1] @ encoding: [0x1d,0xf8,0x12,0x70]
1018 @ CHECK: ldrb.w r7, [sp, r2] @ encoding: [0x1d,0xf8,0x02,0x70]
1021 @------------------------------------------------------------------------------
1022 @ LDRBT
1023 @------------------------------------------------------------------------------
1024 ldrbt r1, [r2]
1025 ldrbt r1, [r8, #0]
1026 ldrbt r1, [r8, #3]
1027 ldrbt r1, [r8, #255]
1029 @ CHECK: ldrbt r1, [r2] @ encoding: [0x12,0xf8,0x00,0x1e]
1030 @ CHECK: ldrbt r1, [r8] @ encoding: [0x18,0xf8,0x00,0x1e]
1031 @ CHECK: ldrbt r1, [r8, #3] @ encoding: [0x18,0xf8,0x03,0x1e]
1032 @ CHECK: ldrbt r1, [r8, #255] @ encoding: [0x18,0xf8,0xff,0x1e]
1035 @------------------------------------------------------------------------------
1036 @ LDRD
1037 @------------------------------------------------------------------------------
1038 ldrd r3, r5, [r6, #24]
1039 ldrd r3, r5, [r6, #24]!
1040 ldrd r3, r5, [r6], #4
1041 ldrd r3, r5, [r6], #-8
1042 ldrd r3, r5, [r6]
1043 ldrd r8, r1, [r3, #0]
1044 ldrd r0, r1, [r2, #-0]
1045 ldrd r0, r1, [r2, #-0]!
1046 ldrd r0, r1, [r2], #-0
1048 @ CHECK: ldrd r3, r5, [r6, #24] @ encoding: [0xd6,0xe9,0x06,0x35]
1049 @ CHECK: ldrd r3, r5, [r6, #24]! @ encoding: [0xf6,0xe9,0x06,0x35]
1050 @ CHECK: ldrd r3, r5, [r6], #4 @ encoding: [0xf6,0xe8,0x01,0x35]
1051 @ CHECK: ldrd r3, r5, [r6], #-8 @ encoding: [0x76,0xe8,0x02,0x35]
1052 @ CHECK: ldrd r3, r5, [r6] @ encoding: [0xd6,0xe9,0x00,0x35]
1053 @ CHECK: ldrd r8, r1, [r3] @ encoding: [0xd3,0xe9,0x00,0x81]
1054 @ CHECK: ldrd r0, r1, [r2, #-0] @ encoding: [0x52,0xe9,0x00,0x01]
1055 @ CHECK: ldrd r0, r1, [r2, #-0]! @ encoding: [0x72,0xe9,0x00,0x01]
1056 @ CHECK: ldrd r0, r1, [r2], #-0 @ encoding: [0x72,0xe8,0x00,0x01]
1059 @------------------------------------------------------------------------------
1060 @ FIXME: LDRD(literal)
1061 @------------------------------------------------------------------------------
1064 @------------------------------------------------------------------------------
1065 @ LDREX/LDREXB/LDREXH/LDREXD
1066 @------------------------------------------------------------------------------
1067 ldrex r1, [r4]
1068 ldrex r8, [r4, #0]
1069 ldrex r2, [sp, #128]
1070 ldrexb r5, [r7]
1071 ldrexh r9, [r12]
1072 ldrexd r9, r3, [r4]
1074 @ CHECK: ldrex r1, [r4] @ encoding: [0x54,0xe8,0x00,0x1f]
1075 @ CHECK: ldrex r8, [r4] @ encoding: [0x54,0xe8,0x00,0x8f]
1076 @ CHECK: ldrex r2, [sp, #128] @ encoding: [0x5d,0xe8,0x20,0x2f]
1077 @ CHECK: ldrexb r5, [r7] @ encoding: [0xd7,0xe8,0x4f,0x5f]
1078 @ CHECK: ldrexh r9, [r12] @ encoding: [0xdc,0xe8,0x5f,0x9f]
1079 @ CHECK: ldrexd r9, r3, [r4] @ encoding: [0xd4,0xe8,0x7f,0x93]
1082 @------------------------------------------------------------------------------
1083 @ LDRH(immediate)
1084 @------------------------------------------------------------------------------
1085 ldrh r5, [r5, #-4]
1086 ldrh r5, [r6, #32]
1087 ldrh r5, [r6, #33]
1088 ldrh r5, [r6, #257]
1089 ldrh.w lr, [r7, #257]
1090 ldrh r5, [r8, #255]!
1091 ldrh r2, [r5, #4]!
1092 ldrh r1, [r4, #-4]!
1093 ldrh lr, [r3], #255
1094 ldrh r9, [r2], #4
1095 ldrh r3, [sp], #-4
1097 @ CHECK: ldrh r5, [r5, #-4] @ encoding: [0x35,0xf8,0x04,0x5c]
1098 @ CHECK: ldrh r5, [r6, #32] @ encoding: [0x35,0x8c]
1099 @ CHECK: ldrh.w r5, [r6, #33] @ encoding: [0xb6,0xf8,0x21,0x50]
1100 @ CHECK: ldrh.w r5, [r6, #257] @ encoding: [0xb6,0xf8,0x01,0x51]
1101 @ CHECK: ldrh.w lr, [r7, #257] @ encoding: [0xb7,0xf8,0x01,0xe1]
1102 @ CHECK: ldrh r5, [r8, #255]! @ encoding: [0x38,0xf8,0xff,0x5f]
1103 @ CHECK: ldrh r2, [r5, #4]! @ encoding: [0x35,0xf8,0x04,0x2f]
1104 @ CHECK: ldrh r1, [r4, #-4]! @ encoding: [0x34,0xf8,0x04,0x1d]
1105 @ CHECK: ldrh lr, [r3], #255 @ encoding: [0x33,0xf8,0xff,0xeb]
1106 @ CHECK: ldrh r9, [r2], #4 @ encoding: [0x32,0xf8,0x04,0x9b]
1107 @ CHECK: ldrh r3, [sp], #-4 @ encoding: [0x3d,0xf8,0x04,0x39]
1110 @------------------------------------------------------------------------------
1111 @ LDRH(register)
1112 @------------------------------------------------------------------------------
1113 ldrh r1, [r8, r1]
1114 ldrh.w r4, [r5, r2]
1115 ldrh r6, [r0, r2, lsl #3]
1116 ldrh r8, [r8, r2, lsl #2]
1117 ldrh r7, [sp, r2, lsl #1]
1118 ldrh r7, [sp, r2, lsl #0]
1120 @ CHECK: ldrh.w r1, [r8, r1] @ encoding: [0x38,0xf8,0x01,0x10]
1121 @ CHECK: ldrh.w r4, [r5, r2] @ encoding: [0x35,0xf8,0x02,0x40]
1122 @ CHECK: ldrh.w r6, [r0, r2, lsl #3] @ encoding: [0x30,0xf8,0x32,0x60]
1123 @ CHECK: ldrh.w r8, [r8, r2, lsl #2] @ encoding: [0x38,0xf8,0x22,0x80]
1124 @ CHECK: ldrh.w r7, [sp, r2, lsl #1] @ encoding: [0x3d,0xf8,0x12,0x70]
1125 @ CHECK: ldrh.w r7, [sp, r2] @ encoding: [0x3d,0xf8,0x02,0x70]
1128 @------------------------------------------------------------------------------
1129 @ LDRH(literal)
1130 @------------------------------------------------------------------------------
1131 ldrh r5, _bar
1133 @ CHECK: ldrh.w r5, _bar @ encoding: [0x3f'A',0xf8'A',A,0x50'A']
1134 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
1135 @ CHECK-BE: ldrh.w r5, _bar @ encoding: [0xf8'A',0x3f'A',0x50'A',A]
1136 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
1139 @------------------------------------------------------------------------------
1140 @ LDRHT
1141 @------------------------------------------------------------------------------
1142 ldrht r1, [r2]
1143 ldrht r1, [r8, #0]
1144 ldrht r1, [r8, #3]
1145 ldrht r1, [r8, #255]
1147 @ CHECK: ldrht r1, [r2] @ encoding: [0x32,0xf8,0x00,0x1e]
1148 @ CHECK: ldrht r1, [r8] @ encoding: [0x38,0xf8,0x00,0x1e]
1149 @ CHECK: ldrht r1, [r8, #3] @ encoding: [0x38,0xf8,0x03,0x1e]
1150 @ CHECK: ldrht r1, [r8, #255] @ encoding: [0x38,0xf8,0xff,0x1e]
1153 @------------------------------------------------------------------------------
1154 @ LDRSB(immediate)
1155 @------------------------------------------------------------------------------
1156 ldrsb r5, [r5, #-4]
1157 ldrsb r5, [r6, #32]
1158 ldrsb r5, [r6, #33]
1159 ldrsb r5, [r6, #257]
1160 ldrsb.w lr, [r7, #257]
1162 @ CHECK: ldrsb r5, [r5, #-4] @ encoding: [0x15,0xf9,0x04,0x5c]
1163 @ CHECK: ldrsb.w r5, [r6, #32] @ encoding: [0x96,0xf9,0x20,0x50]
1164 @ CHECK: ldrsb.w r5, [r6, #33] @ encoding: [0x96,0xf9,0x21,0x50]
1165 @ CHECK: ldrsb.w r5, [r6, #257] @ encoding: [0x96,0xf9,0x01,0x51]
1166 @ CHECK: ldrsb.w lr, [r7, #257] @ encoding: [0x97,0xf9,0x01,0xe1]
1169 @------------------------------------------------------------------------------
1170 @ LDRSB(register)
1171 @------------------------------------------------------------------------------
1172 ldrsb r1, [r8, r1]
1173 ldrsb.w r4, [r5, r2]
1174 ldrsb r6, [r0, r2, lsl #3]
1175 ldrsb r8, [r8, r2, lsl #2]
1176 ldrsb r7, [sp, r2, lsl #1]
1177 ldrsb r7, [sp, r2, lsl #0]
1178 ldrsb r5, [r8, #255]!
1179 ldrsb r2, [r5, #4]!
1180 ldrsb r1, [r4, #-4]!
1181 ldrsb lr, [r3], #255
1182 ldrsb r9, [r2], #4
1183 ldrsb r3, [sp], #-4
1185 @ CHECK: ldrsb.w r1, [r8, r1] @ encoding: [0x18,0xf9,0x01,0x10]
1186 @ CHECK: ldrsb.w r4, [r5, r2] @ encoding: [0x15,0xf9,0x02,0x40]
1187 @ CHECK: ldrsb.w r6, [r0, r2, lsl #3] @ encoding: [0x10,0xf9,0x32,0x60]
1188 @ CHECK: ldrsb.w r8, [r8, r2, lsl #2] @ encoding: [0x18,0xf9,0x22,0x80]
1189 @ CHECK: ldrsb.w r7, [sp, r2, lsl #1] @ encoding: [0x1d,0xf9,0x12,0x70]
1190 @ CHECK: ldrsb.w r7, [sp, r2] @ encoding: [0x1d,0xf9,0x02,0x70]
1191 @ CHECK: ldrsb r5, [r8, #255]! @ encoding: [0x18,0xf9,0xff,0x5f]
1192 @ CHECK: ldrsb r2, [r5, #4]! @ encoding: [0x15,0xf9,0x04,0x2f]
1193 @ CHECK: ldrsb r1, [r4, #-4]! @ encoding: [0x14,0xf9,0x04,0x1d]
1194 @ CHECK: ldrsb lr, [r3], #255 @ encoding: [0x13,0xf9,0xff,0xeb]
1195 @ CHECK: ldrsb r9, [r2], #4 @ encoding: [0x12,0xf9,0x04,0x9b]
1196 @ CHECK: ldrsb r3, [sp], #-4 @ encoding: [0x1d,0xf9,0x04,0x39]
1199 @------------------------------------------------------------------------------
1200 @ LDRSB(literal)
1201 @------------------------------------------------------------------------------
1202 ldrsb r5, _bar
1204 @ CHECK: ldrsb.w r5, _bar @ encoding: [0x1f'A',0xf9'A',A,0x50'A']
1205 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
1206 @ CHECK-BE: ldrsb.w r5, _bar @ encoding: [0xf9'A',0x1f'A',0x50'A',A]
1207 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
1210 @------------------------------------------------------------------------------
1211 @ LDRSBT
1212 @------------------------------------------------------------------------------
1213 ldrsbt r1, [r2]
1214 ldrsbt r1, [r8, #0]
1215 ldrsbt r1, [r8, #3]
1216 ldrsbt r1, [r8, #255]
1218 @ CHECK: ldrsbt r1, [r2] @ encoding: [0x12,0xf9,0x00,0x1e]
1219 @ CHECK: ldrsbt r1, [r8] @ encoding: [0x18,0xf9,0x00,0x1e]
1220 @ CHECK: ldrsbt r1, [r8, #3] @ encoding: [0x18,0xf9,0x03,0x1e]
1221 @ CHECK: ldrsbt r1, [r8, #255] @ encoding: [0x18,0xf9,0xff,0x1e]
1224 @------------------------------------------------------------------------------
1225 @ LDRSH(immediate)
1226 @------------------------------------------------------------------------------
1227 ldrsh r5, [r5, #-4]
1228 ldrsh r5, [r6, #32]
1229 ldrsh r5, [r6, #33]
1230 ldrsh r5, [r6, #257]
1231 ldrsh.w lr, [r7, #257]
1233 @ CHECK: ldrsh r5, [r5, #-4] @ encoding: [0x35,0xf9,0x04,0x5c]
1234 @ CHECK: ldrsh.w r5, [r6, #32] @ encoding: [0xb6,0xf9,0x20,0x50]
1235 @ CHECK: ldrsh.w r5, [r6, #33] @ encoding: [0xb6,0xf9,0x21,0x50]
1236 @ CHECK: ldrsh.w r5, [r6, #257] @ encoding: [0xb6,0xf9,0x01,0x51]
1237 @ CHECK: ldrsh.w lr, [r7, #257] @ encoding: [0xb7,0xf9,0x01,0xe1]
1240 @------------------------------------------------------------------------------
1241 @ LDRSH(register)
1242 @------------------------------------------------------------------------------
1243 ldrsh r1, [r8, r1]
1244 ldrsh.w r4, [r5, r2]
1245 ldrsh r6, [r0, r2, lsl #3]
1246 ldrsh r8, [r8, r2, lsl #2]
1247 ldrsh r7, [sp, r2, lsl #1]
1248 ldrsh r7, [sp, r2, lsl #0]
1249 ldrsh r5, [r8, #255]!
1250 ldrsh r2, [r5, #4]!
1251 ldrsh r1, [r4, #-4]!
1252 ldrsh lr, [r3], #255
1253 ldrsh r9, [r2], #4
1254 ldrsh r3, [sp], #-4
1256 @ CHECK: ldrsh.w r1, [r8, r1] @ encoding: [0x38,0xf9,0x01,0x10]
1257 @ CHECK: ldrsh.w r4, [r5, r2] @ encoding: [0x35,0xf9,0x02,0x40]
1258 @ CHECK: ldrsh.w r6, [r0, r2, lsl #3] @ encoding: [0x30,0xf9,0x32,0x60]
1259 @ CHECK: ldrsh.w r8, [r8, r2, lsl #2] @ encoding: [0x38,0xf9,0x22,0x80]
1260 @ CHECK: ldrsh.w r7, [sp, r2, lsl #1] @ encoding: [0x3d,0xf9,0x12,0x70]
1261 @ CHECK: ldrsh.w r7, [sp, r2] @ encoding: [0x3d,0xf9,0x02,0x70]
1262 @ CHECK: ldrsh r5, [r8, #255]! @ encoding: [0x38,0xf9,0xff,0x5f]
1263 @ CHECK: ldrsh r2, [r5, #4]! @ encoding: [0x35,0xf9,0x04,0x2f]
1264 @ CHECK: ldrsh r1, [r4, #-4]! @ encoding: [0x34,0xf9,0x04,0x1d]
1265 @ CHECK: ldrsh lr, [r3], #255 @ encoding: [0x33,0xf9,0xff,0xeb]
1266 @ CHECK: ldrsh r9, [r2], #4 @ encoding: [0x32,0xf9,0x04,0x9b]
1267 @ CHECK: ldrsh r3, [sp], #-4 @ encoding: [0x3d,0xf9,0x04,0x39]
1270 @------------------------------------------------------------------------------
1271 @ LDRSH(literal)
1272 @------------------------------------------------------------------------------
1273 ldrsh r5, _bar
1275 @ CHECK: ldrsh.w r5, _bar @ encoding: [0x3f'A',0xf9'A',A,0x50'A']
1276 @ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
1277 @ CHECK-BE: ldrsh.w r5, _bar @ encoding: [0xf9'A',0x3f'A',0x50'A',A]
1278 @ CHECK-BE: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
1280 @ TEMPORARILY DISABLED:
1281 @ ldrsh.w r4, [pc, #1435]
1282 @ : ldrsh.w r4, [pc, #1435] @ encoding: [0x3f,0xf9,0x9b,0x45]
1284 @------------------------------------------------------------------------------
1285 @ LDRSHT
1286 @------------------------------------------------------------------------------
1287 ldrsht r1, [r2]
1288 ldrsht r1, [r8, #0]
1289 ldrsht r1, [r8, #3]
1290 ldrsht r1, [r8, #255]
1292 @ CHECK: ldrsht r1, [r2] @ encoding: [0x32,0xf9,0x00,0x1e]
1293 @ CHECK: ldrsht r1, [r8] @ encoding: [0x38,0xf9,0x00,0x1e]
1294 @ CHECK: ldrsht r1, [r8, #3] @ encoding: [0x38,0xf9,0x03,0x1e]
1295 @ CHECK: ldrsht r1, [r8, #255] @ encoding: [0x38,0xf9,0xff,0x1e]
1298 @------------------------------------------------------------------------------
1299 @ LDRT
1300 @------------------------------------------------------------------------------
1301 ldrt r1, [r2]
1302 ldrt r2, [r6, #0]
1303 ldrt r3, [r7, #3]
1304 ldrt r4, [r9, #255]
1306 @ CHECK: ldrt r1, [r2] @ encoding: [0x52,0xf8,0x00,0x1e]
1307 @ CHECK: ldrt r2, [r6] @ encoding: [0x56,0xf8,0x00,0x2e]
1308 @ CHECK: ldrt r3, [r7, #3] @ encoding: [0x57,0xf8,0x03,0x3e]
1309 @ CHECK: ldrt r4, [r9, #255] @ encoding: [0x59,0xf8,0xff,0x4e]
1312 @------------------------------------------------------------------------------
1313 @ LSL (immediate)
1314 @------------------------------------------------------------------------------
1315 lsl r2, r3, #12
1316 lsls r8, r3, #31
1317 lsls.w r2, r3, #1
1318 lsl r2, r3, #4
1319 lsls r2, r12, #15
1321 lsl r3, #19
1322 lsls r8, #2
1323 lsls.w r7, #5
1324 lsl.w r12, #21
1326 lsls r1, r2, #1
1327 itt eq
1328 lslseq r1, r2, #1
1329 lsleq r1, r2, #1
1331 @ CHECK: lsl.w r2, r3, #12 @ encoding: [0x4f,0xea,0x03,0x32]
1332 @ CHECK: lsls.w r8, r3, #31 @ encoding: [0x5f,0xea,0xc3,0x78]
1333 @ CHECK: lsls.w r2, r3, #1 @ encoding: [0x5f,0xea,0x43,0x02]
1334 @ CHECK: lsl.w r2, r3, #4 @ encoding: [0x4f,0xea,0x03,0x12]
1335 @ CHECK: lsls.w r2, r12, #15 @ encoding: [0x5f,0xea,0xcc,0x32]
1337 @ CHECK: lsl.w r3, r3, #19 @ encoding: [0x4f,0xea,0xc3,0x43]
1338 @ CHECK: lsls.w r8, r8, #2 @ encoding: [0x5f,0xea,0x88,0x08]
1339 @ CHECK: lsls.w r7, r7, #5 @ encoding: [0x5f,0xea,0x47,0x17]
1340 @ CHECK: lsl.w r12, r12, #21 @ encoding: [0x4f,0xea,0x4c,0x5c]
1342 @ CHECK: lsls r1, r2, #1 @ encoding: [0x51,0x00]
1343 @ CHECK: itt eq @ encoding: [0x04,0xbf]
1344 @ CHECK: lslseq.w r1, r2, #1 @ encoding: [0x5f,0xea,0x42,0x01]
1345 @ CHECK: lsleq r1, r2, #1 @ encoding: [0x51,0x00]
1347 @------------------------------------------------------------------------------
1348 @ LSL (register)
1349 @------------------------------------------------------------------------------
1350 lsl r3, r4, r2
1351 lsl.w r1, r2
1352 lsls r3, r4, r8
1354 @ CHECK: lsl.w r3, r4, r2 @ encoding: [0x04,0xfa,0x02,0xf3]
1355 @ CHECK: lsl.w r1, r1, r2 @ encoding: [0x01,0xfa,0x02,0xf1]
1356 @ CHECK: lsls.w r3, r4, r8 @ encoding: [0x14,0xfa,0x08,0xf3]
1359 @------------------------------------------------------------------------------
1360 @ LSR (immediate)
1361 @------------------------------------------------------------------------------
1362 lsr r2, r3, #12
1363 lsrs r8, r3, #32
1364 lsrs.w r2, r3, #1
1365 lsr r2, r3, #4
1366 lsrs r2, r12, #15
1368 lsr r3, #19
1369 lsrs r8, #2
1370 lsrs.w r7, #5
1371 lsr.w r12, #21
1373 lsrs r1, r2, #1
1374 itt eq
1375 lsrseq r1, r2, #1
1376 lsreq r1, r2, #1
1378 @ CHECK: lsr.w r2, r3, #12 @ encoding: [0x4f,0xea,0x13,0x32]
1379 @ CHECK: lsrs.w r8, r3, #32 @ encoding: [0x5f,0xea,0x13,0x08]
1380 @ CHECK: lsrs.w r2, r3, #1 @ encoding: [0x5f,0xea,0x53,0x02]
1381 @ CHECK: lsr.w r2, r3, #4 @ encoding: [0x4f,0xea,0x13,0x12]
1382 @ CHECK: lsrs.w r2, r12, #15 @ encoding: [0x5f,0xea,0xdc,0x32]
1384 @ CHECK: lsr.w r3, r3, #19 @ encoding: [0x4f,0xea,0xd3,0x43]
1385 @ CHECK: lsrs.w r8, r8, #2 @ encoding: [0x5f,0xea,0x98,0x08]
1386 @ CHECK: lsrs.w r7, r7, #5 @ encoding: [0x5f,0xea,0x57,0x17]
1387 @ CHECK: lsr.w r12, r12, #21 @ encoding: [0x4f,0xea,0x5c,0x5c]
1389 @ CHECK: lsrs r1, r2, #1 @ encoding: [0x51,0x08]
1390 @ CHECK: itt eq @ encoding: [0x04,0xbf]
1391 @ CHECK: lsrseq.w r1, r2, #1 @ encoding: [0x5f,0xea,0x52,0x01]
1392 @ CHECK: lsreq r1, r2, #1 @ encoding: [0x51,0x08]
1394 @------------------------------------------------------------------------------
1395 @ LSR (register)
1396 @------------------------------------------------------------------------------
1397 lsr r3, r4, r2
1398 lsr.w r1, r2
1399 lsrs r3, r4, r8
1401 @ CHECK: lsr.w r3, r4, r2 @ encoding: [0x24,0xfa,0x02,0xf3]
1402 @ CHECK: lsr.w r1, r1, r2 @ encoding: [0x21,0xfa,0x02,0xf1]
1403 @ CHECK: lsrs.w r3, r4, r8 @ encoding: [0x34,0xfa,0x08,0xf3]
1405 @------------------------------------------------------------------------------
1406 @ MCR/MCR2
1407 @------------------------------------------------------------------------------
1408 mcr p7, #1, r5, c1, c1, #4
1409 mcr2 p7, #1, r5, c1, c1, #4
1410 mcr p14, #0, r4, c0, c5
1411 mcr2 p4, #2, r2, c1, c3
1412 MCR P7, #1, R5, C1, C1, #4
1413 MCR2 P7, #1, R5, C1, C1, #4
1414 MCR P14, #0, R4, C0, C5
1415 MCR2 P4, #2, R2, C1, C3
1417 @ CHECK: mcr p7, #1, r5, c1, c1, #4 @ encoding: [0x21,0xee,0x91,0x57]
1418 @ CHECK: mcr2 p7, #1, r5, c1, c1, #4 @ encoding: [0x21,0xfe,0x91,0x57]
1419 @ CHECK: mcr p14, #0, r4, c0, c5, #0 @ encoding: [0x00,0xee,0x15,0x4e]
1420 @ CHECK: mcr2 p4, #2, r2, c1, c3, #0 @ encoding: [0x41,0xfe,0x13,0x24]
1421 @ CHECK: mcr p7, #1, r5, c1, c1, #4 @ encoding: [0x21,0xee,0x91,0x57]
1422 @ CHECK: mcr2 p7, #1, r5, c1, c1, #4 @ encoding: [0x21,0xfe,0x91,0x57]
1423 @ CHECK: mcr p14, #0, r4, c0, c5, #0 @ encoding: [0x00,0xee,0x15,0x4e]
1424 @ CHECK: mcr2 p4, #2, r2, c1, c3, #0 @ encoding: [0x41,0xfe,0x13,0x24]
1427 @------------------------------------------------------------------------------
1428 @ MCRR/MCRR2
1429 @------------------------------------------------------------------------------
1430 mcrr p7, #15, r5, r4, c1
1431 mcrr2 p7, #15, r5, r4, c1
1432 MCRR P7, #15, R5, R4, C1
1433 MCRR2 P7, #15, R5, R4, C1
1435 @ CHECK: mcrr p7, #15, r5, r4, c1 @ encoding: [0x44,0xec,0xf1,0x57]
1436 @ CHECK: mcrr2 p7, #15, r5, r4, c1 @ encoding: [0x44,0xfc,0xf1,0x57]
1437 @ CHECK: mcrr p7, #15, r5, r4, c1 @ encoding: [0x44,0xec,0xf1,0x57]
1438 @ CHECK: mcrr2 p7, #15, r5, r4, c1 @ encoding: [0x44,0xfc,0xf1,0x57]
1441 @------------------------------------------------------------------------------
1442 @ MLA/MLS
1443 @------------------------------------------------------------------------------
1444 mla r1,r2,r3,r4
1445 mls r1,r2,r3,r4
1447 @ CHECK: mla r1, r2, r3, r4 @ encoding: [0x02,0xfb,0x03,0x41]
1448 @ CHECK: mls r1, r2, r3, r4 @ encoding: [0x02,0xfb,0x13,0x41]
1451 @------------------------------------------------------------------------------
1452 @ MOV(immediate)
1453 @------------------------------------------------------------------------------
1454 movs r1, #21
1455 movs.w r1, #21
1456 movs r8, #21
1457 movw r0, #65535
1458 movw r1, #43777
1459 movw r1, #43792
1460 mov.w r0, #0x3fc0000
1461 mov r0, #0x3fc0000
1462 movs.w r0, #0x3fc0000
1463 itte eq
1464 movseq r1, #12
1465 moveq r1, #12
1466 movne.w r1, #12
1467 mov.w r6, #450
1468 it lo
1469 movlo r1, #-1
1471 @ alias for mvn
1472 mov r3, #-3
1473 mov r11, #0xabcd
1474 movs r0, #1
1475 it ne
1476 movne r3, #15
1478 itt eq
1479 moveq r0, #255
1480 moveq r1, #256
1482 @ CHECK: movs r1, #21 @ encoding: [0x15,0x21]
1483 @ CHECK: movs.w r1, #21 @ encoding: [0x5f,0xf0,0x15,0x01]
1484 @ CHECK: movs.w r8, #21 @ encoding: [0x5f,0xf0,0x15,0x08]
1485 @ CHECK: movw r0, #65535 @ encoding: [0x4f,0xf6,0xff,0x70]
1486 @ CHECK: movw r1, #43777 @ encoding: [0x4a,0xf6,0x01,0x31]
1487 @ CHECK: movw r1, #43792 @ encoding: [0x4a,0xf6,0x10,0x31]
1488 @ CHECK: mov.w r0, #66846720 @ encoding: [0x4f,0xf0,0x7f,0x70]
1489 @ CHECK: mov.w r0, #66846720 @ encoding: [0x4f,0xf0,0x7f,0x70]
1490 @ CHECK: movs.w r0, #66846720 @ encoding: [0x5f,0xf0,0x7f,0x70]
1491 @ CHECK: itte eq @ encoding: [0x06,0xbf]
1492 @ CHECK: movseq.w r1, #12 @ encoding: [0x5f,0xf0,0x0c,0x01]
1493 @ CHECK: moveq r1, #12 @ encoding: [0x0c,0x21]
1494 @ CHECK: movne.w r1, #12 @ encoding: [0x4f,0xf0,0x0c,0x01]
1495 @ CHECK: mov.w r6, #450 @ encoding: [0x4f,0xf4,0xe1,0x76]
1496 @ CHECK: it lo @ encoding: [0x38,0xbf]
1497 @ CHECK: movlo.w r1, #-1 @ encoding: [0x4f,0xf0,0xff,0x31]
1498 @ CHECK: mvn r3, #2 @ encoding: [0x6f,0xf0,0x02,0x03]
1499 @ CHECK: movw r11, #43981 @ encoding: [0x4a,0xf6,0xcd,0x3b]
1500 @ CHECK: movs r0, #1 @ encoding: [0x01,0x20]
1501 @ CHECK: it ne @ encoding: [0x18,0xbf]
1502 @ CHECK: movne r3, #15 @ encoding: [0x0f,0x23]
1504 @ CHECK: itt eq @ encoding: [0x04,0xbf]
1505 @ CHECK: moveq r0, #255 @ encoding: [0xff,0x20]
1506 @ CHECK: movweq r1, #256 @ encoding: [0x40,0xf2,0x00,0x11]
1508 @------------------------------------------------------------------------------
1509 @ MOV(shifted register)
1510 @------------------------------------------------------------------------------
1511 mov r6, r2, lsl #16
1512 mov.w r6, r2, lsl #16
1513 mov r6, r2, lsr #16
1514 mov.w r6, r2, lsr #16
1515 movs r6, r2, asr #32
1516 movs.w r6, r2, asr #32
1517 movs r6, r2, ror #5
1518 movs.w r6, r2, ror #5
1519 movs r4, r4, lsl r5
1520 movs.w r4, r4, lsl r5
1521 movs r4, r4, lsr r5
1522 movs.w r4, r4, lsr r5
1523 movs r4, r4, asr r5
1524 movs.w r4, r4, asr r5
1525 movs r4, r4, ror r5
1526 movs.w r4, r4, ror r5
1527 mov r4, r4, lsl r5
1528 movs r4, r4, ror r8
1529 movs r4, r5, lsr r6
1530 itttt eq
1531 moveq r4, r4, lsl r5
1532 moveq r4, r4, lsr r5
1533 moveq r4, r4, asr r5
1534 moveq r4, r4, ror r5
1535 mov r4, r4, rrx
1537 @ CHECK: lsl.w r6, r2, #16 @ encoding: [0x4f,0xea,0x02,0x46]
1538 @ CHECK: lsl.w r6, r2, #16 @ encoding: [0x4f,0xea,0x02,0x46]
1539 @ CHECK: lsr.w r6, r2, #16 @ encoding: [0x4f,0xea,0x12,0x46]
1540 @ CHECK: lsr.w r6, r2, #16 @ encoding: [0x4f,0xea,0x12,0x46]
1541 @ CHECK: asrs r6, r2, #32 @ encoding: [0x16,0x10]
1542 @ CHECK: asrs.w r6, r2, #32 @ encoding: [0x5f,0xea,0x22,0x06]
1543 @ CHECK: rors.w r6, r2, #5 @ encoding: [0x5f,0xea,0x72,0x16]
1544 @ CHECK: rors.w r6, r2, #5 @ encoding: [0x5f,0xea,0x72,0x16]
1545 @ CHECK: lsls r4, r5 @ encoding: [0xac,0x40]
1546 @ CHECK: lsls.w r4, r4, r5 @ encoding: [0x14,0xfa,0x05,0xf4]
1547 @ CHECK: lsrs r4, r5 @ encoding: [0xec,0x40]
1548 @ CHECK: lsrs.w r4, r4, r5 @ encoding: [0x34,0xfa,0x05,0xf4]
1549 @ CHECK: asrs r4, r5 @ encoding: [0x2c,0x41]
1550 @ CHECK: asrs.w r4, r4, r5 @ encoding: [0x54,0xfa,0x05,0xf4]
1551 @ CHECK: rors r4, r5 @ encoding: [0xec,0x41]
1552 @ CHECK: rors.w r4, r4, r5 @ encoding: [0x74,0xfa,0x05,0xf4]
1553 @ CHECK: lsl.w r4, r4, r5 @ encoding: [0x04,0xfa,0x05,0xf4]
1554 @ CHECK: rors.w r4, r4, r8 @ encoding: [0x74,0xfa,0x08,0xf4]
1555 @ CHECK: lsrs.w r4, r5, r6 @ encoding: [0x35,0xfa,0x06,0xf4]
1556 @ CHECK: itttt eq @ encoding: [0x01,0xbf]
1557 @ CHECK: lsleq r4, r5 @ encoding: [0xac,0x40]
1558 @ CHECK: lsreq r4, r5 @ encoding: [0xec,0x40]
1559 @ CHECK: asreq r4, r5 @ encoding: [0x2c,0x41]
1560 @ CHECK: roreq r4, r5 @ encoding: [0xec,0x41]
1561 @ CHECK: rrx r4, r4 @ encoding: [0x4f,0xea,0x34,0x04]
1564 @------------------------------------------------------------------------------
1565 @ MOVT
1566 @------------------------------------------------------------------------------
1567 movt r3, #7
1568 movt r6, #0xffff
1569 it eq
1570 movteq r4, #0xff0
1572 @ CHECK: movt r3, #7 @ encoding: [0xc0,0xf2,0x07,0x03]
1573 @ CHECK: movt r6, #65535 @ encoding: [0xcf,0xf6,0xff,0x76]
1574 @ CHECK: it eq @ encoding: [0x08,0xbf]
1575 @ CHECK: movteq r4, #4080 @ encoding: [0xc0,0xf6,0xf0,0x74]
1577 @------------------------------------------------------------------------------
1578 @ MRC/MRC2
1579 @------------------------------------------------------------------------------
1580 mrc p14, #0, r1, c1, c2, #4
1581 mrc p15, #7, apsr_nzcv, c15, c6, #6
1582 mrc p9, #1, r1, c2, c2
1583 mrc2 p12, #3, r3, c3, c4
1584 mrc2 p14, #0, r1, c1, c2, #4
1585 mrc2 p8, #7, apsr_nzcv, c15, c0, #1
1586 MRC P14, #0, R1, C1, C2, #4
1587 MRC P15, #7, APSR_NZCV, C15, C6, #6
1588 MRC P9, #1, R1, C2, C2
1589 MRC2 P12, #3, R3, C3, C4
1590 MRC2 P14, #0, R1, C1, C2, #4
1591 MRC2 P8, #7, APSR_NZCV, C15, C0, #1
1593 @ CHECK: mrc p14, #0, r1, c1, c2, #4 @ encoding: [0x11,0xee,0x92,0x1e]
1594 @ CHECK: mrc p15, #7, apsr_nzcv, c15, c6, #6 @ encoding: [0xff,0xee,0xd6,0xff]
1595 @ CHECK: mrc p9, #1, r1, c2, c2, #0 @ encoding: [0x32,0xee,0x12,0x19]
1596 @ CHECK: mrc2 p12, #3, r3, c3, c4, #0 @ encoding: [0x73,0xfe,0x14,0x3c]
1597 @ CHECK: mrc2 p14, #0, r1, c1, c2, #4 @ encoding: [0x11,0xfe,0x92,0x1e]
1598 @ CHECK: mrc2 p8, #7, apsr_nzcv, c15, c0, #1 @ encoding: [0xff,0xfe,0x30,0xf8]
1599 @ CHECK: mrc p14, #0, r1, c1, c2, #4 @ encoding: [0x11,0xee,0x92,0x1e]
1600 @ CHECK: mrc p15, #7, apsr_nzcv, c15, c6, #6 @ encoding: [0xff,0xee,0xd6,0xff]
1601 @ CHECK: mrc p9, #1, r1, c2, c2, #0 @ encoding: [0x32,0xee,0x12,0x19]
1602 @ CHECK: mrc2 p12, #3, r3, c3, c4, #0 @ encoding: [0x73,0xfe,0x14,0x3c]
1603 @ CHECK: mrc2 p14, #0, r1, c1, c2, #4 @ encoding: [0x11,0xfe,0x92,0x1e]
1604 @ CHECK: mrc2 p8, #7, apsr_nzcv, c15, c0, #1 @ encoding: [0xff,0xfe,0x30,0xf8]
1606 @------------------------------------------------------------------------------
1607 @ MRRC/MRRC2
1608 @------------------------------------------------------------------------------
1609 mrrc p7, #1, r5, r4, c1
1610 mrrc2 p7, #1, r5, r4, c1
1611 MRRC P7, #1, R5, R4, C1
1612 MRRC2 P7, #1, R5, R4, C1
1614 @ CHECK: mrrc p7, #1, r5, r4, c1 @ encoding: [0x54,0xec,0x11,0x57]
1615 @ CHECK: mrrc2 p7, #1, r5, r4, c1 @ encoding: [0x54,0xfc,0x11,0x57]
1616 @ CHECK: mrrc p7, #1, r5, r4, c1 @ encoding: [0x54,0xec,0x11,0x57]
1617 @ CHECK: mrrc2 p7, #1, r5, r4, c1 @ encoding: [0x54,0xfc,0x11,0x57]
1620 @------------------------------------------------------------------------------
1621 @ MRS
1622 @------------------------------------------------------------------------------
1623 mrs r8, apsr
1624 mrs r8, cpsr
1625 mrs r8, spsr
1627 @ CHECK: mrs r8, apsr @ encoding: [0xef,0xf3,0x00,0x88]
1628 @ CHECK: mrs r8, apsr @ encoding: [0xef,0xf3,0x00,0x88]
1629 @ CHECK: mrs r8, spsr @ encoding: [0xff,0xf3,0x00,0x88]
1632 @------------------------------------------------------------------------------
1633 @ MSR
1634 @------------------------------------------------------------------------------
1635 msr apsr, r1
1636 msr apsr_g, r2
1637 msr apsr_nzcvq, r3
1638 msr APSR_nzcvq, r4
1639 msr apsr_nzcvqg, r5
1640 msr cpsr_fc, r6
1641 msr cpsr_c, r7
1642 msr cpsr_x, r8
1643 msr cpsr_fc, r9
1644 msr cpsr_all, r11
1645 msr cpsr_fsx, r12
1646 msr spsr_fc, r0
1647 msr SPSR_fsxc, r5
1648 msr cpsr_fsxc, r8
1649 msr cpsr, r3
1651 @ CHECK: msr APSR_nzcvq, r1 @ encoding: [0x81,0xf3,0x00,0x88]
1652 @ CHECK: msr APSR_g, r2 @ encoding: [0x82,0xf3,0x00,0x84]
1653 @ CHECK: msr APSR_nzcvq, r3 @ encoding: [0x83,0xf3,0x00,0x88]
1654 @ CHECK: msr APSR_nzcvq, r4 @ encoding: [0x84,0xf3,0x00,0x88]
1655 @ CHECK: msr APSR_nzcvqg, r5 @ encoding: [0x85,0xf3,0x00,0x8c]
1656 @ CHECK: msr CPSR_fc, r6 @ encoding: [0x86,0xf3,0x00,0x89]
1657 @ CHECK: msr CPSR_c, r7 @ encoding: [0x87,0xf3,0x00,0x81]
1658 @ CHECK: msr CPSR_x, r8 @ encoding: [0x88,0xf3,0x00,0x82]
1659 @ CHECK: msr CPSR_fc, r9 @ encoding: [0x89,0xf3,0x00,0x89]
1660 @ CHECK: msr CPSR_fc, r11 @ encoding: [0x8b,0xf3,0x00,0x89]
1661 @ CHECK: msr CPSR_fsx, r12 @ encoding: [0x8c,0xf3,0x00,0x8e]
1662 @ CHECK: msr SPSR_fc, r0 @ encoding: [0x90,0xf3,0x00,0x89]
1663 @ CHECK: msr SPSR_fsxc, r5 @ encoding: [0x95,0xf3,0x00,0x8f]
1664 @ CHECK: msr CPSR_fsxc, r8 @ encoding: [0x88,0xf3,0x00,0x8f]
1665 @ CHECK: msr CPSR_fc, r3 @ encoding: [0x83,0xf3,0x00,0x89]
1668 @------------------------------------------------------------------------------
1669 @ MUL
1670 @------------------------------------------------------------------------------
1671 muls r3, r4, r3
1672 mul r3, r4, r3
1673 mul r3, r4, r6
1674 it eq
1675 muleq r3, r4, r5
1676 it le
1677 mulle r4, r4, r8
1678 mul r5, r6
1680 @ CHECK: muls r3, r4, r3 @ encoding: [0x63,0x43]
1681 @ CHECK: mul r3, r4, r3 @ encoding: [0x04,0xfb,0x03,0xf3]
1682 @ CHECK: mul r3, r4, r6 @ encoding: [0x04,0xfb,0x06,0xf3]
1683 @ CHECK: it eq @ encoding: [0x08,0xbf]
1684 @ CHECK: muleq r3, r4, r5 @ encoding: [0x04,0xfb,0x05,0xf3]
1685 @ CHECK: it le @ encoding: [0xd8,0xbf]
1686 @ CHECK: mulle r4, r4, r8 @ encoding: [0x04,0xfb,0x08,0xf4]
1687 @ CHECK: mul r5, r6, r5 @ encoding: [0x06,0xfb,0x05,0xf5]
1690 @------------------------------------------------------------------------------
1691 @ MVN(immediate)
1692 @------------------------------------------------------------------------------
1693 mvns r8, #21
1694 mvn r0, #0x3fc0000
1695 mvns r0, #0x3fc0000
1696 itte eq
1697 mvnseq r1, #12
1698 mvneq.w r1, #12
1699 mvnne r1, #12
1701 @ CHECK: mvns r8, #21 @ encoding: [0x7f,0xf0,0x15,0x08]
1702 @ CHECK: mvn r0, #66846720 @ encoding: [0x6f,0xf0,0x7f,0x70]
1703 @ CHECK: mvns r0, #66846720 @ encoding: [0x7f,0xf0,0x7f,0x70]
1704 @ CHECK: itte eq @ encoding: [0x06,0xbf]
1705 @ CHECK: mvnseq r1, #12 @ encoding: [0x7f,0xf0,0x0c,0x01]
1706 @ CHECK: mvneq r1, #12 @ encoding: [0x6f,0xf0,0x0c,0x01]
1707 @ CHECK: mvnne r1, #12 @ encoding: [0x6f,0xf0,0x0c,0x01]
1710 @------------------------------------------------------------------------------
1711 @ MVN(register)
1712 @------------------------------------------------------------------------------
1713 mvn r2, r3
1714 mvns r2, r3
1715 mvn r5, r6, lsl #19
1716 mvn r5, r6, lsr #9
1717 mvn.w r5, r6, asr #4
1718 mvn r5, r6, ror #6
1719 mvn r5, r6, rrx
1720 it eq
1721 mvneq r2, r3
1723 @ CHECK: mvn.w r2, r3 @ encoding: [0x6f,0xea,0x03,0x02]
1724 @ CHECK: mvns r2, r3 @ encoding: [0xda,0x43]
1725 @ CHECK: mvn.w r5, r6, lsl #19 @ encoding: [0x6f,0xea,0xc6,0x45]
1726 @ CHECK: mvn.w r5, r6, lsr #9 @ encoding: [0x6f,0xea,0x56,0x25]
1727 @ CHECK: mvn.w r5, r6, asr #4 @ encoding: [0x6f,0xea,0x26,0x15]
1728 @ CHECK: mvn.w r5, r6, ror #6 @ encoding: [0x6f,0xea,0xb6,0x15]
1729 @ CHECK: mvn.w r5, r6, rrx @ encoding: [0x6f,0xea,0x36,0x05]
1730 @ CHECK: it eq @ encoding: [0x08,0xbf]
1731 @ CHECK: mvneq r2, r3 @ encoding: [0xda,0x43]
1733 @------------------------------------------------------------------------------
1734 @ NEG
1735 @------------------------------------------------------------------------------
1736 neg r5, r2
1737 neg r5, r8
1739 @ CHECK: rsb.w r5, r2, #0 @ encoding: [0xc2,0xf1,0x00,0x05]
1740 @ CHECK: rsb.w r5, r8, #0 @ encoding: [0xc8,0xf1,0x00,0x05]
1743 @------------------------------------------------------------------------------
1744 @ NOP
1745 @------------------------------------------------------------------------------
1746 nop.w
1748 @ CHECK: nop.w @ encoding: [0xaf,0xf3,0x00,0x80]
1751 @------------------------------------------------------------------------------
1752 @ ORN
1753 @------------------------------------------------------------------------------
1754 orn r4, r5, #0xf000
1755 orn r4, r5, r6
1756 orns r4, r5, r6
1757 orn r4, r5, r6, lsl #5
1758 orns r4, r5, r6, lsr #5
1759 orn r4, r5, r6, lsr #5
1760 orns r4, r5, r6, asr #5
1761 orn r4, r5, r6, ror #5
1763 @ CHECK: orn r4, r5, #61440 @ encoding: [0x65,0xf4,0x70,0x44]
1764 @ CHECK: orn r4, r5, r6 @ encoding: [0x65,0xea,0x06,0x04]
1765 @ CHECK: orns r4, r5, r6 @ encoding: [0x75,0xea,0x06,0x04]
1766 @ CHECK: orn r4, r5, r6, lsl #5 @ encoding: [0x65,0xea,0x46,0x14]
1767 @ CHECK: orns r4, r5, r6, lsr #5 @ encoding: [0x75,0xea,0x56,0x14]
1768 @ CHECK: orn r4, r5, r6, lsr #5 @ encoding: [0x65,0xea,0x56,0x14]
1769 @ CHECK: orns r4, r5, r6, asr #5 @ encoding: [0x75,0xea,0x66,0x14]
1770 @ CHECK: orn r4, r5, r6, ror #5 @ encoding: [0x65,0xea,0x76,0x14]
1773 @------------------------------------------------------------------------------
1774 @ ORR
1775 @------------------------------------------------------------------------------
1776 orr r4, r5, #0xf000
1777 orr r4, r5, r6
1778 orr r4, r5, r6, lsl #5
1779 orrs r4, r5, r6, lsr #5
1780 orr r4, r5, r6, lsr #5
1781 orrs r4, r5, r6, asr #5
1782 orr r4, r5, r6, ror #5
1784 @ CHECK: orr r4, r5, #61440 @ encoding: [0x45,0xf4,0x70,0x44]
1785 @ CHECK: orr.w r4, r5, r6 @ encoding: [0x45,0xea,0x06,0x04]
1786 @ CHECK: orr.w r4, r5, r6, lsl #5 @ encoding: [0x45,0xea,0x46,0x14]
1787 @ CHECK: orrs.w r4, r5, r6, lsr #5 @ encoding: [0x55,0xea,0x56,0x14]
1788 @ CHECK: orr.w r4, r5, r6, lsr #5 @ encoding: [0x45,0xea,0x56,0x14]
1789 @ CHECK: orrs.w r4, r5, r6, asr #5 @ encoding: [0x55,0xea,0x66,0x14]
1790 @ CHECK: orr.w r4, r5, r6, ror #5 @ encoding: [0x45,0xea,0x76,0x14]
1793 @------------------------------------------------------------------------------
1794 @ PKH
1795 @------------------------------------------------------------------------------
1796 pkhbt r2, r2, r3
1797 pkhbt r2, r2, r3, lsl #31
1798 pkhbt r2, r2, r3, lsl #0
1799 pkhbt r2, r2, r3, lsl #15
1801 pkhtb r2, r2, r3
1802 pkhtb r2, r2, r3, asr #31
1803 pkhtb r2, r2, r3, asr #15
1805 @ CHECK: pkhbt r2, r2, r3 @ encoding: [0xc2,0xea,0x03,0x02]
1806 @ CHECK: pkhbt r2, r2, r3, lsl #31 @ encoding: [0xc2,0xea,0xc3,0x72]
1807 @ CHECK: pkhbt r2, r2, r3 @ encoding: [0xc2,0xea,0x03,0x02]
1808 @ CHECK: pkhbt r2, r2, r3, lsl #15 @ encoding: [0xc2,0xea,0xc3,0x32]
1810 @ CHECK: pkhbt r2, r3, r2 @ encoding: [0xc3,0xea,0x02,0x02]
1811 @ CHECK: pkhtb r2, r2, r3, asr #31 @ encoding: [0xc2,0xea,0xe3,0x72]
1812 @ CHECK: pkhtb r2, r2, r3, asr #15 @ encoding: [0xc2,0xea,0xe3,0x32]
1815 @------------------------------------------------------------------------------
1816 @ PLD(immediate)
1817 @------------------------------------------------------------------------------
1818 pld [r5, #-4]
1819 pld [r6, #32]
1820 pld [r6, #33]
1821 pld [r6, #257]
1822 pld [r7, #257]
1823 pld [r1, #0]
1824 pld [r1, #-0]
1826 @ CHECK: pld [r5, #-4] @ encoding: [0x15,0xf8,0x04,0xfc]
1827 @ CHECK: pld [r6, #32] @ encoding: [0x96,0xf8,0x20,0xf0]
1828 @ CHECK: pld [r6, #33] @ encoding: [0x96,0xf8,0x21,0xf0]
1829 @ CHECK: pld [r6, #257] @ encoding: [0x96,0xf8,0x01,0xf1]
1830 @ CHECK: pld [r7, #257] @ encoding: [0x97,0xf8,0x01,0xf1]
1831 @ CHECK: pld [r1] @ encoding: [0x91,0xf8,0x00,0xf0]
1832 @ CHECK: pld [r1, #-0] @ encoding: [0x11,0xf8,0x00,0xfc]
1835 @------------------------------------------------------------------------------
1836 @ PLD(literal)
1837 @------------------------------------------------------------------------------
1838 @ pld _foo
1840 @ FIXME: pld _foo @ encoding: [0x9f'A',0xf8'A',A,0xf0'A']
1841 @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
1843 pld [pc,#-4095]
1844 @ CHECK: pld [pc, #-4095] @ encoding: [0x1f,0xf8,0xff,0xff]
1847 @------------------------------------------------------------------------------
1848 @ PLD(register)
1849 @------------------------------------------------------------------------------
1850 pld [r8, r1]
1851 pld [r5, r2]
1852 pld [r0, r2, lsl #3]
1853 pld [r8, r2, lsl #2]
1854 pld [sp, r2, lsl #1]
1855 pld [sp, r2, lsl #0]
1857 @ CHECK: pld [r8, r1] @ encoding: [0x18,0xf8,0x01,0xf0]
1858 @ CHECK: pld [r5, r2] @ encoding: [0x15,0xf8,0x02,0xf0]
1859 @ CHECK: pld [r0, r2, lsl #3] @ encoding: [0x10,0xf8,0x32,0xf0]
1860 @ CHECK: pld [r8, r2, lsl #2] @ encoding: [0x18,0xf8,0x22,0xf0]
1861 @ CHECK: pld [sp, r2, lsl #1] @ encoding: [0x1d,0xf8,0x12,0xf0]
1862 @ CHECK: pld [sp, r2] @ encoding: [0x1d,0xf8,0x02,0xf0]
1864 @------------------------------------------------------------------------------
1865 @ PLI(immediate)
1866 @------------------------------------------------------------------------------
1867 pli [r5, #-4]
1868 pli [r6, #32]
1869 pli [r6, #33]
1870 pli [r6, #257]
1871 pli [r7, #257]
1872 pli [pc, #+4095]
1873 pli [pc, #-4095]
1875 @ CHECK: pli [r5, #-4] @ encoding: [0x15,0xf9,0x04,0xfc]
1876 @ CHECK: pli [r6, #32] @ encoding: [0x96,0xf9,0x20,0xf0]
1877 @ CHECK: pli [r6, #33] @ encoding: [0x96,0xf9,0x21,0xf0]
1878 @ CHECK: pli [r6, #257] @ encoding: [0x96,0xf9,0x01,0xf1]
1879 @ CHECK: pli [r7, #257] @ encoding: [0x97,0xf9,0x01,0xf1]
1880 @ CHECK: pli [pc, #4095] @ encoding: [0x9f,0xf9,0xff,0xff]
1881 @ CHECK: pli [pc, #-4095] @ encoding: [0x1f,0xf9,0xff,0xff]
1884 @------------------------------------------------------------------------------
1885 @ PLI(literal)
1886 @------------------------------------------------------------------------------
1887 @ pli _foo
1890 @ FIXME: pli _foo @ encoding: [0x9f'A',0xf9'A',A,0xf0'A']
1891 @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
1894 @------------------------------------------------------------------------------
1895 @ PLI(register)
1896 @------------------------------------------------------------------------------
1897 pli [r8, r1]
1898 pli [r5, r2]
1899 pli [r0, r2, lsl #3]
1900 pli [r8, r2, lsl #2]
1901 pli [sp, r2, lsl #1]
1902 pli [sp, r2, lsl #0]
1904 @ CHECK: pli [r8, r1] @ encoding: [0x18,0xf9,0x01,0xf0]
1905 @ CHECK: pli [r5, r2] @ encoding: [0x15,0xf9,0x02,0xf0]
1906 @ CHECK: pli [r0, r2, lsl #3] @ encoding: [0x10,0xf9,0x32,0xf0]
1907 @ CHECK: pli [r8, r2, lsl #2] @ encoding: [0x18,0xf9,0x22,0xf0]
1908 @ CHECK: pli [sp, r2, lsl #1] @ encoding: [0x1d,0xf9,0x12,0xf0]
1909 @ CHECK: pli [sp, r2] @ encoding: [0x1d,0xf9,0x02,0xf0]
1911 @------------------------------------------------------------------------------
1912 @ POP (alias)
1913 @------------------------------------------------------------------------------
1914 pop {r2, r9}
1916 @ CHECK: pop.w {r2, r9} @ encoding: [0xbd,0xe8,0x04,0x02]
1919 @------------------------------------------------------------------------------
1920 @ PUSH (alias)
1921 @------------------------------------------------------------------------------
1922 push {r2, r9}
1924 @ CHECK: push.w {r2, r9} @ encoding: [0x2d,0xe9,0x04,0x02]
1927 @------------------------------------------------------------------------------
1928 @ QADD/QADD16/QADD8
1929 @------------------------------------------------------------------------------
1930 qadd r1, r2, r3
1931 qadd16 r1, r2, r3
1932 qadd8 r1, r2, r3
1933 itte gt
1934 qaddgt r1, r2, r3
1935 qadd16gt r1, r2, r3
1936 qadd8le r1, r2, r3
1938 @ CHECK: qadd r1, r2, r3 @ encoding: [0x83,0xfa,0x82,0xf1]
1939 @ CHECK: qadd16 r1, r2, r3 @ encoding: [0x92,0xfa,0x13,0xf1]
1940 @ CHECK: qadd8 r1, r2, r3 @ encoding: [0x82,0xfa,0x13,0xf1]
1941 @ CHECK: itte gt @ encoding: [0xc6,0xbf]
1942 @ CHECK: qaddgt r1, r2, r3 @ encoding: [0x83,0xfa,0x82,0xf1]
1943 @ CHECK: qadd16gt r1, r2, r3 @ encoding: [0x92,0xfa,0x13,0xf1]
1944 @ CHECK: qadd8le r1, r2, r3 @ encoding: [0x82,0xfa,0x13,0xf1]
1947 @------------------------------------------------------------------------------
1948 @ QDADD/QDSUB
1949 @------------------------------------------------------------------------------
1950 qdadd r6, r7, r8
1951 qdsub r6, r7, r8
1952 itt hi
1953 qdaddhi r6, r7, r8
1954 qdsubhi r6, r7, r8
1956 @ CHECK: qdadd r6, r7, r8 @ encoding: [0x88,0xfa,0x97,0xf6]
1957 @ CHECK: qdsub r6, r7, r8 @ encoding: [0x88,0xfa,0xb7,0xf6]
1958 @ CHECK: itt hi @ encoding: [0x84,0xbf]
1959 @ CHECK: qdaddhi r6, r7, r8 @ encoding: [0x88,0xfa,0x97,0xf6]
1960 @ CHECK: qdsubhi r6, r7, r8 @ encoding: [0x88,0xfa,0xb7,0xf6]
1963 @------------------------------------------------------------------------------
1964 @ QSAX
1965 @------------------------------------------------------------------------------
1966 qsax r9, r12, r0
1967 it eq
1968 qsaxeq r9, r12, r0
1970 @ CHECK: qsax r9, r12, r0 @ encoding: [0xec,0xfa,0x10,0xf9]
1971 @ CHECK: it eq @ encoding: [0x08,0xbf]
1972 @ CHECK: qsaxeq r9, r12, r0 @ encoding: [0xec,0xfa,0x10,0xf9]
1975 @------------------------------------------------------------------------------
1976 @ QSUB/QSUB16/QSUB8
1977 @------------------------------------------------------------------------------
1978 qsub r1, r2, r3
1979 qsub16 r1, r2, r3
1980 qsub8 r1, r2, r3
1981 itet le
1982 qsuble r1, r2, r3
1983 qsub16gt r1, r2, r3
1984 qsub8le r1, r2, r3
1986 @ CHECK: qsub r1, r2, r3 @ encoding: [0x83,0xfa,0xa2,0xf1]
1987 @ CHECK: qsub16 r1, r2, r3 @ encoding: [0xd2,0xfa,0x13,0xf1]
1988 @ CHECK: qsub8 r1, r2, r3 @ encoding: [0xc2,0xfa,0x13,0xf1]
1989 @ CHECK: itet le @ encoding: [0xd6,0xbf]
1990 @ CHECK: qsuble r1, r2, r3 @ encoding: [0x83,0xfa,0xa2,0xf1]
1991 @ CHECK: qsub16gt r1, r2, r3 @ encoding: [0xd2,0xfa,0x13,0xf1]
1992 @ CHECK: qsub8le r1, r2, r3 @ encoding: [0xc2,0xfa,0x13,0xf1]
1995 @------------------------------------------------------------------------------
1996 @ RBIT
1997 @------------------------------------------------------------------------------
1998 rbit r1, r2
1999 it ne
2000 rbitne r1, r2
2002 @ CHECK: rbit r1, r2 @ encoding: [0x92,0xfa,0xa2,0xf1]
2003 @ CHECK: it ne @ encoding: [0x18,0xbf]
2004 @ CHECK: rbitne r1, r2 @ encoding: [0x92,0xfa,0xa2,0xf1]
2007 @------------------------------------------------------------------------------
2008 @ REV
2009 @------------------------------------------------------------------------------
2010 rev.w r1, r2
2011 rev r2, r8
2012 itt ne
2013 revne r1, r2
2014 revne r1, r8
2016 @ CHECK: rev.w r1, r2 @ encoding: [0x92,0xfa,0x82,0xf1]
2017 @ CHECK: rev.w r2, r8 @ encoding: [0x98,0xfa,0x88,0xf2]
2018 @ CHECK: itt ne @ encoding: [0x1c,0xbf]
2019 @ CHECK: revne r1, r2 @ encoding: [0x11,0xba]
2020 @ CHECK: revne.w r1, r8 @ encoding: [0x98,0xfa,0x88,0xf1]
2023 @------------------------------------------------------------------------------
2024 @ REV16
2025 @------------------------------------------------------------------------------
2026 rev16.w r1, r2
2027 rev16 r2, r8
2028 itt ne
2029 rev16ne r1, r2
2030 rev16ne r1, r8
2032 @ CHECK: rev16.w r1, r2 @ encoding: [0x92,0xfa,0x92,0xf1]
2033 @ CHECK: rev16.w r2, r8 @ encoding: [0x98,0xfa,0x98,0xf2]
2034 @ CHECK: itt ne @ encoding: [0x1c,0xbf]
2035 @ CHECK: rev16ne r1, r2 @ encoding: [0x51,0xba]
2036 @ CHECK: rev16ne.w r1, r8 @ encoding: [0x98,0xfa,0x98,0xf1]
2039 @------------------------------------------------------------------------------
2040 @ REVSH
2041 @------------------------------------------------------------------------------
2042 revsh.w r1, r2
2043 revsh r2, r8
2044 itt ne
2045 revshne r1, r2
2046 revshne r1, r8
2048 @ CHECK: revsh.w r1, r2 @ encoding: [0x92,0xfa,0xb2,0xf1]
2049 @ CHECK: revsh.w r2, r8 @ encoding: [0x98,0xfa,0xb8,0xf2]
2050 @ CHECK: itt ne @ encoding: [0x1c,0xbf]
2051 @ CHECK: revshne r1, r2 @ encoding: [0xd1,0xba]
2052 @ CHECK: revshne.w r1, r8 @ encoding: [0x98,0xfa,0xb8,0xf1]
2055 @------------------------------------------------------------------------------
2056 @ ROR (immediate)
2057 @------------------------------------------------------------------------------
2058 ror r2, r3, #12
2059 rors r8, r3, #31
2060 rors.w r2, r3, #1
2061 ror r2, r3, #4
2062 rors r2, r12, #15
2064 ror r3, #19
2065 rors r8, #2
2066 rors.w r7, #5
2067 ror.w r12, #21
2069 @ CHECK: ror.w r2, r3, #12 @ encoding: [0x4f,0xea,0x33,0x32]
2070 @ CHECK: rors.w r8, r3, #31 @ encoding: [0x5f,0xea,0xf3,0x78]
2071 @ CHECK: rors.w r2, r3, #1 @ encoding: [0x5f,0xea,0x73,0x02]
2072 @ CHECK: ror.w r2, r3, #4 @ encoding: [0x4f,0xea,0x33,0x12]
2073 @ CHECK: rors.w r2, r12, #15 @ encoding: [0x5f,0xea,0xfc,0x32]
2075 @ CHECK: ror.w r3, r3, #19 @ encoding: [0x4f,0xea,0xf3,0x43]
2076 @ CHECK: rors.w r8, r8, #2 @ encoding: [0x5f,0xea,0xb8,0x08]
2077 @ CHECK: rors.w r7, r7, #5 @ encoding: [0x5f,0xea,0x77,0x17]
2078 @ CHECK: ror.w r12, r12, #21 @ encoding: [0x4f,0xea,0x7c,0x5c]
2081 @------------------------------------------------------------------------------
2082 @ ROR (register)
2083 @------------------------------------------------------------------------------
2084 ror r3, r4, r2
2085 ror.w r1, r2
2086 rors r3, r4, r8
2088 @ CHECK: ror.w r3, r4, r2 @ encoding: [0x64,0xfa,0x02,0xf3]
2089 @ CHECK: ror.w r1, r1, r2 @ encoding: [0x61,0xfa,0x02,0xf1]
2090 @ CHECK: rors.w r3, r4, r8 @ encoding: [0x74,0xfa,0x08,0xf3]
2093 @------------------------------------------------------------------------------
2094 @ RRX
2095 @------------------------------------------------------------------------------
2096 rrx r1, r2
2097 rrxs r1, r2
2098 ite lt
2099 rrxlt r9, r12
2100 rrxsge r8, r3
2102 @ CHECK: rrx r1, r2 @ encoding: [0x4f,0xea,0x32,0x01]
2103 @ CHECK: rrxs r1, r2 @ encoding: [0x5f,0xea,0x32,0x01]
2104 @ CHECK: ite lt @ encoding: [0xb4,0xbf]
2105 @ CHECK: rrxlt r9, r12 @ encoding: [0x4f,0xea,0x3c,0x09]
2106 @ CHECK: rrxsge r8, r3 @ encoding: [0x5f,0xea,0x33,0x08]
2108 @------------------------------------------------------------------------------
2109 @ RSB (immediate)
2110 @------------------------------------------------------------------------------
2111 rsb r2, r5, #0xff000
2112 rsbs r3, r12, #0xf
2113 rsb r1, #0xff
2114 rsb r1, r1, #0xff
2115 rsb r11, r11, #0
2116 rsb r9, #0
2117 rsbs r3, r1, #0
2118 rsb r3, r1, #0
2120 @ CHECK: rsb.w r2, r5, #1044480 @ encoding: [0xc5,0xf5,0x7f,0x22]
2121 @ CHECK: rsbs.w r3, r12, #15 @ encoding: [0xdc,0xf1,0x0f,0x03]
2122 @ CHECK: rsb.w r1, r1, #255 @ encoding: [0xc1,0xf1,0xff,0x01]
2123 @ CHECK: rsb.w r1, r1, #255 @ encoding: [0xc1,0xf1,0xff,0x01]
2124 @ CHECK: rsb.w r11, r11, #0 @ encoding: [0xcb,0xf1,0x00,0x0b]
2125 @ CHECK: rsb.w r9, r9, #0 @ encoding: [0xc9,0xf1,0x00,0x09]
2126 @ CHECK: rsbs r3, r1, #0 @ encoding: [0x4b,0x42]
2127 @ CHECK: rsb.w r3, r1, #0 @ encoding: [0xc1,0xf1,0x00,0x03]
2130 @------------------------------------------------------------------------------
2131 @ RSB (register)
2132 @------------------------------------------------------------------------------
2133 rsb r4, r8
2134 rsb r4, r9, r8
2135 rsb r1, r4, r8, asr #3
2136 rsbs r2, r1, r7, lsl #1
2138 @ CHECK: rsb r4, r4, r8 @ encoding: [0xc4,0xeb,0x08,0x04]
2139 @ CHECK: rsb r4, r9, r8 @ encoding: [0xc9,0xeb,0x08,0x04]
2140 @ CHECK: rsb r1, r4, r8, asr #3 @ encoding: [0xc4,0xeb,0xe8,0x01]
2141 @ CHECK: rsbs r2, r1, r7, lsl #1 @ encoding: [0xd1,0xeb,0x47,0x02]
2144 @------------------------------------------------------------------------------
2145 @ SADD16
2146 @------------------------------------------------------------------------------
2147 sadd16 r3, r4, r8
2148 it ne
2149 sadd16ne r3, r4, r8
2151 @ CHECK: sadd16 r3, r4, r8 @ encoding: [0x94,0xfa,0x08,0xf3]
2152 @ CHECK: it ne @ encoding: [0x18,0xbf]
2153 @ CHECK: sadd16ne r3, r4, r8 @ encoding: [0x94,0xfa,0x08,0xf3]
2156 @------------------------------------------------------------------------------
2157 @ SADD8
2158 @------------------------------------------------------------------------------
2159 sadd8 r3, r4, r8
2160 it ne
2161 sadd8ne r3, r4, r8
2163 @ CHECK: sadd8 r3, r4, r8 @ encoding: [0x84,0xfa,0x08,0xf3]
2164 @ CHECK: it ne @ encoding: [0x18,0xbf]
2165 @ CHECK: sadd8ne r3, r4, r8 @ encoding: [0x84,0xfa,0x08,0xf3]
2168 @------------------------------------------------------------------------------
2169 @ SASX
2170 @------------------------------------------------------------------------------
2171 saddsubx r9, r2, r7
2172 it ne
2173 saddsubxne r2, r5, r6
2174 sasx r9, r2, r7
2175 it ne
2176 sasxne r2, r5, r6
2178 @ CHECK: sasx r9, r2, r7 @ encoding: [0xa2,0xfa,0x07,0xf9]
2179 @ CHECK: it ne @ encoding: [0x18,0xbf]
2180 @ CHECK: sasxne r2, r5, r6 @ encoding: [0xa5,0xfa,0x06,0xf2]
2181 @ CHECK: sasx r9, r2, r7 @ encoding: [0xa2,0xfa,0x07,0xf9]
2182 @ CHECK: it ne @ encoding: [0x18,0xbf]
2183 @ CHECK: sasxne r2, r5, r6 @ encoding: [0xa5,0xfa,0x06,0xf2]
2186 @------------------------------------------------------------------------------
2187 @ SBC (immediate)
2188 @------------------------------------------------------------------------------
2189 sbc r0, r1, #4
2190 sbcs r0, r1, #0
2191 sbc r1, r2, #255
2192 sbc r3, r7, #0x00550055
2193 sbc r8, r12, #0xaa00aa00
2194 sbc r9, r7, #0xa5a5a5a5
2195 sbc r5, r3, #0x87000000
2196 sbc r4, r2, #0x7f800000
2197 sbc r4, r2, #0x00000680
2199 @ CHECK: sbc r0, r1, #4 @ encoding: [0x61,0xf1,0x04,0x00]
2200 @ CHECK: sbcs r0, r1, #0 @ encoding: [0x71,0xf1,0x00,0x00]
2201 @ CHECK: sbc r1, r2, #255 @ encoding: [0x62,0xf1,0xff,0x01]
2202 @ CHECK: sbc r3, r7, #5570645 @ encoding: [0x67,0xf1,0x55,0x13]
2203 @ CHECK: sbc r8, r12, #2852170240 @ encoding: [0x6c,0xf1,0xaa,0x28]
2204 @ CHECK: sbc r9, r7, #2779096485 @ encoding: [0x67,0xf1,0xa5,0x39]
2205 @ CHECK: sbc r5, r3, #2264924160 @ encoding: [0x63,0xf1,0x07,0x45]
2206 @ CHECK: sbc r4, r2, #2139095040 @ encoding: [0x62,0xf1,0xff,0x44]
2207 @ CHECK: sbc r4, r2, #1664 @ encoding: [0x62,0xf5,0xd0,0x64]
2210 @------------------------------------------------------------------------------
2211 @ SBC (register)
2212 @------------------------------------------------------------------------------
2213 sbc r4, r5, r6
2214 sbcs r4, r5, r6
2215 sbc.w r9, r1, r3
2216 sbcs.w r9, r1, r3
2217 sbc r0, r1, r3, ror #4
2218 sbcs r0, r1, r3, lsl #7
2219 sbc.w r0, r1, r3, lsr #31
2220 sbcs.w r0, r1, r3, asr #32
2222 @ CHECK: sbc.w r4, r5, r6 @ encoding: [0x65,0xeb,0x06,0x04]
2223 @ CHECK: sbcs.w r4, r5, r6 @ encoding: [0x75,0xeb,0x06,0x04]
2224 @ CHECK: sbc.w r9, r1, r3 @ encoding: [0x61,0xeb,0x03,0x09]
2225 @ CHECK: sbcs.w r9, r1, r3 @ encoding: [0x71,0xeb,0x03,0x09]
2226 @ CHECK: sbc.w r0, r1, r3, ror #4 @ encoding: [0x61,0xeb,0x33,0x10]
2227 @ CHECK: sbcs.w r0, r1, r3, lsl #7 @ encoding: [0x71,0xeb,0xc3,0x10]
2228 @ CHECK: sbc.w r0, r1, r3, lsr #31 @ encoding: [0x61,0xeb,0xd3,0x70]
2229 @ CHECK: sbcs.w r0, r1, r3, asr #32 @ encoding: [0x71,0xeb,0x23,0x00]
2232 @------------------------------------------------------------------------------
2233 @ SBFX
2234 @------------------------------------------------------------------------------
2235 sbfx r4, r5, #16, #1
2236 it gt
2237 sbfxgt r4, r5, #16, #16
2239 @ CHECK: sbfx r4, r5, #16, #1 @ encoding: [0x45,0xf3,0x00,0x44]
2240 @ CHECK: it gt @ encoding: [0xc8,0xbf]
2241 @ CHECK: sbfxgt r4, r5, #16, #16 @ encoding: [0x45,0xf3,0x0f,0x44]
2244 @------------------------------------------------------------------------------
2245 @ SEL
2246 @------------------------------------------------------------------------------
2247 sel r5, r9, r2
2248 it le
2249 selle r5, r9, r2
2251 @ CHECK: sel r5, r9, r2 @ encoding: [0xa9,0xfa,0x82,0xf5]
2252 @ CHECK: it le @ encoding: [0xd8,0xbf]
2253 @ CHECK: selle r5, r9, r2 @ encoding: [0xa9,0xfa,0x82,0xf5]
2256 @------------------------------------------------------------------------------
2257 @ SEV
2258 @------------------------------------------------------------------------------
2259 sev.w
2260 it eq
2261 seveq.w
2263 @ CHECK: sev.w @ encoding: [0xaf,0xf3,0x04,0x80]
2264 @ CHECK: it eq @ encoding: [0x08,0xbf]
2265 @ CHECK: seveq.w @ encoding: [0xaf,0xf3,0x04,0x80]
2268 @------------------------------------------------------------------------------
2269 @ SADD16/SADD8
2270 @------------------------------------------------------------------------------
2271 sadd16 r1, r2, r3
2272 sadd8 r1, r2, r3
2273 ite gt
2274 sadd16gt r1, r2, r3
2275 sadd8le r1, r2, r3
2277 @ CHECK: sadd16 r1, r2, r3 @ encoding: [0x92,0xfa,0x03,0xf1]
2278 @ CHECK: sadd8 r1, r2, r3 @ encoding: [0x82,0xfa,0x03,0xf1]
2279 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
2280 @ CHECK: sadd16gt r1, r2, r3 @ encoding: [0x92,0xfa,0x03,0xf1]
2281 @ CHECK: sadd8le r1, r2, r3 @ encoding: [0x82,0xfa,0x03,0xf1]
2284 @------------------------------------------------------------------------------
2285 @ SHASX
2286 @------------------------------------------------------------------------------
2287 shasx r4, r8, r2
2288 it gt
2289 shasxgt r4, r8, r2
2290 shaddsubx r4, r8, r2
2291 it gt
2292 shaddsubxgt r4, r8, r2
2294 @ CHECK: shasx r4, r8, r2 @ encoding: [0xa8,0xfa,0x22,0xf4]
2295 @ CHECK: it gt @ encoding: [0xc8,0xbf]
2296 @ CHECK: shasxgt r4, r8, r2 @ encoding: [0xa8,0xfa,0x22,0xf4]
2297 @ CHECK: shasx r4, r8, r2 @ encoding: [0xa8,0xfa,0x22,0xf4]
2298 @ CHECK: it gt @ encoding: [0xc8,0xbf]
2299 @ CHECK: shasxgt r4, r8, r2 @ encoding: [0xa8,0xfa,0x22,0xf4]
2302 @------------------------------------------------------------------------------
2303 @ SHASX
2304 @------------------------------------------------------------------------------
2305 shsax r4, r8, r2
2306 it gt
2307 shsaxgt r4, r8, r2
2308 shsubaddx r4, r8, r2
2309 it gt
2310 shsubaddxgt r4, r8, r2
2312 @ CHECK: shsax r4, r8, r2 @ encoding: [0xe8,0xfa,0x22,0xf4]
2313 @ CHECK: it gt @ encoding: [0xc8,0xbf]
2314 @ CHECK: shsaxgt r4, r8, r2 @ encoding: [0xe8,0xfa,0x22,0xf4]
2315 @ CHECK: shsax r4, r8, r2 @ encoding: [0xe8,0xfa,0x22,0xf4]
2316 @ CHECK: it gt @ encoding: [0xc8,0xbf]
2317 @ CHECK: shsaxgt r4, r8, r2 @ encoding: [0xe8,0xfa,0x22,0xf4]
2320 @------------------------------------------------------------------------------
2321 @ SHSUB16/SHSUB8
2322 @------------------------------------------------------------------------------
2323 shsub16 r4, r8, r2
2324 shsub8 r4, r8, r2
2325 itt gt
2326 shsub16gt r4, r8, r2
2327 shsub8gt r4, r8, r2
2329 @ CHECK: shsub16 r4, r8, r2 @ encoding: [0xd8,0xfa,0x22,0xf4]
2330 @ CHECK: shsub8 r4, r8, r2 @ encoding: [0xc8,0xfa,0x22,0xf4]
2331 @ CHECK: itt gt @ encoding: [0xc4,0xbf]
2332 @ CHECK: shsub16gt r4, r8, r2 @ encoding: [0xd8,0xfa,0x22,0xf4]
2333 @ CHECK: shsub8gt r4, r8, r2 @ encoding: [0xc8,0xfa,0x22,0xf4]
2336 @------------------------------------------------------------------------------
2337 @ SMLABB/SMLABT/SMLATB/SMLATT
2338 @------------------------------------------------------------------------------
2339 smlabb r3, r1, r9, r0
2340 smlabt r5, r6, r4, r1
2341 smlatb r4, r2, r3, r2
2342 smlatt r8, r3, r8, r4
2343 itete gt
2344 smlabbgt r3, r1, r9, r0
2345 smlabtle r5, r6, r4, r1
2346 smlatbgt r4, r2, r3, r2
2347 smlattle r8, r3, r8, r4
2349 @ CHECK: smlabb r3, r1, r9, r0 @ encoding: [0x11,0xfb,0x09,0x03]
2350 @ CHECK: smlabt r5, r6, r4, r1 @ encoding: [0x16,0xfb,0x14,0x15]
2351 @ CHECK: smlatb r4, r2, r3, r2 @ encoding: [0x12,0xfb,0x23,0x24]
2352 @ CHECK: smlatt r8, r3, r8, r4 @ encoding: [0x13,0xfb,0x38,0x48]
2353 @ CHECK: itete gt @ encoding: [0xcb,0xbf]
2354 @ CHECK: smlabbgt r3, r1, r9, r0 @ encoding: [0x11,0xfb,0x09,0x03]
2355 @ CHECK: smlabtle r5, r6, r4, r1 @ encoding: [0x16,0xfb,0x14,0x15]
2356 @ CHECK: smlatbgt r4, r2, r3, r2 @ encoding: [0x12,0xfb,0x23,0x24]
2357 @ CHECK: smlattle r8, r3, r8, r4 @ encoding: [0x13,0xfb,0x38,0x48]
2360 @------------------------------------------------------------------------------
2361 @ SMLAD/SMLADX
2362 @------------------------------------------------------------------------------
2363 smlad r2, r3, r5, r8
2364 smladx r2, r3, r5, r8
2365 itt hi
2366 smladhi r2, r3, r5, r8
2367 smladxhi r2, r3, r5, r8
2369 @ CHECK: smlad r2, r3, r5, r8 @ encoding: [0x23,0xfb,0x05,0x82]
2370 @ CHECK: smladx r2, r3, r5, r8 @ encoding: [0x23,0xfb,0x15,0x82]
2371 @ CHECK: itt hi @ encoding: [0x84,0xbf]
2372 @ CHECK: smladhi r2, r3, r5, r8 @ encoding: [0x23,0xfb,0x05,0x82]
2373 @ CHECK: smladxhi r2, r3, r5, r8 @ encoding: [0x23,0xfb,0x15,0x82]
2376 @------------------------------------------------------------------------------
2377 @ SMLAL
2378 @------------------------------------------------------------------------------
2379 smlal r2, r3, r5, r8
2380 it eq
2381 smlaleq r2, r3, r5, r8
2383 @ CHECK: smlal r2, r3, r5, r8 @ encoding: [0xc5,0xfb,0x08,0x23]
2384 @ CHECK: it eq @ encoding: [0x08,0xbf]
2385 @ CHECK: smlaleq r2, r3, r5, r8 @ encoding: [0xc5,0xfb,0x08,0x23]
2388 @------------------------------------------------------------------------------
2389 @ SMLALBB/SMLALBT/SMLALTB/SMLALTT
2390 @------------------------------------------------------------------------------
2391 smlalbb r3, r1, r9, r0
2392 smlalbt r5, r6, r4, r1
2393 smlaltb r4, r2, r3, r2
2394 smlaltt r8, r3, r8, r4
2395 iteet ge
2396 smlalbbge r3, r1, r9, r0
2397 smlalbtlt r5, r6, r4, r1
2398 smlaltblt r4, r2, r3, r2
2399 smlalttge r8, r3, r8, r4
2401 @ CHECK: smlalbb r3, r1, r9, r0 @ encoding: [0xc9,0xfb,0x80,0x31]
2402 @ CHECK: smlalbt r5, r6, r4, r1 @ encoding: [0xc4,0xfb,0x91,0x56]
2403 @ CHECK: smlaltb r4, r2, r3, r2 @ encoding: [0xc3,0xfb,0xa2,0x42]
2404 @ CHECK: smlaltt r8, r3, r8, r4 @ encoding: [0xc8,0xfb,0xb4,0x83]
2405 @ CHECK: iteet ge @ encoding: [0xad,0xbf]
2406 @ CHECK: smlalbbge r3, r1, r9, r0 @ encoding: [0xc9,0xfb,0x80,0x31]
2407 @ CHECK: smlalbtlt r5, r6, r4, r1 @ encoding: [0xc4,0xfb,0x91,0x56]
2408 @ CHECK: smlaltblt r4, r2, r3, r2 @ encoding: [0xc3,0xfb,0xa2,0x42]
2409 @ CHECK: smlalttge r8, r3, r8, r4 @ encoding: [0xc8,0xfb,0xb4,0x83]
2412 @------------------------------------------------------------------------------
2413 @ SMLALD/SMLALDX
2414 @------------------------------------------------------------------------------
2415 smlald r2, r3, r5, r8
2416 smlaldx r2, r3, r5, r8
2417 ite eq
2418 smlaldeq r2, r3, r5, r8
2419 smlaldxne r2, r3, r5, r8
2421 @ CHECK: smlald r2, r3, r5, r8 @ encoding: [0xc5,0xfb,0xc8,0x23]
2422 @ CHECK: smlaldx r2, r3, r5, r8 @ encoding: [0xc5,0xfb,0xd8,0x23]
2423 @ CHECK: ite eq @ encoding: [0x0c,0xbf]
2424 @ CHECK: smlaldeq r2, r3, r5, r8 @ encoding: [0xc5,0xfb,0xc8,0x23]
2425 @ CHECK: smlaldxne r2, r3, r5, r8 @ encoding: [0xc5,0xfb,0xd8,0x23]
2428 @------------------------------------------------------------------------------
2429 @ SMLAWB/SMLAWT
2430 @------------------------------------------------------------------------------
2431 smlawb r2, r3, r10, r8
2432 smlawt r8, r3, r5, r9
2433 ite eq
2434 smlawbeq r2, r7, r5, r8
2435 smlawtne r1, r3, r0, r8
2437 @ CHECK: smlawb r2, r3, r10, r8 @ encoding: [0x33,0xfb,0x0a,0x82]
2438 @ CHECK: smlawt r8, r3, r5, r9 @ encoding: [0x33,0xfb,0x15,0x98]
2439 @ CHECK: ite eq @ encoding: [0x0c,0xbf]
2440 @ CHECK: smlawbeq r2, r7, r5, r8 @ encoding: [0x37,0xfb,0x05,0x82]
2441 @ CHECK: smlawtne r1, r3, r0, r8 @ encoding: [0x33,0xfb,0x10,0x81]
2444 @------------------------------------------------------------------------------
2445 @ SMLSD/SMLSDX
2446 @------------------------------------------------------------------------------
2447 smlsd r2, r3, r5, r8
2448 smlsdx r2, r3, r5, r8
2449 ite le
2450 smlsdle r2, r3, r5, r8
2451 smlsdxgt r2, r3, r5, r8
2453 @ CHECK: smlsd r2, r3, r5, r8 @ encoding: [0x43,0xfb,0x05,0x82]
2454 @ CHECK: smlsdx r2, r3, r5, r8 @ encoding: [0x43,0xfb,0x15,0x82]
2455 @ CHECK: ite le @ encoding: [0xd4,0xbf]
2456 @ CHECK: smlsdle r2, r3, r5, r8 @ encoding: [0x43,0xfb,0x05,0x82]
2457 @ CHECK: smlsdxgt r2, r3, r5, r8 @ encoding: [0x43,0xfb,0x15,0x82]
2460 @------------------------------------------------------------------------------
2461 @ SMLSLD/SMLSLDX
2462 @------------------------------------------------------------------------------
2463 smlsld r2, r9, r5, r1
2464 smlsldx r4, r11, r2, r8
2465 ite ge
2466 smlsldge r8, r2, r5, r6
2467 smlsldxlt r1, r0, r3, r8
2469 @ CHECK: smlsld r2, r9, r5, r1 @ encoding: [0xd5,0xfb,0xc1,0x29]
2470 @ CHECK: smlsldx r4, r11, r2, r8 @ encoding: [0xd2,0xfb,0xd8,0x4b]
2471 @ CHECK: ite ge @ encoding: [0xac,0xbf]
2472 @ CHECK: smlsldge r8, r2, r5, r6 @ encoding: [0xd5,0xfb,0xc6,0x82]
2473 @ CHECK: smlsldxlt r1, r0, r3, r8 @ encoding: [0xd3,0xfb,0xd8,0x10]
2476 @------------------------------------------------------------------------------
2477 @ SMMLA/SMMLAR
2478 @------------------------------------------------------------------------------
2479 smmla r1, r2, r3, r4
2480 smmlar r4, r3, r2, r1
2481 ite lo
2482 smmlalo r1, r2, r3, r4
2483 smmlarcs r4, r3, r2, r1
2485 @ CHECK: smmla r1, r2, r3, r4 @ encoding: [0x52,0xfb,0x03,0x41]
2486 @ CHECK: smmlar r4, r3, r2, r1 @ encoding: [0x53,0xfb,0x12,0x14]
2487 @ CHECK: ite lo @ encoding: [0x34,0xbf]
2488 @ CHECK: smmlalo r1, r2, r3, r4 @ encoding: [0x52,0xfb,0x03,0x41]
2489 @ CHECK: smmlarhs r4, r3, r2, r1 @ encoding: [0x53,0xfb,0x12,0x14]
2492 @------------------------------------------------------------------------------
2493 @ SMMLS/SMMLSR
2494 @------------------------------------------------------------------------------
2495 smmls r1, r2, r3, r4
2496 smmlsr r4, r3, r2, r1
2497 ite lo
2498 smmlslo r1, r2, r3, r4
2499 smmlsrcs r4, r3, r2, r1
2501 @ CHECK: smmls r1, r2, r3, r4 @ encoding: [0x62,0xfb,0x03,0x41]
2502 @ CHECK: smmlsr r4, r3, r2, r1 @ encoding: [0x63,0xfb,0x12,0x14]
2503 @ CHECK: ite lo @ encoding: [0x34,0xbf]
2504 @ CHECK: smmlslo r1, r2, r3, r4 @ encoding: [0x62,0xfb,0x03,0x41]
2505 @ CHECK: smmlsrhs r4, r3, r2, r1 @ encoding: [0x63,0xfb,0x12,0x14]
2508 @------------------------------------------------------------------------------
2509 @ SMMUL/SMMULR
2510 @------------------------------------------------------------------------------
2511 smmul r2, r3, r4
2512 smmulr r3, r2, r1
2513 ite cc
2514 smmulcc r2, r3, r4
2515 smmulrhs r3, r2, r1
2517 @ CHECK: smmul r2, r3, r4 @ encoding: [0x53,0xfb,0x04,0xf2]
2518 @ CHECK: smmulr r3, r2, r1 @ encoding: [0x52,0xfb,0x11,0xf3]
2519 @ CHECK: ite lo @ encoding: [0x34,0xbf]
2520 @ CHECK: smmullo r2, r3, r4 @ encoding: [0x53,0xfb,0x04,0xf2]
2521 @ CHECK: smmulrhs r3, r2, r1 @ encoding: [0x52,0xfb,0x11,0xf3]
2524 @------------------------------------------------------------------------------
2525 @ SMUAD/SMUADX
2526 @------------------------------------------------------------------------------
2527 smuad r2, r3, r4
2528 smuadx r3, r2, r1
2529 ite lt
2530 smuadlt r2, r3, r4
2531 smuadxge r3, r2, r1
2533 @ CHECK: smuad r2, r3, r4 @ encoding: [0x23,0xfb,0x04,0xf2]
2534 @ CHECK: smuadx r3, r2, r1 @ encoding: [0x22,0xfb,0x11,0xf3]
2535 @ CHECK: ite lt @ encoding: [0xb4,0xbf]
2536 @ CHECK: smuadlt r2, r3, r4 @ encoding: [0x23,0xfb,0x04,0xf2]
2537 @ CHECK: smuadxge r3, r2, r1 @ encoding: [0x22,0xfb,0x11,0xf3]
2540 @------------------------------------------------------------------------------
2541 @ SMULBB/SMULBT/SMULTB/SMULTT
2542 @------------------------------------------------------------------------------
2543 smulbb r3, r9, r0
2544 smulbt r5, r4, r1
2545 smultb r4, r2, r2
2546 smultt r8, r3, r4
2547 itete ge
2548 smulbbge r1, r9, r0
2549 smulbtlt r5, r6, r4
2550 smultbge r2, r3, r2
2551 smulttlt r8, r3, r4
2553 @ CHECK: smulbb r3, r9, r0 @ encoding: [0x19,0xfb,0x00,0xf3]
2554 @ CHECK: smulbt r5, r4, r1 @ encoding: [0x14,0xfb,0x11,0xf5]
2555 @ CHECK: smultb r4, r2, r2 @ encoding: [0x12,0xfb,0x22,0xf4]
2556 @ CHECK: smultt r8, r3, r4 @ encoding: [0x13,0xfb,0x34,0xf8]
2557 @ CHECK: itete ge @ encoding: [0xab,0xbf]
2558 @ CHECK: smulbbge r1, r9, r0 @ encoding: [0x19,0xfb,0x00,0xf1]
2559 @ CHECK: smulbtlt r5, r6, r4 @ encoding: [0x16,0xfb,0x14,0xf5]
2560 @ CHECK: smultbge r2, r3, r2 @ encoding: [0x13,0xfb,0x22,0xf2]
2561 @ CHECK: smulttlt r8, r3, r4 @ encoding: [0x13,0xfb,0x34,0xf8]
2564 @------------------------------------------------------------------------------
2565 @ SMULL
2566 @------------------------------------------------------------------------------
2567 smull r3, r9, r0, r1
2568 it eq
2569 smulleq r8, r3, r4, r5
2571 @ CHECK: smull r3, r9, r0, r1 @ encoding: [0x80,0xfb,0x01,0x39]
2572 @ CHECK: it eq @ encoding: [0x08,0xbf]
2573 @ CHECK: smulleq r8, r3, r4, r5 @ encoding: [0x84,0xfb,0x05,0x83]
2576 @------------------------------------------------------------------------------
2577 @ SMULWB/SMULWT
2578 @------------------------------------------------------------------------------
2579 smulwb r3, r9, r0
2580 smulwt r3, r9, r2
2581 ite gt
2582 smulwbgt r3, r9, r0
2583 smulwtle r3, r9, r2
2585 @ CHECK: smulwb r3, r9, r0 @ encoding: [0x39,0xfb,0x00,0xf3]
2586 @ CHECK: smulwt r3, r9, r2 @ encoding: [0x39,0xfb,0x12,0xf3]
2587 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
2588 @ CHECK: smulwbgt r3, r9, r0 @ encoding: [0x39,0xfb,0x00,0xf3]
2589 @ CHECK: smulwtle r3, r9, r2 @ encoding: [0x39,0xfb,0x12,0xf3]
2592 @------------------------------------------------------------------------------
2593 @ SMUSD/SMUSDX
2594 @------------------------------------------------------------------------------
2595 smusd r3, r0, r1
2596 smusdx r3, r9, r2
2597 ite eq
2598 smusdeq r8, r3, r2
2599 smusdxne r7, r4, r3
2601 @ CHECK: smusd r3, r0, r1 @ encoding: [0x40,0xfb,0x01,0xf3]
2602 @ CHECK: smusdx r3, r9, r2 @ encoding: [0x49,0xfb,0x12,0xf3]
2603 @ CHECK: ite eq @ encoding: [0x0c,0xbf]
2604 @ CHECK: smusdeq r8, r3, r2 @ encoding: [0x43,0xfb,0x02,0xf8]
2605 @ CHECK: smusdxne r7, r4, r3 @ encoding: [0x44,0xfb,0x13,0xf7]
2608 @------------------------------------------------------------------------------
2609 @ SRS
2610 @------------------------------------------------------------------------------
2611 srsdb sp, #1
2612 srsia sp, #0
2614 srsdb sp!, #19
2615 srsia sp!, #2
2617 srsea sp, #10
2618 srsfd sp, #9
2620 srsea sp!, #5
2621 srsfd sp!, #5
2623 srs sp, #5
2624 srs sp!, #5
2626 @ CHECK: srsdb sp, #1 @ encoding: [0x0d,0xe8,0x01,0xc0]
2627 @ CHECK: srsia sp, #0 @ encoding: [0x8d,0xe9,0x00,0xc0]
2628 @ CHECK: srsdb sp!, #19 @ encoding: [0x2d,0xe8,0x13,0xc0]
2629 @ CHECK: srsia sp!, #2 @ encoding: [0xad,0xe9,0x02,0xc0]
2630 @ CHECK: srsia sp, #10 @ encoding: [0x8d,0xe9,0x0a,0xc0]
2631 @ CHECK: srsdb sp, #9 @ encoding: [0x0d,0xe8,0x09,0xc0]
2632 @ CHECK: srsia sp!, #5 @ encoding: [0xad,0xe9,0x05,0xc0]
2633 @ CHECK: srsdb sp!, #5 @ encoding: [0x2d,0xe8,0x05,0xc0]
2634 @ CHECK: srsia sp, #5 @ encoding: [0x8d,0xe9,0x05,0xc0]
2635 @ CHECK: srsia sp!, #5 @ encoding: [0xad,0xe9,0x05,0xc0]
2637 srsdb #1
2638 srsia #0
2640 srsdb #19!
2641 srsia #2!
2643 srsea #10
2644 srsfd #9
2646 srsea #5!
2647 srsfd #5!
2649 srs #5
2650 srs #5!
2652 @ CHECK: srsdb sp, #1 @ encoding: [0x0d,0xe8,0x01,0xc0]
2653 @ CHECK: srsia sp, #0 @ encoding: [0x8d,0xe9,0x00,0xc0]
2654 @ CHECK: srsdb sp!, #19 @ encoding: [0x2d,0xe8,0x13,0xc0]
2655 @ CHECK: srsia sp!, #2 @ encoding: [0xad,0xe9,0x02,0xc0]
2656 @ CHECK: srsia sp, #10 @ encoding: [0x8d,0xe9,0x0a,0xc0]
2657 @ CHECK: srsdb sp, #9 @ encoding: [0x0d,0xe8,0x09,0xc0]
2658 @ CHECK: srsia sp!, #5 @ encoding: [0xad,0xe9,0x05,0xc0]
2659 @ CHECK: srsdb sp!, #5 @ encoding: [0x2d,0xe8,0x05,0xc0]
2660 @ CHECK: srsia sp, #5 @ encoding: [0x8d,0xe9,0x05,0xc0]
2661 @ CHECK: srsia sp!, #5 @ encoding: [0xad,0xe9,0x05,0xc0]
2664 @------------------------------------------------------------------------------
2665 @ SSAT
2666 @------------------------------------------------------------------------------
2667 ssat r8, #1, r10
2668 ssat r8, #1, r10, lsl #0
2669 ssat r8, #1, r10, lsl #31
2670 ssat r8, #1, r10, asr #1
2672 @ CHECK: ssat r8, #1, r10 @ encoding: [0x0a,0xf3,0x00,0x08]
2673 @ CHECK: ssat r8, #1, r10 @ encoding: [0x0a,0xf3,0x00,0x08]
2674 @ CHECK: ssat r8, #1, r10, lsl #31 @ encoding: [0x0a,0xf3,0xc0,0x78]
2675 @ CHECK: ssat r8, #1, r10, asr #1 @ encoding: [0x2a,0xf3,0x40,0x08]
2678 @------------------------------------------------------------------------------
2679 @ SSAT16
2680 @------------------------------------------------------------------------------
2681 ssat16 r2, #1, r7
2682 ssat16 r3, #16, r5
2684 @ CHECK: ssat16 r2, #1, r7 @ encoding: [0x27,0xf3,0x00,0x02]
2685 @ CHECK: ssat16 r3, #16, r5 @ encoding: [0x25,0xf3,0x0f,0x03]
2688 @------------------------------------------------------------------------------
2689 @ SSAX
2690 @------------------------------------------------------------------------------
2691 ssubaddx r2, r3, r4
2692 it lt
2693 ssubaddxlt r2, r3, r4
2694 ssax r2, r3, r4
2695 it lt
2696 ssaxlt r2, r3, r4
2698 @ CHECK: ssax r2, r3, r4 @ encoding: [0xe3,0xfa,0x04,0xf2]
2699 @ CHECK: it lt @ encoding: [0xb8,0xbf]
2700 @ CHECK: ssaxlt r2, r3, r4 @ encoding: [0xe3,0xfa,0x04,0xf2]
2701 @ CHECK: ssax r2, r3, r4 @ encoding: [0xe3,0xfa,0x04,0xf2]
2702 @ CHECK: it lt @ encoding: [0xb8,0xbf]
2703 @ CHECK: ssaxlt r2, r3, r4 @ encoding: [0xe3,0xfa,0x04,0xf2]
2706 @------------------------------------------------------------------------------
2707 @ SSUB16/SSUB8
2708 @------------------------------------------------------------------------------
2709 ssub16 r1, r0, r6
2710 ssub8 r9, r2, r4
2711 ite ne
2712 ssub16ne r5, r3, r2
2713 ssub8eq r5, r1, r2
2715 @ CHECK: ssub16 r1, r0, r6 @ encoding: [0xd0,0xfa,0x06,0xf1]
2716 @ CHECK: ssub8 r9, r2, r4 @ encoding: [0xc2,0xfa,0x04,0xf9]
2717 @ CHECK: ite ne @ encoding: [0x14,0xbf]
2718 @ CHECK: ssub16ne r5, r3, r2 @ encoding: [0xd3,0xfa,0x02,0xf5]
2719 @ CHECK: ssub8eq r5, r1, r2 @ encoding: [0xc1,0xfa,0x02,0xf5]
2722 @------------------------------------------------------------------------------
2723 @ STC{L}/STC2{L}
2724 @------------------------------------------------------------------------------
2725 stc2 p0, c8, [r1, #4]
2726 stc2 p1, c7, [r2]
2727 stc2 p2, c6, [r3, #-224]
2728 stc2 p3, c5, [r4, #-120]!
2729 stc2 p4, c4, [r5], #16
2730 stc2 p5, c3, [r6], #-72
2731 stc2l p6, c2, [r7, #4]
2732 stc2l p7, c1, [r8]
2733 stc2l p8, c0, [r9, #-224]
2734 stc2l p9, c1, [r10, #-120]!
2735 stc2l p0, c2, [r11], #16
2736 stc2l p1, c3, [r12], #-72
2738 stc p12, c4, [r0, #4]
2739 stc p13, c5, [r1]
2740 stc p14, c6, [r2, #-224]
2741 stc p15, c7, [r3, #-120]!
2742 stc p5, c8, [r4], #16
2743 stc p4, c9, [r5], #-72
2744 stcl p3, c10, [r6, #4]
2745 stcl p2, c11, [r7]
2746 stcl p1, c12, [r8, #-224]
2747 stcl p0, c13, [r9, #-120]!
2748 stcl p6, c14, [r10], #16
2749 stcl p7, c15, [r11], #-72
2751 stc2 p2, c8, [r1], { 25 }
2753 @ CHECK: stc2 p0, c8, [r1, #4] @ encoding: [0x81,0xfd,0x01,0x80]
2754 @ CHECK: stc2 p1, c7, [r2] @ encoding: [0x82,0xfd,0x00,0x71]
2755 @ CHECK: stc2 p2, c6, [r3, #-224] @ encoding: [0x03,0xfd,0x38,0x62]
2756 @ CHECK: stc2 p3, c5, [r4, #-120]! @ encoding: [0x24,0xfd,0x1e,0x53]
2757 @ CHECK: stc2 p4, c4, [r5], #16 @ encoding: [0xa5,0xfc,0x04,0x44]
2758 @ CHECK: stc2 p5, c3, [r6], #-72 @ encoding: [0x26,0xfc,0x12,0x35]
2759 @ CHECK: stc2l p6, c2, [r7, #4] @ encoding: [0xc7,0xfd,0x01,0x26]
2760 @ CHECK: stc2l p7, c1, [r8] @ encoding: [0xc8,0xfd,0x00,0x17]
2761 @ CHECK: stc2l p8, c0, [r9, #-224] @ encoding: [0x49,0xfd,0x38,0x08]
2762 @ CHECK: stc2l p9, c1, [r10, #-120]! @ encoding: [0x6a,0xfd,0x1e,0x19]
2763 @ CHECK: stc2l p0, c2, [r11], #16 @ encoding: [0xeb,0xfc,0x04,0x20]
2764 @ CHECK: stc2l p1, c3, [r12], #-72 @ encoding: [0x6c,0xfc,0x12,0x31]
2766 @ CHECK: stc p12, c4, [r0, #4] @ encoding: [0x80,0xed,0x01,0x4c]
2767 @ CHECK: stc p13, c5, [r1] @ encoding: [0x81,0xed,0x00,0x5d]
2768 @ CHECK: stc p14, c6, [r2, #-224] @ encoding: [0x02,0xed,0x38,0x6e]
2769 @ CHECK: stc p15, c7, [r3, #-120]! @ encoding: [0x23,0xed,0x1e,0x7f]
2770 @ CHECK: stc p5, c8, [r4], #16 @ encoding: [0xa4,0xec,0x04,0x85]
2771 @ CHECK: stc p4, c9, [r5], #-72 @ encoding: [0x25,0xec,0x12,0x94]
2772 @ CHECK: stcl p3, c10, [r6, #4] @ encoding: [0xc6,0xed,0x01,0xa3]
2773 @ CHECK: stcl p2, c11, [r7] @ encoding: [0xc7,0xed,0x00,0xb2]
2774 @ CHECK: stcl p1, c12, [r8, #-224] @ encoding: [0x48,0xed,0x38,0xc1]
2775 @ CHECK: stcl p0, c13, [r9, #-120]! @ encoding: [0x69,0xed,0x1e,0xd0]
2776 @ CHECK: stcl p6, c14, [r10], #16 @ encoding: [0xea,0xec,0x04,0xe6]
2777 @ CHECK: stcl p7, c15, [r11], #-72 @ encoding: [0x6b,0xec,0x12,0xf7]
2779 @ CHECK: stc2 p2, c8, [r1], {25} @ encoding: [0x81,0xfc,0x19,0x82]
2782 @------------------------------------------------------------------------------
2783 @ STMIA
2784 @------------------------------------------------------------------------------
2785 stmia.w r4, {r4, r5, r8, r9}
2786 stmia.w r4, {r5, r6}
2787 stmia.w r5!, {r3, r8}
2788 stm.w r4, {r4, r5, r8, r9}
2789 stm.w r4, {r5, r6}
2790 stm.w r5!, {r3, r8}
2791 stm.w r5!, {r1, r2}
2792 stm.w r2, {r1, r2}
2794 stmia r4, {r4, r5, r8, r9}
2795 stmia r4, {r5, r6}
2796 stmia r5!, {r3, r8}
2797 stm r4, {r4, r5, r8, r9}
2798 stm r4, {r5, r6}
2799 stm r5!, {r3, r8}
2800 stmea r5!, {r3, r8}
2802 @ CHECK: stm.w r4, {r4, r5, r8, r9} @ encoding: [0x84,0xe8,0x30,0x03]
2803 @ CHECK: stm.w r4, {r5, r6} @ encoding: [0x84,0xe8,0x60,0x00]
2804 @ CHECK: stm.w r5!, {r3, r8} @ encoding: [0xa5,0xe8,0x08,0x01]
2805 @ CHECK: stm.w r4, {r4, r5, r8, r9} @ encoding: [0x84,0xe8,0x30,0x03]
2806 @ CHECK: stm.w r4, {r5, r6} @ encoding: [0x84,0xe8,0x60,0x00]
2807 @ CHECK: stm.w r5!, {r3, r8} @ encoding: [0xa5,0xe8,0x08,0x01]
2808 @ CHECK: stm.w r5!, {r1, r2} @ encoding: [0xa5,0xe8,0x06,0x00]
2809 @ CHECK: stm.w r2, {r1, r2} @ encoding: [0x82,0xe8,0x06,0x00]
2811 @ CHECK: stm.w r4, {r4, r5, r8, r9} @ encoding: [0x84,0xe8,0x30,0x03]
2812 @ CHECK: stm.w r4, {r5, r6} @ encoding: [0x84,0xe8,0x60,0x00]
2813 @ CHECK: stm.w r5!, {r3, r8} @ encoding: [0xa5,0xe8,0x08,0x01]
2814 @ CHECK: stm.w r4, {r4, r5, r8, r9} @ encoding: [0x84,0xe8,0x30,0x03]
2815 @ CHECK: stm.w r4, {r5, r6} @ encoding: [0x84,0xe8,0x60,0x00]
2816 @ CHECK: stm.w r5!, {r3, r8} @ encoding: [0xa5,0xe8,0x08,0x01]
2817 @ CHECK: stm.w r5!, {r3, r8} @ encoding: [0xa5,0xe8,0x08,0x01]
2820 @------------------------------------------------------------------------------
2821 @ STMDB
2822 @------------------------------------------------------------------------------
2823 stmdb r4, {r4, r5, r8, r9}
2824 stmdb r4, {r5, r6}
2825 stmdb r5!, {r3, r8}
2826 stmea r5!, {r3, r8}
2827 stmdb.w r5, {r0, r1}
2829 @ CHECK: stmdb r4, {r4, r5, r8, r9} @ encoding: [0x04,0xe9,0x30,0x03]
2830 @ CHECK: stmdb r4, {r5, r6} @ encoding: [0x04,0xe9,0x60,0x00]
2831 @ CHECK: stmdb r5!, {r3, r8} @ encoding: [0x25,0xe9,0x08,0x01]
2832 @ CHECK: stm.w r5!, {r3, r8} @ encoding: [0xa5,0xe8,0x08,0x01]
2833 @ CHECK: stmdb r5, {r0, r1} @ encoding: [0x05,0xe9,0x03,0x00]
2836 @------------------------------------------------------------------------------
2837 @ STR(immediate)
2838 @------------------------------------------------------------------------------
2839 str r5, [r5, #-4]
2840 str r5, [r6, #32]
2841 str r5, [r6, #33]
2842 str r5, [r6, #257]
2843 str.w pc, [r7, #257]
2844 str r2, [r4, #255]!
2845 str r8, [sp, #4]!
2846 str lr, [sp, #-4]!
2847 str r2, [r4], #255
2848 str r8, [sp], #4
2849 str lr, [sp], #-4
2851 @ CHECK: str r5, [r5, #-4] @ encoding: [0x45,0xf8,0x04,0x5c]
2852 @ CHECK: str r5, [r6, #32] @ encoding: [0x35,0x62]
2853 @ CHECK: str.w r5, [r6, #33] @ encoding: [0xc6,0xf8,0x21,0x50]
2854 @ CHECK: str.w r5, [r6, #257] @ encoding: [0xc6,0xf8,0x01,0x51]
2855 @ CHECK: str.w pc, [r7, #257] @ encoding: [0xc7,0xf8,0x01,0xf1]
2856 @ CHECK: str r2, [r4, #255]! @ encoding: [0x44,0xf8,0xff,0x2f]
2857 @ CHECK: str r8, [sp, #4]! @ encoding: [0x4d,0xf8,0x04,0x8f]
2858 @ CHECK: str lr, [sp, #-4]! @ encoding: [0x4d,0xf8,0x04,0xed]
2859 @ CHECK: str r2, [r4], #255 @ encoding: [0x44,0xf8,0xff,0x2b]
2860 @ CHECK: str r8, [sp], #4 @ encoding: [0x4d,0xf8,0x04,0x8b]
2861 @ CHECK: str lr, [sp], #-4 @ encoding: [0x4d,0xf8,0x04,0xe9]
2864 @------------------------------------------------------------------------------
2865 @ STR(register)
2866 @------------------------------------------------------------------------------
2867 str r1, [r8, r1]
2868 str.w r4, [r5, r2]
2869 str r6, [r0, r2, lsl #3]
2870 str r8, [r8, r2, lsl #2]
2871 str r7, [sp, r2, lsl #1]
2872 str r7, [sp, r2, lsl #0]
2874 @ CHECK: str.w r1, [r8, r1] @ encoding: [0x48,0xf8,0x01,0x10]
2875 @ CHECK: str.w r4, [r5, r2] @ encoding: [0x45,0xf8,0x02,0x40]
2876 @ CHECK: str.w r6, [r0, r2, lsl #3] @ encoding: [0x40,0xf8,0x32,0x60]
2877 @ CHECK: str.w r8, [r8, r2, lsl #2] @ encoding: [0x48,0xf8,0x22,0x80]
2878 @ CHECK: str.w r7, [sp, r2, lsl #1] @ encoding: [0x4d,0xf8,0x12,0x70]
2879 @ CHECK: str.w r7, [sp, r2] @ encoding: [0x4d,0xf8,0x02,0x70]
2882 @------------------------------------------------------------------------------
2883 @ STRB(immediate)
2884 @------------------------------------------------------------------------------
2885 strb r5, [r5, #-4]
2886 strb r5, [r6, #32]
2887 strb r5, [r6, #33]
2888 strb r5, [r6, #257]
2889 strb.w lr, [r7, #257]
2890 strb r5, [r8, #255]!
2891 strb r2, [r5, #4]!
2892 strb r1, [r4, #-4]!
2893 strb lr, [r3], #255
2894 strb r9, [r2], #4
2895 strb r3, [sp], #-4
2896 strb r4, [r8, #-0]!
2897 strb r1, [r0], #-0
2899 @ CHECK: strb r5, [r5, #-4] @ encoding: [0x05,0xf8,0x04,0x5c]
2900 @ CHECK: strb.w r5, [r6, #32] @ encoding: [0x86,0xf8,0x20,0x50]
2901 @ CHECK: strb.w r5, [r6, #33] @ encoding: [0x86,0xf8,0x21,0x50]
2902 @ CHECK: strb.w r5, [r6, #257] @ encoding: [0x86,0xf8,0x01,0x51]
2903 @ CHECK: strb.w lr, [r7, #257] @ encoding: [0x87,0xf8,0x01,0xe1]
2904 @ CHECK: strb r5, [r8, #255]! @ encoding: [0x08,0xf8,0xff,0x5f]
2905 @ CHECK: strb r2, [r5, #4]! @ encoding: [0x05,0xf8,0x04,0x2f]
2906 @ CHECK: strb r1, [r4, #-4]! @ encoding: [0x04,0xf8,0x04,0x1d]
2907 @ CHECK: strb lr, [r3], #255 @ encoding: [0x03,0xf8,0xff,0xeb]
2908 @ CHECK: strb r9, [r2], #4 @ encoding: [0x02,0xf8,0x04,0x9b]
2909 @ CHECK: strb r3, [sp], #-4 @ encoding: [0x0d,0xf8,0x04,0x39]
2910 @ CHECK: strb r4, [r8, #-0]! @ encoding: [0x08,0xf8,0x00,0x4d]
2911 @ CHECK: strb r1, [r0], #-0 @ encoding: [0x00,0xf8,0x00,0x19]
2914 @------------------------------------------------------------------------------
2915 @ STRB(register)
2916 @------------------------------------------------------------------------------
2917 strb r1, [r8, r1]
2918 strb.w r4, [r5, r2]
2919 strb r6, [r0, r2, lsl #3]
2920 strb r8, [r8, r2, lsl #2]
2921 strb r7, [sp, r2, lsl #1]
2922 strb r7, [sp, r2, lsl #0]
2924 @ CHECK: strb.w r1, [r8, r1] @ encoding: [0x08,0xf8,0x01,0x10]
2925 @ CHECK: strb.w r4, [r5, r2] @ encoding: [0x05,0xf8,0x02,0x40]
2926 @ CHECK: strb.w r6, [r0, r2, lsl #3] @ encoding: [0x00,0xf8,0x32,0x60]
2927 @ CHECK: strb.w r8, [r8, r2, lsl #2] @ encoding: [0x08,0xf8,0x22,0x80]
2928 @ CHECK: strb.w r7, [sp, r2, lsl #1] @ encoding: [0x0d,0xf8,0x12,0x70]
2929 @ CHECK: strb.w r7, [sp, r2] @ encoding: [0x0d,0xf8,0x02,0x70]
2932 @------------------------------------------------------------------------------
2933 @ STRBT
2934 @------------------------------------------------------------------------------
2935 strbt r1, [r2]
2936 strbt r1, [r8, #0]
2937 strbt r1, [r8, #3]
2938 strbt r1, [r8, #255]
2940 @ CHECK: strbt r1, [r2] @ encoding: [0x02,0xf8,0x00,0x1e]
2941 @ CHECK: strbt r1, [r8] @ encoding: [0x08,0xf8,0x00,0x1e]
2942 @ CHECK: strbt r1, [r8, #3] @ encoding: [0x08,0xf8,0x03,0x1e]
2943 @ CHECK: strbt r1, [r8, #255] @ encoding: [0x08,0xf8,0xff,0x1e]
2946 @------------------------------------------------------------------------------
2947 @ STRD
2948 @------------------------------------------------------------------------------
2949 strd r3, r5, [r6, #24]
2950 strd r3, r5, [r6, #24]!
2951 strd r3, r5, [r6], #4
2952 strd r3, r5, [r6], #-8
2953 strd r3, r5, [r6]
2954 strd r8, r1, [r3, #0]
2955 strd r0, r1, [r2, #-0]
2956 strd r0, r1, [r2, #-0]!
2957 strd r0, r1, [r2], #-0
2958 strd r0, r1, [r2, #256]
2959 strd r0, r1, [r2, #256]!
2960 strd r0, r1, [r2], #256
2962 @ CHECK: strd r3, r5, [r6, #24] @ encoding: [0xc6,0xe9,0x06,0x35]
2963 @ CHECK: strd r3, r5, [r6, #24]! @ encoding: [0xe6,0xe9,0x06,0x35]
2964 @ CHECK: strd r3, r5, [r6], #4 @ encoding: [0xe6,0xe8,0x01,0x35]
2965 @ CHECK: strd r3, r5, [r6], #-8 @ encoding: [0x66,0xe8,0x02,0x35]
2966 @ CHECK: strd r3, r5, [r6] @ encoding: [0xc6,0xe9,0x00,0x35]
2967 @ CHECK: strd r8, r1, [r3] @ encoding: [0xc3,0xe9,0x00,0x81]
2968 @ CHECK: strd r0, r1, [r2, #-0] @ encoding: [0x42,0xe9,0x00,0x01]
2969 @ CHECK: strd r0, r1, [r2, #-0]! @ encoding: [0x62,0xe9,0x00,0x01]
2970 @ CHECK: strd r0, r1, [r2], #-0 @ encoding: [0x62,0xe8,0x00,0x01]
2971 @ CHECK: strd r0, r1, [r2, #256] @ encoding: [0xc2,0xe9,0x40,0x01]
2972 @ CHECK: strd r0, r1, [r2, #256]! @ encoding: [0xe2,0xe9,0x40,0x01]
2973 @ CHECK: strd r0, r1, [r2], #256 @ encoding: [0xe2,0xe8,0x40,0x01]
2976 @------------------------------------------------------------------------------
2977 @ STREX/STREXB/STREXH/STREXD
2978 @------------------------------------------------------------------------------
2979 strex r1, r8, [r4]
2980 strex r8, r2, [r4, #0]
2981 strex r2, r12, [sp, #128]
2982 strexb r5, r1, [r7]
2983 strexh r9, r7, [r12]
2984 strexd r9, r3, r6, [r4]
2986 @ CHECK: strex r1, r8, [r4] @ encoding: [0x44,0xe8,0x00,0x81]
2987 @ CHECK: strex r8, r2, [r4] @ encoding: [0x44,0xe8,0x00,0x28]
2988 @ CHECK: strex r2, r12, [sp, #128] @ encoding: [0x4d,0xe8,0x20,0xc2]
2989 @ CHECK: strexb r5, r1, [r7] @ encoding: [0xc7,0xe8,0x45,0x1f]
2990 @ CHECK: strexh r9, r7, [r12] @ encoding: [0xcc,0xe8,0x59,0x7f]
2991 @ CHECK: strexd r9, r3, r6, [r4] @ encoding: [0xc4,0xe8,0x79,0x36]
2994 @------------------------------------------------------------------------------
2995 @ STRH(immediate)
2996 @------------------------------------------------------------------------------
2997 strh r5, [r5, #-4]
2998 strh r5, [r6, #32]
2999 strh r5, [r6, #33]
3000 strh r5, [r6, #257]
3001 strh.w lr, [r7, #257]
3002 strh r5, [r8, #255]!
3003 strh r2, [r5, #4]!
3004 strh r1, [r4, #-4]!
3005 strh lr, [r3], #255
3006 strh r9, [r2], #4
3007 strh r3, [sp], #-4
3009 @ CHECK: strh r5, [r5, #-4] @ encoding: [0x25,0xf8,0x04,0x5c]
3010 @ CHECK: strh r5, [r6, #32] @ encoding: [0x35,0x84]
3011 @ CHECK: strh.w r5, [r6, #33] @ encoding: [0xa6,0xf8,0x21,0x50]
3012 @ CHECK: strh.w r5, [r6, #257] @ encoding: [0xa6,0xf8,0x01,0x51]
3013 @ CHECK: strh.w lr, [r7, #257] @ encoding: [0xa7,0xf8,0x01,0xe1]
3014 @ CHECK: strh r5, [r8, #255]! @ encoding: [0x28,0xf8,0xff,0x5f]
3015 @ CHECK: strh r2, [r5, #4]! @ encoding: [0x25,0xf8,0x04,0x2f]
3016 @ CHECK: strh r1, [r4, #-4]! @ encoding: [0x24,0xf8,0x04,0x1d]
3017 @ CHECK: strh lr, [r3], #255 @ encoding: [0x23,0xf8,0xff,0xeb]
3018 @ CHECK: strh r9, [r2], #4 @ encoding: [0x22,0xf8,0x04,0x9b]
3019 @ CHECK: strh r3, [sp], #-4 @ encoding: [0x2d,0xf8,0x04,0x39]
3022 @------------------------------------------------------------------------------
3023 @ STRH(register)
3024 @------------------------------------------------------------------------------
3025 strh r1, [r8, r1]
3026 strh.w r4, [r5, r2]
3027 strh r6, [r0, r2, lsl #3]
3028 strh r8, [r8, r2, lsl #2]
3029 strh r7, [sp, r2, lsl #1]
3030 strh r7, [sp, r2, lsl #0]
3032 @ CHECK: strh.w r1, [r8, r1] @ encoding: [0x28,0xf8,0x01,0x10]
3033 @ CHECK: strh.w r4, [r5, r2] @ encoding: [0x25,0xf8,0x02,0x40]
3034 @ CHECK: strh.w r6, [r0, r2, lsl #3] @ encoding: [0x20,0xf8,0x32,0x60]
3035 @ CHECK: strh.w r8, [r8, r2, lsl #2] @ encoding: [0x28,0xf8,0x22,0x80]
3036 @ CHECK: strh.w r7, [sp, r2, lsl #1] @ encoding: [0x2d,0xf8,0x12,0x70]
3037 @ CHECK: strh.w r7, [sp, r2] @ encoding: [0x2d,0xf8,0x02,0x70]
3040 @------------------------------------------------------------------------------
3041 @ STRHT
3042 @------------------------------------------------------------------------------
3043 strht r1, [r2]
3044 strht r1, [r8, #0]
3045 strht r1, [r8, #3]
3046 strht r1, [r8, #255]
3048 @ CHECK: strht r1, [r2] @ encoding: [0x22,0xf8,0x00,0x1e]
3049 @ CHECK: strht r1, [r8] @ encoding: [0x28,0xf8,0x00,0x1e]
3050 @ CHECK: strht r1, [r8, #3] @ encoding: [0x28,0xf8,0x03,0x1e]
3051 @ CHECK: strht r1, [r8, #255] @ encoding: [0x28,0xf8,0xff,0x1e]
3054 @------------------------------------------------------------------------------
3055 @ STRT
3056 @------------------------------------------------------------------------------
3057 strt r1, [r2]
3058 strt r1, [r8, #0]
3059 strt r1, [r8, #3]
3060 strt r1, [r8, #255]
3062 @ CHECK: strt r1, [r2] @ encoding: [0x42,0xf8,0x00,0x1e]
3063 @ CHECK: strt r1, [r8] @ encoding: [0x48,0xf8,0x00,0x1e]
3064 @ CHECK: strt r1, [r8, #3] @ encoding: [0x48,0xf8,0x03,0x1e]
3065 @ CHECK: strt r1, [r8, #255] @ encoding: [0x48,0xf8,0xff,0x1e]
3068 @------------------------------------------------------------------------------
3069 @ SUB (immediate)
3070 @------------------------------------------------------------------------------
3071 itet eq
3072 subeq r1, r2, #4
3073 subwne r5, r3, #1023
3074 subeq r4, r5, #293
3075 sub r2, sp, #1024
3076 sub r2, r8, #0xff00
3077 sub r2, r3, #257
3078 subw r2, r3, #257
3079 sub r12, r6, #0x100
3080 subw r12, r6, #0x100
3081 subs r1, r2, #0x1f0
3082 sub r2, #1
3083 sub r0, r0, #32
3084 subs r2, r2, #56
3085 subs r2, #56
3087 @ CHECK: itet eq @ encoding: [0x0a,0xbf]
3088 @ CHECK: subeq r1, r2, #4 @ encoding: [0x11,0x1f]
3089 @ CHECK: subwne r5, r3, #1023 @ encoding: [0xa3,0xf2,0xff,0x35]
3090 @ CHECK: subweq r4, r5, #293 @ encoding: [0xa5,0xf2,0x25,0x14]
3091 @ CHECK: sub.w r2, sp, #1024 @ encoding: [0xad,0xf5,0x80,0x62]
3092 @ CHECK: sub.w r2, r8, #65280 @ encoding: [0xa8,0xf5,0x7f,0x42]
3093 @ CHECK: subw r2, r3, #257 @ encoding: [0xa3,0xf2,0x01,0x12]
3094 @ CHECK: subw r2, r3, #257 @ encoding: [0xa3,0xf2,0x01,0x12]
3095 @ CHECK: sub.w r12, r6, #256 @ encoding: [0xa6,0xf5,0x80,0x7c]
3096 @ CHECK: subw r12, r6, #256 @ encoding: [0xa6,0xf2,0x00,0x1c]
3097 @ CHECK: subs.w r1, r2, #496 @ encoding: [0xb2,0xf5,0xf8,0x71]
3098 @ CHECK: sub.w r2, r2, #1 @ encoding: [0xa2,0xf1,0x01,0x02]
3099 @ CHECK: sub.w r0, r0, #32 @ encoding: [0xa0,0xf1,0x20,0x00]
3100 @ CHECK: subs r2, #56 @ encoding: [0x38,0x3a]
3101 @ CHECK: subs r2, #56 @ encoding: [0x38,0x3a]
3104 @------------------------------------------------------------------------------
3105 @ SUB (register)
3106 @------------------------------------------------------------------------------
3107 sub r4, r5, r6
3108 sub r4, r5, r6, lsl #5
3109 sub r4, r5, r6, lsr #5
3110 sub.w r4, r5, r6, lsr #5
3111 sub r4, r5, r6, asr #5
3112 sub r4, r5, r6, ror #5
3113 sub.w r5, r2, r12, rrx
3114 sub r2, sp, ip
3115 sub sp, sp, ip
3116 sub sp, ip
3117 sub.w r2, sp, ip
3118 sub.w sp, sp, ip
3119 sub.w sp, ip
3121 @ CHECK: sub.w r4, r5, r6 @ encoding: [0xa5,0xeb,0x06,0x04]
3122 @ CHECK: sub.w r4, r5, r6, lsl #5 @ encoding: [0xa5,0xeb,0x46,0x14]
3123 @ CHECK: sub.w r4, r5, r6, lsr #5 @ encoding: [0xa5,0xeb,0x56,0x14]
3124 @ CHECK: sub.w r4, r5, r6, lsr #5 @ encoding: [0xa5,0xeb,0x56,0x14]
3125 @ CHECK: sub.w r4, r5, r6, asr #5 @ encoding: [0xa5,0xeb,0x66,0x14]
3126 @ CHECK: sub.w r4, r5, r6, ror #5 @ encoding: [0xa5,0xeb,0x76,0x14]
3127 @ CHECK: sub.w r5, r2, r12, rrx @ encoding: [0xa2,0xeb,0x3c,0x05]
3128 @ CHECK: sub.w r2, sp, r12 @ encoding: [0xad,0xeb,0x0c,0x02]
3129 @ CHECK: sub.w sp, sp, r12 @ encoding: [0xad,0xeb,0x0c,0x0d]
3130 @ CHECK: sub.w sp, sp, r12 @ encoding: [0xad,0xeb,0x0c,0x0d]
3131 @ CHECK: sub.w r2, sp, r12 @ encoding: [0xad,0xeb,0x0c,0x02]
3132 @ CHECK: sub.w sp, sp, r12 @ encoding: [0xad,0xeb,0x0c,0x0d]
3133 @ CHECK: sub.w sp, sp, r12 @ encoding: [0xad,0xeb,0x0c,0x0d]
3136 @------------------------------------------------------------------------------
3137 @ SVC
3138 @------------------------------------------------------------------------------
3139 svc #0
3140 it eq
3141 svceq #255
3142 it ne
3143 swine #33
3144 itt eq
3145 svceq #0
3146 svceq #1
3148 @ CHECK: svc #0 @ encoding: [0x00,0xdf]
3149 @ CHECK: it eq @ encoding: [0x08,0xbf]
3150 @ CHECK: svceq #255 @ encoding: [0xff,0xdf]
3151 @ CHECK: it ne @ encoding: [0x18,0xbf]
3152 @ CHECK: svcne #33 @ encoding: [0x21,0xdf]
3153 @ CHECK: itt eq @ encoding: [0x04,0xbf]
3154 @ CHECK: svceq #0 @ encoding: [0x00,0xdf]
3155 @ CHECK: svceq #1 @ encoding: [0x01,0xdf]
3158 @------------------------------------------------------------------------------
3159 @ SXTAB
3160 @------------------------------------------------------------------------------
3161 sxtab r2, r3, r4
3162 sxtab r4, r5, r6, ror #0
3163 it lt
3164 sxtablt r6, r2, r9, ror #8
3165 sxtab r5, r1, r4, ror #16
3166 sxtab r7, r8, r3, ror #24
3168 @ CHECK: sxtab r2, r3, r4 @ encoding: [0x43,0xfa,0x84,0xf2]
3169 @ CHECK: sxtab r4, r5, r6 @ encoding: [0x45,0xfa,0x86,0xf4]
3170 @ CHECK: it lt @ encoding: [0xb8,0xbf]
3171 @ CHECK: sxtablt r6, r2, r9, ror #8 @ encoding: [0x42,0xfa,0x99,0xf6]
3172 @ CHECK: sxtab r5, r1, r4, ror #16 @ encoding: [0x41,0xfa,0xa4,0xf5]
3173 @ CHECK: sxtab r7, r8, r3, ror #24 @ encoding: [0x48,0xfa,0xb3,0xf7]
3176 @------------------------------------------------------------------------------
3177 @ SXTAB16
3178 @------------------------------------------------------------------------------
3179 sxtab16 r6, r2, r7, ror #0
3180 sxtab16 r3, r5, r8, ror #8
3181 sxtab16 r3, r2, r1, ror #16
3182 ite ne
3183 sxtab16ne r0, r1, r4
3184 sxtab16eq r1, r2, r3, ror #24
3186 @ CHECK: sxtab16 r6, r2, r7 @ encoding: [0x22,0xfa,0x87,0xf6]
3187 @ CHECK: sxtab16 r3, r5, r8, ror #8 @ encoding: [0x25,0xfa,0x98,0xf3]
3188 @ CHECK: sxtab16 r3, r2, r1, ror #16 @ encoding: [0x22,0xfa,0xa1,0xf3]
3189 @ CHECK: ite ne @ encoding: [0x14,0xbf]
3190 @ CHECK: sxtab16ne r0, r1, r4 @ encoding: [0x21,0xfa,0x84,0xf0]
3191 @ CHECK: sxtab16eq r1, r2, r3, ror #24 @ encoding: [0x22,0xfa,0xb3,0xf1]
3194 @------------------------------------------------------------------------------
3195 @ SXTAH
3196 @------------------------------------------------------------------------------
3197 sxtah r1, r3, r9
3198 sxtah r3, r8, r3, ror #8
3199 sxtah r9, r3, r3, ror #24
3200 ite hi
3201 sxtahhi r6, r1, r6, ror #0
3202 sxtahls r2, r2, r4, ror #16
3204 @ CHECK: sxtah r1, r3, r9 @ encoding: [0x03,0xfa,0x89,0xf1]
3205 @ CHECK: sxtah r3, r8, r3, ror #8 @ encoding: [0x08,0xfa,0x93,0xf3]
3206 @ CHECK: sxtah r9, r3, r3, ror #24 @ encoding: [0x03,0xfa,0xb3,0xf9]
3207 @ CHECK: ite hi @ encoding: [0x8c,0xbf]
3208 @ CHECK: sxtahhi r6, r1, r6 @ encoding: [0x01,0xfa,0x86,0xf6]
3209 @ CHECK: sxtahls r2, r2, r4, ror #16 @ encoding: [0x02,0xfa,0xa4,0xf2]
3212 @------------------------------------------------------------------------------
3213 @ SXTB
3214 @------------------------------------------------------------------------------
3215 sxtb r5, r6, ror #0
3216 sxtb r6, r9, ror #8
3217 sxtb r8, r3, ror #24
3218 ite ge
3219 sxtbge r2, r4
3220 sxtblt r5, r1, ror #16
3221 sxtb.w r7, r8
3223 @ CHECK: sxtb r5, r6 @ encoding: [0x75,0xb2]
3224 @ CHECK: sxtb.w r6, r9, ror #8 @ encoding: [0x4f,0xfa,0x99,0xf6]
3225 @ CHECK: sxtb.w r8, r3, ror #24 @ encoding: [0x4f,0xfa,0xb3,0xf8]
3226 @ CHECK: ite ge @ encoding: [0xac,0xbf]
3227 @ CHECK: sxtbge r2, r4 @ encoding: [0x62,0xb2]
3228 @ CHECK: sxtblt.w r5, r1, ror #16 @ encoding: [0x4f,0xfa,0xa1,0xf5]
3229 @ CHECK: sxtb.w r7, r8 @ encoding: [0x4f,0xfa,0x88,0xf7]
3232 @------------------------------------------------------------------------------
3233 @ SXTB16
3234 @------------------------------------------------------------------------------
3235 sxtb16 r1, r4
3236 sxtb16 r6, r7, ror #0
3237 sxtb16 r3, r1, ror #16
3238 ite cs
3239 sxtb16cs r3, r5, ror #8
3240 sxtb16lo r2, r3, ror #24
3242 @ CHECK: sxtb16 r1, r4 @ encoding: [0x2f,0xfa,0x84,0xf1]
3243 @ CHECK: sxtb16 r6, r7 @ encoding: [0x2f,0xfa,0x87,0xf6]
3244 @ CHECK: sxtb16 r3, r1, ror #16 @ encoding: [0x2f,0xfa,0xa1,0xf3]
3245 @ CHECK: ite hs @ encoding: [0x2c,0xbf]
3246 @ CHECK: sxtb16hs r3, r5, ror #8 @ encoding: [0x2f,0xfa,0x95,0xf3]
3247 @ CHECK: sxtb16lo r2, r3, ror #24 @ encoding: [0x2f,0xfa,0xb3,0xf2]
3250 @------------------------------------------------------------------------------
3251 @ SXTH
3252 @------------------------------------------------------------------------------
3253 sxth r1, r6, ror #0
3254 sxth r3, r8, ror #8
3255 sxth r9, r3, ror #24
3256 itt ne
3257 sxthne r3, r9
3258 sxthne r2, r2, ror #16
3259 sxth.w r7, r8
3261 @ CHECK: sxth r1, r6 @ encoding: [0x31,0xb2]
3262 @ CHECK: sxth.w r3, r8, ror #8 @ encoding: [0x0f,0xfa,0x98,0xf3]
3263 @ CHECK: sxth.w r9, r3, ror #24 @ encoding: [0x0f,0xfa,0xb3,0xf9]
3264 @ CHECK: itt ne @ encoding: [0x1c,0xbf]
3265 @ CHECK: sxthne.w r3, r9 @ encoding: [0x0f,0xfa,0x89,0xf3]
3266 @ CHECK: sxthne.w r2, r2, ror #16 @ encoding: [0x0f,0xfa,0xa2,0xf2]
3267 @ CHECK: sxth.w r7, r8 @ encoding: [0x0f,0xfa,0x88,0xf7]
3270 @------------------------------------------------------------------------------
3271 @ SXTB
3272 @------------------------------------------------------------------------------
3273 sxtb r5, r6, ror #0
3274 sxtb.w r6, r9, ror #8
3275 sxtb r8, r3, ror #24
3276 ite ge
3277 sxtbge r2, r4
3278 sxtblt r5, r1, ror #16
3280 @ CHECK: sxtb r5, r6 @ encoding: [0x75,0xb2]
3281 @ CHECK: sxtb.w r6, r9, ror #8 @ encoding: [0x4f,0xfa,0x99,0xf6]
3282 @ CHECK: sxtb.w r8, r3, ror #24 @ encoding: [0x4f,0xfa,0xb3,0xf8]
3283 @ CHECK: ite ge @ encoding: [0xac,0xbf]
3284 @ CHECK: sxtbge r2, r4 @ encoding: [0x62,0xb2]
3285 @ CHECK: sxtblt.w r5, r1, ror #16 @ encoding: [0x4f,0xfa,0xa1,0xf5]
3288 @------------------------------------------------------------------------------
3289 @ SXTB16
3290 @------------------------------------------------------------------------------
3291 sxtb16 r1, r4
3292 sxtb16 r6, r7, ror #0
3293 sxtb16 r3, r1, ror #16
3294 ite cs
3295 sxtb16cs r3, r5, ror #8
3296 sxtb16lo r2, r3, ror #24
3298 @ CHECK: sxtb16 r1, r4 @ encoding: [0x2f,0xfa,0x84,0xf1]
3299 @ CHECK: sxtb16 r6, r7 @ encoding: [0x2f,0xfa,0x87,0xf6]
3300 @ CHECK: sxtb16 r3, r1, ror #16 @ encoding: [0x2f,0xfa,0xa1,0xf3]
3301 @ CHECK: ite hs @ encoding: [0x2c,0xbf]
3302 @ CHECK: sxtb16hs r3, r5, ror #8 @ encoding: [0x2f,0xfa,0x95,0xf3]
3303 @ CHECK: sxtb16lo r2, r3, ror #24 @ encoding: [0x2f,0xfa,0xb3,0xf2]
3306 @------------------------------------------------------------------------------
3307 @ SXTH
3308 @------------------------------------------------------------------------------
3309 sxth r1, r6, ror #0
3310 sxth.w r3, r8, ror #8
3311 sxth r9, r3, ror #24
3312 itt ne
3313 sxthne r3, r9
3314 sxthne r2, r2, ror #16
3316 @ CHECK: sxth r1, r6 @ encoding: [0x31,0xb2]
3317 @ CHECK: sxth.w r3, r8, ror #8 @ encoding: [0x0f,0xfa,0x98,0xf3]
3318 @ CHECK: sxth.w r9, r3, ror #24 @ encoding: [0x0f,0xfa,0xb3,0xf9]
3319 @ CHECK: itt ne @ encoding: [0x1c,0xbf]
3320 @ CHECK: sxthne.w r3, r9 @ encoding: [0x0f,0xfa,0x89,0xf3]
3321 @ CHECK: sxthne.w r2, r2, ror #16 @ encoding: [0x0f,0xfa,0xa2,0xf2]
3324 @------------------------------------------------------------------------------
3325 @ TBB/TBH
3326 @------------------------------------------------------------------------------
3327 tbb [r3, r8]
3328 tbh [r3, r8, lsl #1]
3329 it eq
3330 tbbeq [r3, r8]
3331 it cs
3332 tbhcs [r3, r8, lsl #1]
3334 @ CHECK: tbb [r3, r8] @ encoding: [0xd3,0xe8,0x08,0xf0]
3335 @ CHECK: tbh [r3, r8, lsl #1] @ encoding: [0xd3,0xe8,0x18,0xf0]
3336 @ CHECK: it eq @ encoding: [0x08,0xbf]
3337 @ CHECK: tbbeq [r3, r8] @ encoding: [0xd3,0xe8,0x08,0xf0]
3338 @ CHECK: it hs @ encoding: [0x28,0xbf]
3339 @ CHECK: tbhhs [r3, r8, lsl #1] @ encoding: [0xd3,0xe8,0x18,0xf0]
3342 @------------------------------------------------------------------------------
3343 @ TEQ
3344 @------------------------------------------------------------------------------
3345 teq r5, #0xf000
3346 teq r4, r5
3347 teq r4, r5, lsl #5
3348 teq r4, r5, lsr #5
3349 teq r4, r5, lsr #5
3350 teq r4, r5, asr #5
3351 teq r4, r5, ror #5
3353 @ CHECK: teq.w r5, #61440 @ encoding: [0x95,0xf4,0x70,0x4f]
3354 @ CHECK: teq.w r4, r5 @ encoding: [0x94,0xea,0x05,0x0f]
3355 @ CHECK: teq.w r4, r5, lsl #5 @ encoding: [0x94,0xea,0x45,0x1f]
3356 @ CHECK: teq.w r4, r5, lsr #5 @ encoding: [0x94,0xea,0x55,0x1f]
3357 @ CHECK: teq.w r4, r5, lsr #5 @ encoding: [0x94,0xea,0x55,0x1f]
3358 @ CHECK: teq.w r4, r5, asr #5 @ encoding: [0x94,0xea,0x65,0x1f]
3359 @ CHECK: teq.w r4, r5, ror #5 @ encoding: [0x94,0xea,0x75,0x1f]
3362 @------------------------------------------------------------------------------
3363 @ TST
3364 @------------------------------------------------------------------------------
3365 tst r5, #0xf000
3366 tst r2, r5
3367 tst r3, r12, lsl #5
3368 tst r4, r11, lsr #4
3369 tst r5, r10, lsr #12
3370 tst r6, r9, asr #30
3371 tst r7, r8, ror #2
3373 @ CHECK: tst.w r5, #61440 @ encoding: [0x15,0xf4,0x70,0x4f]
3374 @ CHECK: tst r2, r5 @ encoding: [0x2a,0x42]
3375 @ CHECK: tst.w r3, r12, lsl #5 @ encoding: [0x13,0xea,0x4c,0x1f]
3376 @ CHECK: tst.w r4, r11, lsr #4 @ encoding: [0x14,0xea,0x1b,0x1f]
3377 @ CHECK: tst.w r5, r10, lsr #12 @ encoding: [0x15,0xea,0x1a,0x3f]
3378 @ CHECK: tst.w r6, r9, asr #30 @ encoding: [0x16,0xea,0xa9,0x7f]
3379 @ CHECK: tst.w r7, r8, ror #2 @ encoding: [0x17,0xea,0xb8,0x0f]
3382 @------------------------------------------------------------------------------
3383 @ UADD16/UADD8
3384 @------------------------------------------------------------------------------
3385 uadd16 r1, r2, r3
3386 uadd8 r1, r2, r3
3387 ite gt
3388 uadd16gt r1, r2, r3
3389 uadd8le r1, r2, r3
3391 @ CHECK: uadd16 r1, r2, r3 @ encoding: [0x92,0xfa,0x43,0xf1]
3392 @ CHECK: uadd8 r1, r2, r3 @ encoding: [0x82,0xfa,0x43,0xf1]
3393 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
3394 @ CHECK: uadd16gt r1, r2, r3 @ encoding: [0x92,0xfa,0x43,0xf1]
3395 @ CHECK: uadd8le r1, r2, r3 @ encoding: [0x82,0xfa,0x43,0xf1]
3398 @------------------------------------------------------------------------------
3399 @ UASX
3400 @------------------------------------------------------------------------------
3401 uasx r9, r12, r0
3402 it eq
3403 uasxeq r9, r12, r0
3404 uaddsubx r9, r12, r0
3405 it eq
3406 uaddsubxeq r9, r12, r0
3408 @ CHECK: uasx r9, r12, r0 @ encoding: [0xac,0xfa,0x40,0xf9]
3409 @ CHECK: it eq @ encoding: [0x08,0xbf]
3410 @ CHECK: uasxeq r9, r12, r0 @ encoding: [0xac,0xfa,0x40,0xf9]
3411 @ CHECK: uasx r9, r12, r0 @ encoding: [0xac,0xfa,0x40,0xf9]
3412 @ CHECK: it eq @ encoding: [0x08,0xbf]
3413 @ CHECK: uasxeq r9, r12, r0 @ encoding: [0xac,0xfa,0x40,0xf9]
3416 @------------------------------------------------------------------------------
3417 @ UBFX
3418 @------------------------------------------------------------------------------
3419 ubfx r4, r5, #16, #1
3420 it gt
3421 ubfxgt r4, r5, #16, #16
3423 @ CHECK: ubfx r4, r5, #16, #1 @ encoding: [0xc5,0xf3,0x00,0x44]
3424 @ CHECK: it gt @ encoding: [0xc8,0xbf]
3425 @ CHECK: ubfxgt r4, r5, #16, #16 @ encoding: [0xc5,0xf3,0x0f,0x44]
3428 @------------------------------------------------------------------------------
3429 @ UHADD16/UHADD8
3430 @------------------------------------------------------------------------------
3431 uhadd16 r4, r8, r2
3432 uhadd8 r4, r8, r2
3433 itt gt
3434 uhadd16gt r4, r8, r2
3435 uhadd8gt r4, r8, r2
3437 @ CHECK: uhadd16 r4, r8, r2 @ encoding: [0x98,0xfa,0x62,0xf4]
3438 @ CHECK: uhadd8 r4, r8, r2 @ encoding: [0x88,0xfa,0x62,0xf4]
3439 @ CHECK: itt gt @ encoding: [0xc4,0xbf]
3440 @ CHECK: uhadd16gt r4, r8, r2 @ encoding: [0x98,0xfa,0x62,0xf4]
3441 @ CHECK: uhadd8gt r4, r8, r2 @ encoding: [0x88,0xfa,0x62,0xf4]
3444 @------------------------------------------------------------------------------
3445 @ UHASX/UHSAX
3446 @------------------------------------------------------------------------------
3447 uhasx r4, r1, r5
3448 uhsax r5, r6, r6
3449 itt gt
3450 uhasxgt r6, r9, r8
3451 uhsaxgt r7, r8, r12
3452 uhaddsubx r4, r1, r5
3453 uhsubaddx r5, r6, r6
3454 itt gt
3455 uhaddsubxgt r6, r9, r8
3456 uhsubaddxgt r7, r8, r12
3458 @ CHECK: uhasx r4, r1, r5 @ encoding: [0xa1,0xfa,0x65,0xf4]
3459 @ CHECK: uhsax r5, r6, r6 @ encoding: [0xe6,0xfa,0x66,0xf5]
3460 @ CHECK: itt gt @ encoding: [0xc4,0xbf]
3461 @ CHECK: uhasxgt r6, r9, r8 @ encoding: [0xa9,0xfa,0x68,0xf6]
3462 @ CHECK: uhsaxgt r7, r8, r12 @ encoding: [0xe8,0xfa,0x6c,0xf7]
3463 @ CHECK: uhasx r4, r1, r5 @ encoding: [0xa1,0xfa,0x65,0xf4]
3464 @ CHECK: uhsax r5, r6, r6 @ encoding: [0xe6,0xfa,0x66,0xf5]
3465 @ CHECK: itt gt @ encoding: [0xc4,0xbf]
3466 @ CHECK: uhasxgt r6, r9, r8 @ encoding: [0xa9,0xfa,0x68,0xf6]
3467 @ CHECK: uhsaxgt r7, r8, r12 @ encoding: [0xe8,0xfa,0x6c,0xf7]
3470 @------------------------------------------------------------------------------
3471 @ UHSUB16/UHSUB8
3472 @------------------------------------------------------------------------------
3473 uhsub16 r5, r8, r3
3474 uhsub8 r1, r7, r6
3475 itt lt
3476 uhsub16lt r4, r9, r12
3477 uhsub8lt r3, r1, r5
3479 @ CHECK: uhsub16 r5, r8, r3 @ encoding: [0xd8,0xfa,0x63,0xf5]
3480 @ CHECK: uhsub8 r1, r7, r6 @ encoding: [0xc7,0xfa,0x66,0xf1]
3481 @ CHECK: itt lt @ encoding: [0xbc,0xbf]
3482 @ CHECK: uhsub16lt r4, r9, r12 @ encoding: [0xd9,0xfa,0x6c,0xf4]
3483 @ CHECK: uhsub8lt r3, r1, r5 @ encoding: [0xc1,0xfa,0x65,0xf3]
3486 @------------------------------------------------------------------------------
3487 @ UMAAL
3488 @------------------------------------------------------------------------------
3489 umaal r3, r4, r5, r6
3490 it lt
3491 umaallt r3, r4, r5, r6
3493 @ CHECK: umaal r3, r4, r5, r6 @ encoding: [0xe5,0xfb,0x66,0x34]
3494 @ CHECK: it lt @ encoding: [0xb8,0xbf]
3495 @ CHECK: umaallt r3, r4, r5, r6 @ encoding: [0xe5,0xfb,0x66,0x34]
3498 @------------------------------------------------------------------------------
3499 @ UMLAL
3500 @------------------------------------------------------------------------------
3501 umlal r2, r4, r6, r8
3502 it gt
3503 umlalgt r6, r1, r2, r6
3505 @ CHECK: umlal r2, r4, r6, r8 @ encoding: [0xe6,0xfb,0x08,0x24]
3506 @ CHECK: it gt @ encoding: [0xc8,0xbf]
3507 @ CHECK: umlalgt r6, r1, r2, r6 @ encoding: [0xe2,0xfb,0x06,0x61]
3510 @------------------------------------------------------------------------------
3511 @ UMULL
3512 @------------------------------------------------------------------------------
3513 umull r2, r4, r6, r8
3514 it gt
3515 umullgt r6, r1, r2, r6
3517 @ CHECK: umull r2, r4, r6, r8 @ encoding: [0xa6,0xfb,0x08,0x24]
3518 @ CHECK: it gt @ encoding: [0xc8,0xbf]
3519 @ CHECK: umullgt r6, r1, r2, r6 @ encoding: [0xa2,0xfb,0x06,0x61]
3522 @------------------------------------------------------------------------------
3523 @ UQADD16/UQADD8
3524 @------------------------------------------------------------------------------
3525 uqadd16 r1, r2, r3
3526 uqadd8 r3, r4, r8
3527 ite gt
3528 uqadd16gt r4, r7, r9
3529 uqadd8le r8, r1, r2
3531 @ CHECK: uqadd16 r1, r2, r3 @ encoding: [0x92,0xfa,0x53,0xf1]
3532 @ CHECK: uqadd8 r3, r4, r8 @ encoding: [0x84,0xfa,0x58,0xf3]
3533 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
3534 @ CHECK: uqadd16gt r4, r7, r9 @ encoding: [0x97,0xfa,0x59,0xf4]
3535 @ CHECK: uqadd8le r8, r1, r2 @ encoding: [0x81,0xfa,0x52,0xf8]
3538 @------------------------------------------------------------------------------
3539 @ UQASX/UQSAX
3540 @------------------------------------------------------------------------------
3541 uqasx r1, r2, r3
3542 uqsax r3, r4, r8
3543 ite gt
3544 uqasxgt r4, r7, r9
3545 uqsaxle r8, r1, r2
3547 uqaddsubx r1, r2, r3
3548 uqsubaddx r3, r4, r8
3549 ite gt
3550 uqaddsubxgt r4, r7, r9
3551 uqsubaddxle r8, r1, r2
3553 @ CHECK: uqasx r1, r2, r3 @ encoding: [0xa2,0xfa,0x53,0xf1]
3554 @ CHECK: uqsax r3, r4, r8 @ encoding: [0xe4,0xfa,0x58,0xf3]
3555 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
3556 @ CHECK: uqasxgt r4, r7, r9 @ encoding: [0xa7,0xfa,0x59,0xf4]
3557 @ CHECK: uqsaxle r8, r1, r2 @ encoding: [0xe1,0xfa,0x52,0xf8]
3559 @ CHECK: uqasx r1, r2, r3 @ encoding: [0xa2,0xfa,0x53,0xf1]
3560 @ CHECK: uqsax r3, r4, r8 @ encoding: [0xe4,0xfa,0x58,0xf3]
3561 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
3562 @ CHECK: uqasxgt r4, r7, r9 @ encoding: [0xa7,0xfa,0x59,0xf4]
3563 @ CHECK: uqsaxle r8, r1, r2 @ encoding: [0xe1,0xfa,0x52,0xf8]
3566 @------------------------------------------------------------------------------
3567 @ UQSUB16/UQSUB8
3568 @------------------------------------------------------------------------------
3569 uqsub8 r8, r2, r9
3570 uqsub16 r1, r9, r7
3571 ite gt
3572 uqsub8gt r3, r1, r6
3573 uqsub16le r4, r6, r4
3575 @ CHECK: uqsub8 r8, r2, r9 @ encoding: [0xc2,0xfa,0x59,0xf8]
3576 @ CHECK: uqsub16 r1, r9, r7 @ encoding: [0xd9,0xfa,0x57,0xf1]
3577 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
3578 @ CHECK: uqsub8gt r3, r1, r6 @ encoding: [0xc1,0xfa,0x56,0xf3]
3579 @ CHECK: uqsub16le r4, r6, r4 @ encoding: [0xd6,0xfa,0x54,0xf4]
3582 @------------------------------------------------------------------------------
3583 @ UQSUB16/UQSUB8
3584 @------------------------------------------------------------------------------
3585 usad8 r1, r9, r7
3586 usada8 r8, r2, r9, r12
3587 ite gt
3588 usada8gt r3, r1, r6, r9
3589 usad8le r4, r6, r4
3591 @ CHECK: usad8 r1, r9, r7 @ encoding: [0x79,0xfb,0x07,0xf1]
3592 @ CHECK: usada8 r8, r2, r9, r12 @ encoding: [0x72,0xfb,0x09,0xc8]
3593 @ CHECK: ite gt @ encoding: [0xcc,0xbf]
3594 @ CHECK: usada8gt r3, r1, r6, r9 @ encoding: [0x71,0xfb,0x06,0x93]
3595 @ CHECK: usad8le r4, r6, r4 @ encoding: [0x76,0xfb,0x04,0xf4]
3598 @------------------------------------------------------------------------------
3599 @ USAT
3600 @------------------------------------------------------------------------------
3601 usat r8, #1, r10
3602 usat r8, #4, r10, lsl #0
3603 usat r8, #5, r10, lsl #31
3604 usat r8, #16, r10, asr #1
3606 @ CHECK: usat r8, #1, r10 @ encoding: [0x8a,0xf3,0x01,0x08]
3607 @ CHECK: usat r8, #4, r10 @ encoding: [0x8a,0xf3,0x04,0x08]
3608 @ CHECK: usat r8, #5, r10, lsl #31 @ encoding: [0x8a,0xf3,0xc5,0x78]
3609 @ CHECK: usat r8, #16, r10, asr #1 @ encoding: [0xaa,0xf3,0x50,0x08]
3612 @------------------------------------------------------------------------------
3613 @ USAT16
3614 @------------------------------------------------------------------------------
3615 usat16 r2, #2, r7
3616 usat16 r3, #15, r5
3618 @ CHECK: usat16 r2, #2, r7 @ encoding: [0xa7,0xf3,0x02,0x02]
3619 @ CHECK: usat16 r3, #15, r5 @ encoding: [0xa5,0xf3,0x0f,0x03]
3622 @------------------------------------------------------------------------------
3623 @ USAX
3624 @------------------------------------------------------------------------------
3625 usax r2, r3, r4
3626 it ne
3627 usaxne r6, r1, r9
3628 usubaddx r2, r3, r4
3629 it ne
3630 usubaddxne r6, r1, r9
3632 @ CHECK: usax r2, r3, r4 @ encoding: [0xe3,0xfa,0x44,0xf2]
3633 @ CHECK: it ne @ encoding: [0x18,0xbf]
3634 @ CHECK: usaxne r6, r1, r9 @ encoding: [0xe1,0xfa,0x49,0xf6]
3635 @ CHECK: usax r2, r3, r4 @ encoding: [0xe3,0xfa,0x44,0xf2]
3636 @ CHECK: it ne @ encoding: [0x18,0xbf]
3637 @ CHECK: usaxne r6, r1, r9 @ encoding: [0xe1,0xfa,0x49,0xf6]
3640 @------------------------------------------------------------------------------
3641 @ USUB16/USUB8
3642 @------------------------------------------------------------------------------
3643 usub16 r4, r2, r7
3644 usub8 r1, r8, r5
3645 ite hi
3646 usub16hi r1, r1, r3
3647 usub8ls r9, r2, r3
3649 @ CHECK: usub16 r4, r2, r7 @ encoding: [0xd2,0xfa,0x47,0xf4]
3650 @ CHECK: usub8 r1, r8, r5 @ encoding: [0xc8,0xfa,0x45,0xf1]
3651 @ CHECK: ite hi @ encoding: [0x8c,0xbf]
3652 @ CHECK: usub16hi r1, r1, r3 @ encoding: [0xd1,0xfa,0x43,0xf1]
3653 @ CHECK: usub8ls r9, r2, r3 @ encoding: [0xc2,0xfa,0x43,0xf9]
3656 @------------------------------------------------------------------------------
3657 @ UXTAB
3658 @------------------------------------------------------------------------------
3659 uxtab r2, r3, r4
3660 uxtab r4, r5, r6, ror #0
3661 it lt
3662 uxtablt r6, r2, r9, ror #8
3663 uxtab r5, r1, r4, ror #16
3664 uxtab r7, r8, r3, ror #24
3666 @ CHECK: uxtab r2, r3, r4 @ encoding: [0x53,0xfa,0x84,0xf2]
3667 @ CHECK: uxtab r4, r5, r6 @ encoding: [0x55,0xfa,0x86,0xf4]
3668 @ CHECK: it lt @ encoding: [0xb8,0xbf]
3669 @ CHECK: uxtablt r6, r2, r9, ror #8 @ encoding: [0x52,0xfa,0x99,0xf6]
3670 @ CHECK: uxtab r5, r1, r4, ror #16 @ encoding: [0x51,0xfa,0xa4,0xf5]
3671 @ CHECK: uxtab r7, r8, r3, ror #24 @ encoding: [0x58,0xfa,0xb3,0xf7]
3674 @------------------------------------------------------------------------------
3675 @ UXTAB16
3676 @------------------------------------------------------------------------------
3677 it ge
3678 uxtab16ge r0, r1, r4
3679 uxtab16 r6, r2, r7, ror #0
3680 uxtab16 r3, r5, r8, ror #8
3681 uxtab16 r3, r2, r1, ror #16
3682 it eq
3683 uxtab16eq r1, r2, r3, ror #24
3685 @ CHECK: it ge @ encoding: [0xa8,0xbf]
3686 @ CHECK: uxtab16ge r0, r1, r4 @ encoding: [0x31,0xfa,0x84,0xf0]
3687 @ CHECK: uxtab16 r6, r2, r7 @ encoding: [0x32,0xfa,0x87,0xf6]
3688 @ CHECK: uxtab16 r3, r5, r8, ror #8 @ encoding: [0x35,0xfa,0x98,0xf3]
3689 @ CHECK: uxtab16 r3, r2, r1, ror #16 @ encoding: [0x32,0xfa,0xa1,0xf3]
3690 @ CHECK: it eq @ encoding: [0x08,0xbf]
3691 @ CHECK: uxtab16eq r1, r2, r3, ror #24 @ encoding: [0x32,0xfa,0xb3,0xf1]
3694 @------------------------------------------------------------------------------
3695 @ UXTAH
3696 @------------------------------------------------------------------------------
3697 uxtah r1, r3, r9
3698 it hi
3699 uxtahhi r6, r1, r6, ror #0
3700 uxtah r3, r8, r3, ror #8
3701 it lo
3702 uxtahlo r2, r2, r4, ror #16
3703 uxtah r9, r3, r3, ror #24
3705 @ CHECK: uxtah r1, r3, r9 @ encoding: [0x13,0xfa,0x89,0xf1]
3706 @ CHECK: it hi @ encoding: [0x88,0xbf]
3707 @ CHECK: uxtahhi r6, r1, r6 @ encoding: [0x11,0xfa,0x86,0xf6]
3708 @ CHECK: uxtah r3, r8, r3, ror #8 @ encoding: [0x18,0xfa,0x93,0xf3]
3709 @ CHECK: it lo @ encoding: [0x38,0xbf]
3710 @ CHECK: uxtahlo r2, r2, r4, ror #16 @ encoding: [0x12,0xfa,0xa4,0xf2]
3711 @ CHECK: uxtah r9, r3, r3, ror #24 @ encoding: [0x13,0xfa,0xb3,0xf9]
3714 @------------------------------------------------------------------------------
3715 @ UXTB
3716 @------------------------------------------------------------------------------
3717 it ge
3718 uxtbge r2, r4
3719 uxtb r5, r6, ror #0
3720 uxtb r6, r9, ror #8
3721 it cc
3722 uxtbcc r5, r1, ror #16
3723 uxtb r8, r3, ror #24
3724 uxtb.w r7, r8
3726 @ CHECK: it ge @ encoding: [0xa8,0xbf]
3727 @ CHECK: uxtbge r2, r4 @ encoding: [0xe2,0xb2]
3728 @ CHECK: uxtb r5, r6 @ encoding: [0xf5,0xb2]
3729 @ CHECK: uxtb.w r6, r9, ror #8 @ encoding: [0x5f,0xfa,0x99,0xf6]
3730 @ CHECK: it lo @ encoding: [0x38,0xbf]
3731 @ CHECK: uxtblo.w r5, r1, ror #16 @ encoding: [0x5f,0xfa,0xa1,0xf5]
3732 @ CHECK: uxtb.w r8, r3, ror #24 @ encoding: [0x5f,0xfa,0xb3,0xf8]
3733 @ CHECK: uxtb.w r7, r8 @ encoding: [0x5f,0xfa,0x88,0xf7]
3736 @------------------------------------------------------------------------------
3737 @ UXTB16
3738 @------------------------------------------------------------------------------
3739 uxtb16 r1, r4
3740 uxtb16 r6, r7, ror #0
3741 it cs
3742 uxtb16cs r3, r5, ror #8
3743 uxtb16 r3, r1, ror #16
3744 it ge
3745 uxtb16ge r2, r3, ror #24
3747 @ CHECK: uxtb16 r1, r4 @ encoding: [0x3f,0xfa,0x84,0xf1]
3748 @ CHECK: uxtb16 r6, r7 @ encoding: [0x3f,0xfa,0x87,0xf6]
3749 @ CHECK: it hs @ encoding: [0x28,0xbf]
3750 @ CHECK: uxtb16hs r3, r5, ror #8 @ encoding: [0x3f,0xfa,0x95,0xf3]
3751 @ CHECK: uxtb16 r3, r1, ror #16 @ encoding: [0x3f,0xfa,0xa1,0xf3]
3752 @ CHECK: it ge @ encoding: [0xa8,0xbf]
3753 @ CHECK: uxtb16ge r2, r3, ror #24 @ encoding: [0x3f,0xfa,0xb3,0xf2]
3756 @------------------------------------------------------------------------------
3757 @ UXTH
3758 @------------------------------------------------------------------------------
3759 it ne
3760 uxthne r3, r9
3761 uxth r1, r6, ror #0
3762 uxth r3, r8, ror #8
3763 it le
3764 uxthle r2, r2, ror #16
3765 uxth r9, r3, ror #24
3766 uxth.w r7, r8
3768 @ CHECK: it ne @ encoding: [0x18,0xbf]
3769 @ CHECK: uxthne.w r3, r9 @ encoding: [0x1f,0xfa,0x89,0xf3]
3770 @ CHECK: uxth r1, r6 @ encoding: [0xb1,0xb2]
3771 @ CHECK: uxth.w r3, r8, ror #8 @ encoding: [0x1f,0xfa,0x98,0xf3]
3772 @ CHECK: it le @ encoding: [0xd8,0xbf]
3773 @ CHECK: uxthle.w r2, r2, ror #16 @ encoding: [0x1f,0xfa,0xa2,0xf2]
3774 @ CHECK: uxth.w r9, r3, ror #24 @ encoding: [0x1f,0xfa,0xb3,0xf9]
3775 @ CHECK: uxth.w r7, r8 @ encoding: [0x1f,0xfa,0x88,0xf7]
3777 @------------------------------------------------------------------------------
3778 @ WFE/WFI/YIELD/HINT
3779 @------------------------------------------------------------------------------
3782 yield
3783 itet lt
3784 wfelt
3785 wfige
3786 yieldlt
3787 hint.w #4
3788 hint.w #3
3789 hint.w #2
3790 hint.w #1
3791 hint.w #0
3792 hint #4
3793 hint #3
3794 hint #2
3795 hint #1
3796 hint #0
3798 itet lt
3799 hintlt #15
3800 hintge #16
3801 hintlt #239
3803 @ CHECK: wfe @ encoding: [0x20,0xbf]
3804 @ CHECK: wfi @ encoding: [0x30,0xbf]
3805 @ CHECK: yield @ encoding: [0x10,0xbf]
3806 @ CHECK: itet lt @ encoding: [0xb6,0xbf]
3807 @ CHECK: wfelt @ encoding: [0x20,0xbf]
3808 @ CHECK: wfige @ encoding: [0x30,0xbf]
3809 @ CHECK: yieldlt @ encoding: [0x10,0xbf]
3810 @ CHECK: sev.w @ encoding: [0xaf,0xf3,0x04,0x80]
3811 @ CHECK: wfi.w @ encoding: [0xaf,0xf3,0x03,0x80]
3812 @ CHECK: wfe.w @ encoding: [0xaf,0xf3,0x02,0x80]
3813 @ CHECK: yield.w @ encoding: [0xaf,0xf3,0x01,0x80]
3814 @ CHECK: nop.w @ encoding: [0xaf,0xf3,0x00,0x80]
3815 @ CHECK: sev @ encoding: [0x40,0xbf]
3816 @ CHECK: wfi @ encoding: [0x30,0xbf]
3817 @ CHECK: wfe @ encoding: [0x20,0xbf]
3818 @ CHECK: yield @ encoding: [0x10,0xbf]
3819 @ CHECK: nop @ encoding: [0x00,0xbf]
3821 @ CHECK: itet lt @ encoding: [0xb6,0xbf]
3822 @ CHECK: hintlt #15 @ encoding: [0xf0,0xbf]
3823 @ CHECK: hintge.w #16 @ encoding: [0xaf,0xf3,0x10,0x80]
3824 @ CHECK: hintlt.w #239 @ encoding: [0xaf,0xf3,0xef,0x80]
3826 @------------------------------------------------------------------------------
3827 @ Unallocated wide/narrow hints
3828 @------------------------------------------------------------------------------
3829 hint #7
3830 hint.w #7
3831 @ CHECK: hint #7 @ encoding: [0x70,0xbf]
3832 @ CHECK: hint.w #7 @ encoding: [0xaf,0xf3,0x07,0x80]
3834 @------------------------------------------------------------------------------
3835 @ Alternate syntax for LDR*(literal) encodings
3836 @------------------------------------------------------------------------------
3837 ldrb r11, [pc, #22]
3838 ldrh r11, [pc, #22]
3839 ldrsb r11, [pc, #22]
3840 ldrsh r11, [pc, #22]
3841 ldr.w r11, [pc, #22]
3842 ldrb.w r11, [pc, #22]
3843 ldrh.w r11, [pc, #22]
3844 ldrsb.w r11, [pc, #22]
3845 ldrsh.w r11, [pc, #22]
3847 @ CHECK: ldrb.w r11, [pc, #22] @ encoding: [0x9f,0xf8,0x16,0xb0]
3848 @ CHECK: ldrh.w r11, [pc, #22] @ encoding: [0xbf,0xf8,0x16,0xb0]
3849 @ CHECK: ldrsb.w r11, [pc, #22] @ encoding: [0x9f,0xf9,0x16,0xb0]
3850 @ CHECK: ldrsh.w r11, [pc, #22] @ encoding: [0xbf,0xf9,0x16,0xb0]
3851 @ CHECK: ldr.w r11, [pc, #22] @ encoding: [0xdf,0xf8,0x16,0xb0]
3852 @ CHECK: ldrb.w r11, [pc, #22] @ encoding: [0x9f,0xf8,0x16,0xb0]
3853 @ CHECK: ldrh.w r11, [pc, #22] @ encoding: [0xbf,0xf8,0x16,0xb0]
3854 @ CHECK: ldrsb.w r11, [pc, #22] @ encoding: [0x9f,0xf9,0x16,0xb0]
3855 @ CHECK: ldrsh.w r11, [pc, #22] @ encoding: [0xbf,0xf9,0x16,0xb0]
3857 ldr r11, [pc, #-22]
3858 ldrb r11, [pc, #-22]
3859 ldrh r11, [pc, #-22]
3860 ldrsb r11, [pc, #-22]
3861 ldrsh r11, [pc, #-22]
3862 ldr.w r11, [pc, #-22]
3863 ldrb.w r11, [pc, #-22]
3864 ldrh.w r11, [pc, #-22]
3865 ldrsb.w r11, [pc, #-22]
3866 ldrsh.w r11, [pc, #-22]
3868 @ CHECK: ldr.w r11, [pc, #-22] @ encoding: [0x5f,0xf8,0x16,0xb0]
3869 @ CHECK: ldrb.w r11, [pc, #-22] @ encoding: [0x1f,0xf8,0x16,0xb0]
3870 @ CHECK: ldrh.w r11, [pc, #-22] @ encoding: [0x3f,0xf8,0x16,0xb0]
3871 @ CHECK: ldrsb.w r11, [pc, #-22] @ encoding: [0x1f,0xf9,0x16,0xb0]
3872 @ CHECK: ldrsh.w r11, [pc, #-22] @ encoding: [0x3f,0xf9,0x16,0xb0]
3873 @ CHECK: ldr.w r11, [pc, #-22] @ encoding: [0x5f,0xf8,0x16,0xb0]
3874 @ CHECK: ldrb.w r11, [pc, #-22] @ encoding: [0x1f,0xf8,0x16,0xb0]
3875 @ CHECK: ldrh.w r11, [pc, #-22] @ encoding: [0x3f,0xf8,0x16,0xb0]
3876 @ CHECK: ldrsb.w r11, [pc, #-22] @ encoding: [0x1f,0xf9,0x16,0xb0]
3877 @ CHECK: ldrsh.w r11, [pc, #-22] @ encoding: [0x3f,0xf9,0x16,0xb0]
3879 @ rdar://12596361
3880 ldr r1, [pc, #12]
3881 @ CHECK: ldr r1, [pc, #12] @ encoding: [0x03,0x49]
3883 @ rdar://14214063
3884 subs pc, lr, #4
3885 @ CHECK: subs pc, lr, #4 @ encoding: [0xde,0xf3,0x04,0x8f]