1 @ RUN
: llvm-mc
-mcpu
=cortex-a8
-triple arm-unknown-unknown
-show-encoding
%s | FileCheck
%s
4 @ CHECK
: encoding
: [0x00,0xf0,0x20,0xe3]
8 @ CHECK
: encoding
: [0x00,0xf0,0x20,0x03]
12 @ CHECK
: encoding
: [0xfe,0xde,0xff,0xe7]
16 @ CHECK
: encoding
: [0x1e,0xff,0x2f,0xe1]
19 @ CHECK
: vqdmull.s32 q8
, d17
, d16
20 @ CHECK
: encoding
: [0xa0,0x0d,0xe1,0xf2]
21 vqdmull.s32 q8
, d17
, d16
23 @ CHECK
: ldmia
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x92,0xe8]
24 @ CHECK
: ldmib
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x92,0xe9]
25 @ CHECK
: ldmda
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x12,0xe8]
26 @ CHECK
: ldmdb
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x12,0xe9]
27 ldmia
r2, {r1,r3-
r6,sp
}
28 ldmib
r2, {r1,r3-
r6,sp
}
29 ldmda
r2, {r1,r3-
r6,sp
}
30 ldmdb
r2, {r1,r3-
r6,sp
}
32 @ CHECK
: stmia
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x82,0xe8]
33 @ CHECK
: stmib
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x82,0xe9]
34 @ CHECK
: stmda
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x02,0xe8]
35 @ CHECK
: stmdb
r2, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x02,0xe9]
36 stmia
r2, {r1,r3-
r6,sp
}
37 stmib
r2, {r1,r3-
r6,sp
}
38 stmda
r2, {r1,r3-
r6,sp
}
39 stmdb
r2, {r1,r3-
r6,sp
}
41 @ CHECK
: ldmia
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0xb2,0xe8]
42 @ CHECK
: ldmib
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0xb2,0xe9]
43 @ CHECK
: ldmda
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x32,0xe8]
44 @ CHECK
: ldmdb
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x32,0xe9]
45 ldmia
r2!, {r1,r3-
r6,sp
}
46 ldmib
r2!, {r1,r3-
r6,sp
}
47 ldmda
r2!, {r1,r3-
r6,sp
}
48 ldmdb
r2!, {r1,r3-
r6,sp
}
50 @ CHECK
: stmia
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0xa2,0xe8]
51 @ CHECK
: stmib
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0xa2,0xe9]
52 @ CHECK
: stmda
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x22,0xe8]
53 @ CHECK
: stmdb
r2!, {r1, r3, r4, r5, r6, sp
} @ encoding
: [0x7a,0x20,0x22,0xe9]
54 stmia
r2!, {r1,r3-
r6,sp
}
55 stmib
r2!, {r1,r3-
r6,sp
}
56 stmda
r2!, {r1,r3-
r6,sp
}
57 stmdb
r2!, {r1,r3-
r6,sp
}
59 @ CHECK
: and r1, r2, r3 @ encoding
: [0x03,0x10,0x02,0xe0]
62 @ FIXME
: This is wrong
, we are dropping the
's' for now.
63 @ CHECK-FIXME
: ands
r1, r2, r3 @ encoding
: [0x03,0x10,0x12,0xe0]
66 @ CHECK
: eor
r1, r2, r3 @ encoding
: [0x03,0x10,0x22,0xe0]
69 @ FIXME
: This is wrong
, we are dropping the
's' for now.
70 @ CHECK-FIXME
: eors
r1, r2, r3 @ encoding
: [0x03,0x10,0x32,0xe0]
73 @ CHECK
: sub r1, r2, r3 @ encoding
: [0x03,0x10,0x42,0xe0]
76 @ FIXME
: This is wrong
, we are dropping the
's' for now.
77 @ CHECK-FIXME
: subs
r1, r2, r3 @ encoding
: [0x03,0x10,0x52,0xe0]
80 @ CHECK
: add r1, r2, r3 @ encoding
: [0x03,0x10,0x82,0xe0]
83 @ FIXME
: This is wrong
, we are dropping the
's' for now.
84 @ CHECK-FIXME
: adds
r1, r2, r3 @ encoding
: [0x03,0x10,0x92,0xe0]
87 @ CHECK
: adc
r1, r2, r3 @ encoding
: [0x03,0x10,0xa2,0xe0]
90 @ CHECK
: sbc
r1, r2, r3 @ encoding
: [0x03,0x10,0xc2,0xe0]
93 @ CHECK
: orr
r1, r2, r3 @ encoding
: [0x03,0x10,0x82,0xe1]
96 @ FIXME
: This is wrong
, we are dropping the
's' for now.
97 @ CHECK-FIXME
: orrs
r1, r2, r3 @ encoding
: [0x03,0x10,0x92,0xe1]
100 @ CHECK
: bic
r1, r2, r3 @ encoding
: [0x03,0x10,0xc2,0xe1]
103 @ FIXME
: This is wrong
, we are dropping the
's' for now.
104 @ CHECK-FIXME
: bics
r1, r2, r3 @ encoding
: [0x03,0x10,0xd2,0xe1]
107 @ CHECK
: mov
r1, r2 @ encoding
: [0x02,0x10,0xa0,0xe1]
110 @ CHECK
: mvn
r1, r2 @ encoding
: [0x02,0x10,0xe0,0xe1]
113 @ FIXME
: This is wrong
, we are dropping the
's' for now.
114 @ CHECK-FIXME
: mvns
r1, r2 @ encoding
: [0x02,0x10,0xf0,0xe1]
117 @ CHECK
: rsb
r1, r2, r3 @ encoding
: [0x03,0x10,0x62,0xe0]
120 @ CHECK
: rsc
r1, r2, r3 @ encoding
: [0x03,0x10,0xe2,0xe0]
123 @ FIXME
: This is broken
, CCOut operands don
't work correctly when their presence
124 @ may depend on flags.
125 @ CHECK-FIXME:: mlas r1, r2, r3, r4 @ encoding: [0x92,0x43,0x31,0xe0]
128 @ CHECK: bfi r0, r0, #5, #7 @ encoding: [0x90,0x02,0xcb,0xe7]
131 @ CHECK: bkpt #10 @ encoding: [0x7a,0x00,0x20,0xe1]
134 @ CHECK: isb @ encoding: [0x6f,0xf0,0x7f,0xf5]
136 @ CHECK: mrs r8, cpsr @ encoding: [0x00,0x80,0x0f,0xe1]
139 @ CHECK: mcr p7, #1, r5, c1, c1, #4 @ encoding: [0x91,0x57,0x21,0xee]
140 mcr p7, #1, r5, c1, c1, #4
141 @ CHECK: mrc p14, #0, r1, c1, c2, #4 @ encoding: [0x92,0x1e,0x11,0xee]
142 mrc p14, #0, r1, c1, c2, #4
143 @ CHECK: mcrr p7, #1, r5, r4, c1 @ encoding: [0x11,0x57,0x44,0xec]
144 mcrr p7, #1, r5, r4, c1
145 @ CHECK: mrrc p7, #1, r5, r4, c1 @ encoding: [0x11,0x57,0x54,0xec]
146 mrrc p7, #1, r5, r4, c1
148 @ CHECK: mcr2 p7, #1, r5, c1, c1, #4 @ encoding: [0x91,0x57,0x21,0xfe]
149 mcr2 p7, #1, r5, c1, c1, #4
150 @ CHECK: mrc2 p14, #0, r1, c1, c2, #4 @ encoding: [0x92,0x1e,0x11,0xfe]
151 mrc2 p14, #0, r1, c1, c2, #4
152 @ CHECK: mcrr2 p7, #1, r5, r4, c1 @ encoding: [0x11,0x57,0x44,0xfc]
153 mcrr2 p7, #1, r5, r4, c1
154 @ CHECK: mrrc2 p7, #1, r5, r4, c1 @ encoding: [0x11,0x57,0x54,0xfc]
155 mrrc2 p7, #1, r5, r4, c1
157 @ CHECK: cdp p7, #1, c1, c1, c1, #4 @ encoding: [0x81,0x17,0x11,0xee]
158 cdp p7, #1, c1, c1, c1, #4
159 @ CHECK: cdp2 p7, #1, c1, c1, c1, #4 @ encoding: [0x81,0x17,0x11,0xfe]
160 cdp2 p7, #1, c1, c1, c1, #4
162 @ CHECK: clrex @ encoding: [0x1f,0xf0,0x7f,0xf5]
165 @ CHECK: clz r9, r0 @ encoding: [0x10,0x9f,0x6f,0xe1]
168 @ CHECK: qadd r1, r2, r3 @ encoding: [0x52,0x10,0x03,0xe1]
171 @ CHECK: qsub r1, r2, r3 @ encoding: [0x52,0x10,0x23,0xe1]
174 @ CHECK: qdadd r1, r2, r3 @ encoding: [0x52,0x10,0x43,0xe1]
177 @ CHECK: qdsub r1, r2, r3 @ encoding: [0x52,0x10,0x63,0xe1]
180 @ CHECK: wfe @ encoding: [0x02,0xf0,0x20,0xe3]
183 @ CHECK: wfi @ encoding: [0x03,0xf0,0x20,0xe3]
186 @ CHECK: yield @ encoding: [0x01,0xf0,0x20,0xe3]
189 @ CHECK: nop @ encoding: [0x00,0xf0,0x20,0xe3]
192 @ CHECK: dmb sy @ encoding: [0x5f,0xf0,0x7f,0xf5]
195 @ CHECK: dmb st @ encoding: [0x5e,0xf0,0x7f,0xf5]
198 @ CHECK: dmb ish @ encoding: [0x5b,0xf0,0x7f,0xf5]
201 @ CHECK: dmb ishst @ encoding: [0x5a,0xf0,0x7f,0xf5]
204 @ CHECK: dmb nsh @ encoding: [0x57,0xf0,0x7f,0xf5]
207 @ CHECK: dmb nshst @ encoding: [0x56,0xf0,0x7f,0xf5]
210 @ CHECK: dmb osh @ encoding: [0x53,0xf0,0x7f,0xf5]
213 @ CHECK: dmb oshst @ encoding: [0x52,0xf0,0x7f,0xf5]
216 @ CHECK: dsb sy @ encoding: [0x4f,0xf0,0x7f,0xf5]
219 @ CHECK: dsb st @ encoding: [0x4e,0xf0,0x7f,0xf5]
222 @ CHECK: dsb ish @ encoding: [0x4b,0xf0,0x7f,0xf5]
225 @ CHECK: dsb ishst @ encoding: [0x4a,0xf0,0x7f,0xf5]
228 @ CHECK: dsb nsh @ encoding: [0x47,0xf0,0x7f,0xf5]
231 @ CHECK: dsb nshst @ encoding: [0x46,0xf0,0x7f,0xf5]
234 @ CHECK: dsb osh @ encoding: [0x43,0xf0,0x7f,0xf5]
237 @ CHECK: dsb oshst @ encoding: [0x42,0xf0,0x7f,0xf5]
240 @ CHECK: cpsie aif @ encoding: [0xc0,0x01,0x08,0xf1]
243 @ CHECK: cps #15 @ encoding: [0x0f,0x00,0x02,0xf1]
246 @ CHECK: cpsie if, #10 @ encoding: [0xca,0x00,0x0a,0xf1]
249 @ CHECK: msr cpsr_fc, r0 @ encoding: [0x00,0xf0,0x29,0xe1]
252 @ CHECK: msr cpsr_s, r0 @ encoding: [0x00,0xf0,0x24,0xe1]
255 @ CHECK: msr cpsr_f, r0 @ encoding: [0x00,0xf0,0x28,0xe1]
258 @ CHECK: msr cpsr_fs, r0 @ encoding: [0x00,0xf0,0x2c,0xe1]
261 @ CHECK: msr cpsr_fc, r0 @ encoding: [0x00,0xf0,0x29,0xe1]
264 @ CHECK: msr cpsr_c, r0 @ encoding: [0x00,0xf0,0x21,0xe1]
267 @ CHECK: msr cpsr_x, r0 @ encoding: [0x00,0xf0,0x22,0xe1]
270 @ CHECK: msr cpsr_fc, r0 @ encoding: [0x00,0xf0,0x29,0xe1]
273 @ CHECK: msr cpsr_fc, r0 @ encoding: [0x00,0xf0,0x29,0xe1]
276 @ CHECK: msr cpsr_fsx, r0 @ encoding: [0x00,0xf0,0x2e,0xe1]
279 @ CHECK: msr spsr_fc, r0 @ encoding: [0x00,0xf0,0x69,0xe1]
282 @ CHECK: msr spsr_fsxc, r0 @ encoding: [0x00,0xf0,0x6f,0xe1]
285 @ CHECK: msr cpsr_fsxc, r0 @ encoding: [0x00,0xf0,0x2f,0xe1]
288 @ CHECK: add r1, r2, r3, lsl r4 @ encoding: [0x13,0x14,0x82,0xe0]
289 add r1, r2, r3, lsl r4
291 @ CHECK: strexb r0, r1, [r2] @ encoding: [0x91,0x0f,0xc2,0xe1]
294 @ CHECK: strexh r0, r1, [r2] @ encoding: [0x91,0x0f,0xe2,0xe1]
297 @ CHECK: strex r0, r1, [r2] @ encoding: [0x91,0x0f,0x82,0xe1]
300 @ CHECK: strexd r0, r2, r3, [r1] @ encoding: [0x92,0x0f,0xa1,0xe1]
301 strexd r0, r2, r3, [r1]
303 @ CHECK: ldrexb r0, [r0] @ encoding: [0x9f,0x0f,0xd0,0xe1]
306 @ CHECK: ldrexh r0, [r0] @ encoding: [0x9f,0x0f,0xf0,0xe1]
309 @ CHECK: ldrex r0, [r0] @ encoding: [0x9f,0x0f,0x90,0xe1]
312 @ CHECK: ldrexd r0, r1, [r0] @ encoding: [0x9f,0x0f,0xb0,0xe1]
315 @ CHECK: ssat16 r0, #7, r0 @ encoding: [0x30,0x0f,0xa6,0xe6]