Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / llvm / test / MC / ARM / neon-bitwise-encoding.s
blob7f3a5a02c9eadbd0b96d045e1e68f1276a9d97a5
1 @ RUN: llvm-mc -mcpu=cortex-a8 -triple arm-unknown-unknown -show-encoding < %s \
2 @ RUN: | FileCheck %s
4 vand d16, d17, d16
5 vand q8, q8, q9
7 @ CHECK: vand d16, d17, d16 @ encoding: [0xb0,0x01,0x41,0xf2]
8 @ CHECK: vand q8, q8, q9 @ encoding: [0xf2,0x01,0x40,0xf2]
10 veor d16, d17, d16
11 veor q8, q8, q9
13 @ CHECK: veor d16, d17, d16 @ encoding: [0xb0,0x01,0x41,0xf3]
14 @ CHECK: veor q8, q8, q9 @ encoding: [0xf2,0x01,0x40,0xf3]
16 vorr d16, d17, d16
17 vorr q8, q8, q9
19 @ CHECK: vorr d16, d17, d16 @ encoding: [0xb0,0x01,0x61,0xf2]
20 @ CHECK: vorr q8, q8, q9 @ encoding: [0xf2,0x01,0x60,0xf2]
22 vorr.i32 d16, #0x1000000
23 vorr.i32 q8, #0x1000000
24 vorr.i32 q8, #0x0
26 @ CHECK: vorr.i32 d16, #0x1000000 @ encoding: [0x11,0x07,0xc0,0xf2]
27 @ CHECK: vorr.i32 q8, #0x1000000 @ encoding: [0x51,0x07,0xc0,0xf2]
28 @ CHECK: vorr.i32 q8, #0x0 @ encoding: [0x50,0x01,0xc0,0xf2]
30 vbic d16, d17, d16
31 vbic q8, q8, q9
32 vbic q10, q11
33 vbic d9, d1
34 vbic.i16 d16, #0xFF00
35 vbic.i16 q8, #0xFF00
36 vbic.i16 d16, #0x00FF
37 vbic.i16 q8, #0x00FF
38 vbic.i32 d16, #0xFF000000
39 vbic.i32 q8, #0xFF000000
40 vbic.i32 d16, #0x00FF0000
41 vbic.i32 q8, #0x00FF0000
42 vbic.i32 d16, #0x0000FF00
43 vbic.i32 q8, #0x0000FF00
44 vbic.i32 d16, #0x000000FF
45 vbic.i32 q8, #0x000000FF
47 @ CHECK: vbic d16, d17, d16 @ encoding: [0xb0,0x01,0x51,0xf2]
48 @ CHECK: vbic q8, q8, q9 @ encoding: [0xf2,0x01,0x50,0xf2]
49 @ CHECK: vbic q10, q10, q11 @ encoding: [0xf6,0x41,0x54,0xf2]
50 @ CHECK: vbic d9, d9, d1 @ encoding: [0x11,0x91,0x19,0xf2]
51 @ CHECK: vbic.i16 d16, #0xff00 @ encoding: [0x3f,0x0b,0xc7,0xf3]
52 @ CHECK: vbic.i16 q8, #0xff00 @ encoding: [0x7f,0x0b,0xc7,0xf3]
53 @ CHECK: vbic.i16 d16, #0xff @ encoding: [0x3f,0x09,0xc7,0xf3]
54 @ CHECK: vbic.i16 q8, #0xff @ encoding: [0x7f,0x09,0xc7,0xf3]
55 @ CHECK: vbic.i32 d16, #0xff000000 @ encoding: [0x3f,0x07,0xc7,0xf3]
56 @ CHECK: vbic.i32 q8, #0xff000000 @ encoding: [0x7f,0x07,0xc7,0xf3]
57 @ CHECK: vbic.i32 d16, #0xff0000 @ encoding: [0x3f,0x05,0xc7,0xf3]
58 @ CHECK: vbic.i32 q8, #0xff0000 @ encoding: [0x7f,0x05,0xc7,0xf3]
59 @ CHECK: vbic.i32 d16, #0xff00 @ encoding: [0x3f,0x03,0xc7,0xf3]
60 @ CHECK: vbic.i32 q8, #0xff00 @ encoding: [0x7f,0x03,0xc7,0xf3]
61 @ CHECK: vbic.i32 d16, #0xff @ encoding: [0x3f,0x01,0xc7,0xf3]
62 @ CHECK: vbic.i32 q8, #0xff @ encoding: [0x7f,0x01,0xc7,0xf3]
64 vand.i16 d10, #0xff03
65 vand.i16 q10, #0xff03
66 vand.i16 d10, #0x03ff
67 vand.i16 q10, #0x03ff
68 vand.i32 d10, #0x03ffffff
69 vand.i32 q10, #0x03ffffff
70 vand.i32 d10, #0xff03ffff
71 vand.i32 q10, #0xff03ffff
72 vand.i32 d10, #0xffff03ff
73 vand.i32 q10, #0xffff03ff
74 vand.i32 d10, #0xffffff03
75 vand.i32 q10, #0xffffff03
77 @ CHECK: vbic.i16 d10, #0xfc @ encoding: [0x3c,0xa9,0x87,0xf3]
78 @ CHECK: vbic.i16 q10, #0xfc @ encoding: [0x7c,0x49,0xc7,0xf3]
79 @ CHECK: vbic.i16 d10, #0xfc00 @ encoding: [0x3c,0xab,0x87,0xf3]
80 @ CHECK: vbic.i16 q10, #0xfc00 @ encoding: [0x7c,0x4b,0xc7,0xf3]
81 @ CHECK: vbic.i32 d10, #0xfc000000 @ encoding: [0x3c,0xa7,0x87,0xf3]
82 @ CHECK: vbic.i32 q10, #0xfc000000 @ encoding: [0x7c,0x47,0xc7,0xf3]
83 @ CHECK: vbic.i32 d10, #0xfc0000 @ encoding: [0x3c,0xa5,0x87,0xf3]
84 @ CHECK: vbic.i32 q10, #0xfc0000 @ encoding: [0x7c,0x45,0xc7,0xf3]
85 @ CHECK: vbic.i32 d10, #0xfc00 @ encoding: [0x3c,0xa3,0x87,0xf3]
86 @ CHECK: vbic.i32 q10, #0xfc00 @ encoding: [0x7c,0x43,0xc7,0xf3]
87 @ CHECK: vbic.i32 d10, #0xfc @ encoding: [0x3c,0xa1,0x87,0xf3]
88 @ CHECK: vbic.i32 q10, #0xfc @ encoding: [0x7c,0x41,0xc7,0xf3]
90 vorn d16, d17, d16
91 vorn q8, q8, q9
93 @ CHECK: vorn d16, d17, d16 @ encoding: [0xb0,0x01,0x71,0xf2]
94 @ CHECK: vorn q8, q8, q9 @ encoding: [0xf2,0x01,0x70,0xf2]
96 vmvn d16, d16
97 vmvn q8, q8
99 @ CHECK: vmvn d16, d16 @ encoding: [0xa0,0x05,0xf0,0xf3]
100 @ CHECK: vmvn q8, q8 @ encoding: [0xe0,0x05,0xf0,0xf3]
102 vbsl d18, d17, d16
103 vbsl q8, q10, q9
104 vbit d18, d17, d16
105 vbit q8, q10, q9
106 vbif d18, d17, d16
107 vbif q8, q10, q9
109 @ CHECK: vbsl d18, d17, d16 @ encoding: [0xb0,0x21,0x51,0xf3]
110 @ CHECK: vbsl q8, q10, q9 @ encoding: [0xf2,0x01,0x54,0xf3]
111 @ CHECK: vbit d18, d17, d16 @ encoding: [0xb0,0x21,0x61,0xf3]
112 @ CHECK: vbit q8, q10, q9 @ encoding: [0xf2,0x01,0x64,0xf3]
113 @ CHECK: vbif d18, d17, d16 @ encoding: [0xb0,0x21,0x71,0xf3]
114 @ CHECK: vbif q8, q10, q9 @ encoding: [0xf2,0x01,0x74,0xf3]
116 @ Size suffices are optional.
117 veor q4, q7, q3
118 veor.8 q4, q7, q3
119 veor.16 q4, q7, q3
120 veor.32 q4, q7, q3
121 veor.64 q4, q7, q3
123 veor.i8 q4, q7, q3
124 veor.i16 q4, q7, q3
125 veor.i32 q4, q7, q3
126 veor.i64 q4, q7, q3
128 veor.s8 q4, q7, q3
129 veor.s16 q4, q7, q3
130 veor.s32 q4, q7, q3
131 veor.s64 q4, q7, q3
133 veor.u8 q4, q7, q3
134 veor.u16 q4, q7, q3
135 veor.u32 q4, q7, q3
136 veor.u64 q4, q7, q3
138 veor.p8 q4, q7, q3
139 veor.p16 q4, q7, q3
140 veor.f32 q4, q7, q3
141 veor.f64 q4, q7, q3
143 veor.f q4, q7, q3
144 veor.d q4, q7, q3
146 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
147 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
148 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
149 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
150 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
152 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
153 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
154 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
155 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
157 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
158 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
159 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
160 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
162 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
163 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
164 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
165 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
167 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
168 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
169 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
170 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
172 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
173 @ CHECK: veor q4, q7, q3 @ encoding: [0x56,0x81,0x0e,0xf3]
176 vand d4, d7, d3
177 vand.8 d4, d7, d3
178 vand.16 d4, d7, d3
179 vand.32 d4, d7, d3
180 vand.64 d4, d7, d3
182 vand.i8 d4, d7, d3
183 vand.i16 d4, d7, d3
184 vand.i32 d4, d7, d3
185 vand.i64 d4, d7, d3
187 vand.s8 d4, d7, d3
188 vand.s16 d4, d7, d3
189 vand.s32 d4, d7, d3
190 vand.s64 d4, d7, d3
192 vand.u8 d4, d7, d3
193 vand.u16 d4, d7, d3
194 vand.u32 d4, d7, d3
195 vand.u64 d4, d7, d3
197 vand.p8 d4, d7, d3
198 vand.p16 d4, d7, d3
199 vand.f32 d4, d7, d3
200 vand.f64 d4, d7, d3
202 vand.f d4, d7, d3
203 vand.d d4, d7, d3
205 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
206 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
207 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
208 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
209 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
211 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
212 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
213 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
214 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
216 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
217 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
218 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
219 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
221 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
222 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
223 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
224 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
226 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
227 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
228 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
229 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
231 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
232 @ CHECK: vand d4, d7, d3 @ encoding: [0x13,0x41,0x07,0xf2]
234 vorr d4, d7, d3
235 vorr.8 d4, d7, d3
236 vorr.16 d4, d7, d3
237 vorr.32 d4, d7, d3
238 vorr.64 d4, d7, d3
240 vorr.i8 d4, d7, d3
241 vorr.i16 d4, d7, d3
242 vorr.i32 d4, d7, d3
243 vorr.i64 d4, d7, d3
245 vorr.s8 d4, d7, d3
246 vorr.s16 d4, d7, d3
247 vorr.s32 q4, q7, q3
248 vorr.s64 q4, q7, q3
250 vorr.u8 q4, q7, q3
251 vorr.u16 q4, q7, q3
252 vorr.u32 q4, q7, q3
253 vorr.u64 q4, q7, q3
255 vorr.p8 q4, q7, q3
256 vorr.p16 q4, q7, q3
257 vorr.f32 q4, q7, q3
258 vorr.f64 q4, q7, q3
260 vorr.f q4, q7, q3
261 vorr.d q4, q7, q3
263 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
264 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
265 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
266 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
267 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
269 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
270 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
271 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
272 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
274 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
275 @ CHECK: vorr d4, d7, d3 @ encoding: [0x13,0x41,0x27,0xf2]
276 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
277 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
279 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
280 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
281 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
282 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
284 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
285 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
286 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
287 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
289 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
290 @ CHECK: vorr q4, q7, q3 @ encoding: [0x56,0x81,0x2e,0xf2]
292 @ Two-operand aliases
293 vand q6, q5
294 vand.s8 q6, q5
295 vand.s16 q7, q1
296 vand.s32 q8, q2
297 vand.f64 q8, q2
299 veor q6, q5
300 veor.8 q6, q5
301 veor.p16 q7, q1
302 veor.u32 q8, q2
303 veor.d q8, q2
305 veor q6, q5
306 veor.i8 q6, q5
307 veor.16 q7, q1
308 veor.f q8, q2
309 veor.i64 q8, q2
311 vclt.s16 q5, #0
312 vclt.s16 d5, #0
314 vceq.s16 q5, q3
315 vceq.s16 d5, d3
317 vcgt.s16 q5, q3
318 vcgt.s16 d5, d3
320 vcge.s16 q5, q3
321 vcge.s16 d5, d3
323 vcgt.s16 q5, #0
324 vcgt.s16 d5, #0
326 vcge.s16 q5, #0
327 vcge.s16 d5, #0
329 vceq.s16 q5, #0
330 vceq.s16 d5, #0
332 vcle.s16 q5, #0
333 vcle.s16 d5, #0
335 vacge.f32 d5, d30
336 vacge.f32 q5, q3
338 vacgt.f32 d5, d30
339 vacgt.f32 q5, q3
341 @ FIXME: We don't have an alias that reverses the operands
342 @ vacle.f32 d5, d30
343 @ vacle.f32 q5, q3
344 @ vaclt.f32 d5, d30
345 @ vaclt.f32 q5, q3
347 @ CHECK: vand q6, q6, q5 @ encoding: [0x5a,0xc1,0x0c,0xf2]
348 @ CHECK: vand q6, q6, q5 @ encoding: [0x5a,0xc1,0x0c,0xf2]
349 @ CHECK: vand q7, q7, q1 @ encoding: [0x52,0xe1,0x0e,0xf2]
350 @ CHECK: vand q8, q8, q2 @ encoding: [0xd4,0x01,0x40,0xf2]
351 @ CHECK: vand q8, q8, q2 @ encoding: [0xd4,0x01,0x40,0xf2]
353 @ CHECK: veor q6, q6, q5 @ encoding: [0x5a,0xc1,0x0c,0xf3]
354 @ CHECK: veor q6, q6, q5 @ encoding: [0x5a,0xc1,0x0c,0xf3]
355 @ CHECK: veor q7, q7, q1 @ encoding: [0x52,0xe1,0x0e,0xf3]
356 @ CHECK: veor q8, q8, q2 @ encoding: [0xd4,0x01,0x40,0xf3]
357 @ CHECK: veor q8, q8, q2 @ encoding: [0xd4,0x01,0x40,0xf3]
359 @ CHECK: veor q6, q6, q5 @ encoding: [0x5a,0xc1,0x0c,0xf3]
360 @ CHECK: veor q6, q6, q5 @ encoding: [0x5a,0xc1,0x0c,0xf3]
361 @ CHECK: veor q7, q7, q1 @ encoding: [0x52,0xe1,0x0e,0xf3]
362 @ CHECK: veor q8, q8, q2 @ encoding: [0xd4,0x01,0x40,0xf3]
363 @ CHECK: veor q8, q8, q2 @ encoding: [0xd4,0x01,0x40,0xf3]
364 @ CHECK: vclt.s16 q5, q5, #0 @ encoding: [0x4a,0xa2,0xb5,0xf3]
365 @ CHECK: vclt.s16 d5, d5, #0 @ encoding: [0x05,0x52,0xb5,0xf3]
367 @ CHECK: vceq.i16 q5, q5, q3 @ encoding: [0x56,0xa8,0x1a,0xf3]
368 @ CHECK: vceq.i16 d5, d5, d3 @ encoding: [0x13,0x58,0x15,0xf3]
370 @ CHECK: vcgt.s16 q5, q5, q3 @ encoding: [0x46,0xa3,0x1a,0xf2]
371 @ CHECK: vcgt.s16 d5, d5, d3 @ encoding: [0x03,0x53,0x15,0xf2]
373 @ CHECK: vcge.s16 q5, q5, q3 @ encoding: [0x56,0xa3,0x1a,0xf2]
374 @ CHECK: vcge.s16 d5, d5, d3 @ encoding: [0x13,0x53,0x15,0xf2]
376 @ CHECK: vcgt.s16 q5, q5, #0 @ encoding: [0x4a,0xa0,0xb5,0xf3]
377 @ CHECK: vcgt.s16 d5, d5, #0 @ encoding: [0x05,0x50,0xb5,0xf3]
379 @ CHECK: vcge.s16 q5, q5, #0 @ encoding: [0xca,0xa0,0xb5,0xf3]
380 @ CHECK: vcge.s16 d5, d5, #0 @ encoding: [0x85,0x50,0xb5,0xf3]
382 @ CHECK: vceq.i16 q5, q5, #0 @ encoding: [0x4a,0xa1,0xb5,0xf3]
383 @ CHECK: vceq.i16 d5, d5, #0 @ encoding: [0x05,0x51,0xb5,0xf3]
385 @ CHECK: vcle.s16 q5, q5, #0 @ encoding: [0xca,0xa1,0xb5,0xf3]
386 @ CHECK: vcle.s16 d5, d5, #0 @ encoding: [0x85,0x51,0xb5,0xf3]
388 @ CHECK: vacge.f32 d5, d5, d30 @ encoding: [0x3e,0x5e,0x05,0xf3]
389 @ CHECK: vacge.f32 q5, q5, q3 @ encoding: [0x56,0xae,0x0a,0xf3]
391 @ CHECK: vacgt.f32 d5, d5, d30 @ encoding: [0x3e,0x5e,0x25,0xf3]
392 @ CHECK: vacgt.f32 q5, q5, q3 @ encoding: [0x56,0xae,0x2a,0xf3]