1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 2
2 ; RUN: llc -mtriple=aarch64 -verify-machineinstrs %s -o - 2>&1 | FileCheck %s --check-prefixes=CHECK,CHECK-SD
3 ; RUN: llc -mtriple=aarch64 -global-isel -global-isel-abort=2 -verify-machineinstrs %s -o - 2>&1 | FileCheck %s --check-prefixes=CHECK,CHECK-GI
5 ; CHECK-GI: warning: Instruction selection used fallback path for zext_v16i10_v16i16
7 define i16 @zext_i8_to_i16(i8 %a) {
8 ; CHECK-LABEL: zext_i8_to_i16:
9 ; CHECK: // %bb.0: // %entry
10 ; CHECK-NEXT: and w0, w0, #0xff
13 %c = zext i8 %a to i16
17 define i32 @zext_i8_to_i32(i8 %a) {
18 ; CHECK-LABEL: zext_i8_to_i32:
19 ; CHECK: // %bb.0: // %entry
20 ; CHECK-NEXT: and w0, w0, #0xff
23 %c = zext i8 %a to i32
27 define i64 @zext_i8_to_i64(i8 %a) {
28 ; CHECK-LABEL: zext_i8_to_i64:
29 ; CHECK: // %bb.0: // %entry
30 ; CHECK-NEXT: // kill: def $w0 killed $w0 def $x0
31 ; CHECK-NEXT: and x0, x0, #0xff
34 %c = zext i8 %a to i64
38 define i10 @zext_i8_to_i10(i8 %a) {
39 ; CHECK-LABEL: zext_i8_to_i10:
40 ; CHECK: // %bb.0: // %entry
41 ; CHECK-NEXT: and w0, w0, #0xff
44 %c = zext i8 %a to i10
48 define i32 @zext_i16_to_i32(i16 %a) {
49 ; CHECK-LABEL: zext_i16_to_i32:
50 ; CHECK: // %bb.0: // %entry
51 ; CHECK-NEXT: and w0, w0, #0xffff
54 %c = zext i16 %a to i32
58 define i64 @zext_i16_to_i64(i16 %a) {
59 ; CHECK-LABEL: zext_i16_to_i64:
60 ; CHECK: // %bb.0: // %entry
61 ; CHECK-NEXT: // kill: def $w0 killed $w0 def $x0
62 ; CHECK-NEXT: and x0, x0, #0xffff
65 %c = zext i16 %a to i64
69 define i64 @zext_i32_to_i64(i32 %a) {
70 ; CHECK-LABEL: zext_i32_to_i64:
71 ; CHECK: // %bb.0: // %entry
72 ; CHECK-NEXT: mov w0, w0
75 %c = zext i32 %a to i64
79 define i16 @zext_i10_to_i16(i10 %a) {
80 ; CHECK-LABEL: zext_i10_to_i16:
81 ; CHECK: // %bb.0: // %entry
82 ; CHECK-NEXT: and w0, w0, #0x3ff
85 %c = zext i10 %a to i16
89 define i32 @zext_i10_to_i32(i10 %a) {
90 ; CHECK-LABEL: zext_i10_to_i32:
91 ; CHECK: // %bb.0: // %entry
92 ; CHECK-NEXT: and w0, w0, #0x3ff
95 %c = zext i10 %a to i32
99 define i64 @zext_i10_to_i64(i10 %a) {
100 ; CHECK-LABEL: zext_i10_to_i64:
101 ; CHECK: // %bb.0: // %entry
102 ; CHECK-NEXT: // kill: def $w0 killed $w0 def $x0
103 ; CHECK-NEXT: and x0, x0, #0x3ff
106 %c = zext i10 %a to i64
110 define <2 x i16> @zext_v2i8_v2i16(<2 x i8> %a) {
111 ; CHECK-LABEL: zext_v2i8_v2i16:
112 ; CHECK: // %bb.0: // %entry
113 ; CHECK-NEXT: movi d1, #0x0000ff000000ff
114 ; CHECK-NEXT: and v0.8b, v0.8b, v1.8b
117 %c = zext <2 x i8> %a to <2 x i16>
121 define <2 x i32> @zext_v2i8_v2i32(<2 x i8> %a) {
122 ; CHECK-LABEL: zext_v2i8_v2i32:
123 ; CHECK: // %bb.0: // %entry
124 ; CHECK-NEXT: movi d1, #0x0000ff000000ff
125 ; CHECK-NEXT: and v0.8b, v0.8b, v1.8b
128 %c = zext <2 x i8> %a to <2 x i32>
132 define <2 x i64> @zext_v2i8_v2i64(<2 x i8> %a) {
133 ; CHECK-SD-LABEL: zext_v2i8_v2i64:
134 ; CHECK-SD: // %bb.0: // %entry
135 ; CHECK-SD-NEXT: movi d1, #0x0000ff000000ff
136 ; CHECK-SD-NEXT: and v0.8b, v0.8b, v1.8b
137 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
140 ; CHECK-GI-LABEL: zext_v2i8_v2i64:
141 ; CHECK-GI: // %bb.0: // %entry
142 ; CHECK-GI-NEXT: movi v1.2d, #0x000000000000ff
143 ; CHECK-GI-NEXT: ushll v0.2d, v0.2s, #0
144 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
147 %c = zext <2 x i8> %a to <2 x i64>
151 define <2 x i32> @zext_v2i16_v2i32(<2 x i16> %a) {
152 ; CHECK-LABEL: zext_v2i16_v2i32:
153 ; CHECK: // %bb.0: // %entry
154 ; CHECK-NEXT: movi d1, #0x00ffff0000ffff
155 ; CHECK-NEXT: and v0.8b, v0.8b, v1.8b
158 %c = zext <2 x i16> %a to <2 x i32>
162 define <2 x i64> @zext_v2i16_v2i64(<2 x i16> %a) {
163 ; CHECK-SD-LABEL: zext_v2i16_v2i64:
164 ; CHECK-SD: // %bb.0: // %entry
165 ; CHECK-SD-NEXT: movi d1, #0x00ffff0000ffff
166 ; CHECK-SD-NEXT: and v0.8b, v0.8b, v1.8b
167 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
170 ; CHECK-GI-LABEL: zext_v2i16_v2i64:
171 ; CHECK-GI: // %bb.0: // %entry
172 ; CHECK-GI-NEXT: movi v1.2d, #0x0000000000ffff
173 ; CHECK-GI-NEXT: ushll v0.2d, v0.2s, #0
174 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
177 %c = zext <2 x i16> %a to <2 x i64>
181 define <2 x i64> @zext_v2i32_v2i64(<2 x i32> %a) {
182 ; CHECK-LABEL: zext_v2i32_v2i64:
183 ; CHECK: // %bb.0: // %entry
184 ; CHECK-NEXT: ushll v0.2d, v0.2s, #0
187 %c = zext <2 x i32> %a to <2 x i64>
191 define <2 x i16> @zext_v2i10_v2i16(<2 x i10> %a) {
192 ; CHECK-LABEL: zext_v2i10_v2i16:
193 ; CHECK: // %bb.0: // %entry
194 ; CHECK-NEXT: movi v1.2s, #3, msl #8
195 ; CHECK-NEXT: and v0.8b, v0.8b, v1.8b
198 %c = zext <2 x i10> %a to <2 x i16>
202 define <2 x i32> @zext_v2i10_v2i32(<2 x i10> %a) {
203 ; CHECK-LABEL: zext_v2i10_v2i32:
204 ; CHECK: // %bb.0: // %entry
205 ; CHECK-NEXT: movi v1.2s, #3, msl #8
206 ; CHECK-NEXT: and v0.8b, v0.8b, v1.8b
209 %c = zext <2 x i10> %a to <2 x i32>
213 define <2 x i64> @zext_v2i10_v2i64(<2 x i10> %a) {
214 ; CHECK-SD-LABEL: zext_v2i10_v2i64:
215 ; CHECK-SD: // %bb.0: // %entry
216 ; CHECK-SD-NEXT: movi v1.2s, #3, msl #8
217 ; CHECK-SD-NEXT: and v0.8b, v0.8b, v1.8b
218 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
221 ; CHECK-GI-LABEL: zext_v2i10_v2i64:
222 ; CHECK-GI: // %bb.0: // %entry
223 ; CHECK-GI-NEXT: adrp x8, .LCPI18_0
224 ; CHECK-GI-NEXT: ushll v0.2d, v0.2s, #0
225 ; CHECK-GI-NEXT: ldr q1, [x8, :lo12:.LCPI18_0]
226 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
229 %c = zext <2 x i10> %a to <2 x i64>
233 define <3 x i16> @zext_v3i8_v3i16(<3 x i8> %a) {
234 ; CHECK-SD-LABEL: zext_v3i8_v3i16:
235 ; CHECK-SD: // %bb.0: // %entry
236 ; CHECK-SD-NEXT: fmov s0, w0
237 ; CHECK-SD-NEXT: mov v0.h[1], w1
238 ; CHECK-SD-NEXT: mov v0.h[2], w2
239 ; CHECK-SD-NEXT: bic v0.4h, #255, lsl #8
240 ; CHECK-SD-NEXT: // kill: def $d0 killed $d0 killed $q0
243 ; CHECK-GI-LABEL: zext_v3i8_v3i16:
244 ; CHECK-GI: // %bb.0: // %entry
245 ; CHECK-GI-NEXT: fmov s0, w0
246 ; CHECK-GI-NEXT: mov w8, #255 // =0xff
247 ; CHECK-GI-NEXT: fmov s1, w8
248 ; CHECK-GI-NEXT: mov v0.s[1], w1
249 ; CHECK-GI-NEXT: mov v2.16b, v1.16b
250 ; CHECK-GI-NEXT: mov v0.s[2], w2
251 ; CHECK-GI-NEXT: mov v2.h[1], v1.h[0]
252 ; CHECK-GI-NEXT: mov v0.s[3], w8
253 ; CHECK-GI-NEXT: mov v2.h[2], v1.h[0]
254 ; CHECK-GI-NEXT: xtn v0.4h, v0.4s
255 ; CHECK-GI-NEXT: mov v2.h[3], v0.h[0]
256 ; CHECK-GI-NEXT: and v0.8b, v0.8b, v2.8b
259 %c = zext <3 x i8> %a to <3 x i16>
263 define <3 x i32> @zext_v3i8_v3i32(<3 x i8> %a) {
264 ; CHECK-SD-LABEL: zext_v3i8_v3i32:
265 ; CHECK-SD: // %bb.0: // %entry
266 ; CHECK-SD-NEXT: fmov s0, w0
267 ; CHECK-SD-NEXT: movi v1.2d, #0x0000ff000000ff
268 ; CHECK-SD-NEXT: mov v0.h[1], w1
269 ; CHECK-SD-NEXT: mov v0.h[2], w2
270 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
271 ; CHECK-SD-NEXT: and v0.16b, v0.16b, v1.16b
274 ; CHECK-GI-LABEL: zext_v3i8_v3i32:
275 ; CHECK-GI: // %bb.0: // %entry
276 ; CHECK-GI-NEXT: mov w8, #255 // =0xff
277 ; CHECK-GI-NEXT: fmov s0, w0
278 ; CHECK-GI-NEXT: fmov s1, w8
279 ; CHECK-GI-NEXT: mov v0.s[1], w1
280 ; CHECK-GI-NEXT: mov v1.s[1], w8
281 ; CHECK-GI-NEXT: mov v0.s[2], w2
282 ; CHECK-GI-NEXT: mov v1.s[2], w8
283 ; CHECK-GI-NEXT: mov v0.s[3], w8
284 ; CHECK-GI-NEXT: mov v1.s[3], w8
285 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
288 %c = zext <3 x i8> %a to <3 x i32>
292 define <3 x i64> @zext_v3i8_v3i64(<3 x i8> %a) {
293 ; CHECK-SD-LABEL: zext_v3i8_v3i64:
294 ; CHECK-SD: // %bb.0: // %entry
295 ; CHECK-SD-NEXT: fmov s0, w0
296 ; CHECK-SD-NEXT: movi v1.2d, #0x000000000000ff
297 ; CHECK-SD-NEXT: fmov s3, w2
298 ; CHECK-SD-NEXT: movi v2.2d, #0000000000000000
299 ; CHECK-SD-NEXT: mov v0.s[1], w1
300 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
301 ; CHECK-SD-NEXT: and v0.16b, v0.16b, v1.16b
302 ; CHECK-SD-NEXT: ushll v1.2d, v3.2s, #0
303 ; CHECK-SD-NEXT: mov v2.b[0], v1.b[0]
304 ; CHECK-SD-NEXT: ext v1.16b, v0.16b, v0.16b, #8
305 ; CHECK-SD-NEXT: // kill: def $d0 killed $d0 killed $q0
306 ; CHECK-SD-NEXT: // kill: def $d1 killed $d1 killed $q1
307 ; CHECK-SD-NEXT: // kill: def $d2 killed $d2 killed $q2
310 ; CHECK-GI-LABEL: zext_v3i8_v3i64:
311 ; CHECK-GI: // %bb.0: // %entry
312 ; CHECK-GI-NEXT: // kill: def $w0 killed $w0 def $x0
313 ; CHECK-GI-NEXT: fmov d1, x0
314 ; CHECK-GI-NEXT: // kill: def $w1 killed $w1 def $x1
315 ; CHECK-GI-NEXT: movi v0.2d, #0x000000000000ff
316 ; CHECK-GI-NEXT: // kill: def $w2 killed $w2 def $x2
317 ; CHECK-GI-NEXT: and x8, x2, #0xff
318 ; CHECK-GI-NEXT: fmov d2, x8
319 ; CHECK-GI-NEXT: mov v1.d[1], x1
320 ; CHECK-GI-NEXT: and v0.16b, v1.16b, v0.16b
321 ; CHECK-GI-NEXT: mov d1, v0.d[1]
322 ; CHECK-GI-NEXT: // kill: def $d0 killed $d0 killed $q0
325 %c = zext <3 x i8> %a to <3 x i64>
329 define <3 x i32> @zext_v3i16_v3i32(<3 x i16> %a) {
330 ; CHECK-SD-LABEL: zext_v3i16_v3i32:
331 ; CHECK-SD: // %bb.0: // %entry
332 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
335 ; CHECK-GI-LABEL: zext_v3i16_v3i32:
336 ; CHECK-GI: // %bb.0: // %entry
337 ; CHECK-GI-NEXT: // kill: def $d0 killed $d0 def $q0
338 ; CHECK-GI-NEXT: umov w8, v0.h[0]
339 ; CHECK-GI-NEXT: umov w9, v0.h[1]
340 ; CHECK-GI-NEXT: fmov s1, w8
341 ; CHECK-GI-NEXT: umov w8, v0.h[2]
342 ; CHECK-GI-NEXT: mov v1.s[1], w9
343 ; CHECK-GI-NEXT: mov v1.s[2], w8
344 ; CHECK-GI-NEXT: mov v1.s[3], w8
345 ; CHECK-GI-NEXT: mov v0.16b, v1.16b
348 %c = zext <3 x i16> %a to <3 x i32>
352 define <3 x i64> @zext_v3i16_v3i64(<3 x i16> %a) {
353 ; CHECK-SD-LABEL: zext_v3i16_v3i64:
354 ; CHECK-SD: // %bb.0: // %entry
355 ; CHECK-SD-NEXT: ushll v2.4s, v0.4h, #0
356 ; CHECK-SD-NEXT: ushll v0.2d, v2.2s, #0
357 ; CHECK-SD-NEXT: ushll2 v2.2d, v2.4s, #0
358 ; CHECK-SD-NEXT: // kill: def $d2 killed $d2 killed $q2
359 ; CHECK-SD-NEXT: ext v1.16b, v0.16b, v0.16b, #8
360 ; CHECK-SD-NEXT: // kill: def $d0 killed $d0 killed $q0
361 ; CHECK-SD-NEXT: // kill: def $d1 killed $d1 killed $q1
364 ; CHECK-GI-LABEL: zext_v3i16_v3i64:
365 ; CHECK-GI: // %bb.0: // %entry
366 ; CHECK-GI-NEXT: // kill: def $d0 killed $d0 def $q0
367 ; CHECK-GI-NEXT: umov w8, v0.h[0]
368 ; CHECK-GI-NEXT: umov w9, v0.h[1]
369 ; CHECK-GI-NEXT: umov w10, v0.h[2]
370 ; CHECK-GI-NEXT: fmov d0, x8
371 ; CHECK-GI-NEXT: fmov d1, x9
372 ; CHECK-GI-NEXT: fmov d2, x10
375 %c = zext <3 x i16> %a to <3 x i64>
379 define <3 x i64> @zext_v3i32_v3i64(<3 x i32> %a) {
380 ; CHECK-SD-LABEL: zext_v3i32_v3i64:
381 ; CHECK-SD: // %bb.0: // %entry
382 ; CHECK-SD-NEXT: ushll v3.2d, v0.2s, #0
383 ; CHECK-SD-NEXT: ushll2 v2.2d, v0.4s, #0
384 ; CHECK-SD-NEXT: // kill: def $d2 killed $d2 killed $q2
385 ; CHECK-SD-NEXT: fmov d0, d3
386 ; CHECK-SD-NEXT: ext v1.16b, v3.16b, v3.16b, #8
387 ; CHECK-SD-NEXT: // kill: def $d1 killed $d1 killed $q1
390 ; CHECK-GI-LABEL: zext_v3i32_v3i64:
391 ; CHECK-GI: // %bb.0: // %entry
392 ; CHECK-GI-NEXT: mov w8, v0.s[0]
393 ; CHECK-GI-NEXT: mov w9, v0.s[1]
394 ; CHECK-GI-NEXT: mov w10, v0.s[2]
395 ; CHECK-GI-NEXT: fmov d0, x8
396 ; CHECK-GI-NEXT: fmov d1, x9
397 ; CHECK-GI-NEXT: fmov d2, x10
400 %c = zext <3 x i32> %a to <3 x i64>
404 define <3 x i16> @zext_v3i10_v3i16(<3 x i10> %a) {
405 ; CHECK-SD-LABEL: zext_v3i10_v3i16:
406 ; CHECK-SD: // %bb.0: // %entry
407 ; CHECK-SD-NEXT: fmov s0, w0
408 ; CHECK-SD-NEXT: mov v0.h[1], w1
409 ; CHECK-SD-NEXT: mov v0.h[2], w2
410 ; CHECK-SD-NEXT: bic v0.4h, #252, lsl #8
411 ; CHECK-SD-NEXT: // kill: def $d0 killed $d0 killed $q0
414 ; CHECK-GI-LABEL: zext_v3i10_v3i16:
415 ; CHECK-GI: // %bb.0: // %entry
416 ; CHECK-GI-NEXT: fmov s0, w0
417 ; CHECK-GI-NEXT: mov w8, #1023 // =0x3ff
418 ; CHECK-GI-NEXT: fmov s1, w8
419 ; CHECK-GI-NEXT: mov v0.s[1], w1
420 ; CHECK-GI-NEXT: mov v2.16b, v1.16b
421 ; CHECK-GI-NEXT: mov v0.s[2], w2
422 ; CHECK-GI-NEXT: mov v2.h[1], v1.h[0]
423 ; CHECK-GI-NEXT: mov v0.s[3], w8
424 ; CHECK-GI-NEXT: mov v2.h[2], v1.h[0]
425 ; CHECK-GI-NEXT: xtn v0.4h, v0.4s
426 ; CHECK-GI-NEXT: mov v2.h[3], v0.h[0]
427 ; CHECK-GI-NEXT: and v0.8b, v0.8b, v2.8b
430 %c = zext <3 x i10> %a to <3 x i16>
434 define <3 x i32> @zext_v3i10_v3i32(<3 x i10> %a) {
435 ; CHECK-SD-LABEL: zext_v3i10_v3i32:
436 ; CHECK-SD: // %bb.0: // %entry
437 ; CHECK-SD-NEXT: fmov s0, w0
438 ; CHECK-SD-NEXT: movi v1.4s, #3, msl #8
439 ; CHECK-SD-NEXT: mov v0.h[1], w1
440 ; CHECK-SD-NEXT: mov v0.h[2], w2
441 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
442 ; CHECK-SD-NEXT: and v0.16b, v0.16b, v1.16b
445 ; CHECK-GI-LABEL: zext_v3i10_v3i32:
446 ; CHECK-GI: // %bb.0: // %entry
447 ; CHECK-GI-NEXT: mov w8, #1023 // =0x3ff
448 ; CHECK-GI-NEXT: fmov s0, w0
449 ; CHECK-GI-NEXT: fmov s1, w8
450 ; CHECK-GI-NEXT: mov v0.s[1], w1
451 ; CHECK-GI-NEXT: mov v1.s[1], w8
452 ; CHECK-GI-NEXT: mov v0.s[2], w2
453 ; CHECK-GI-NEXT: mov v1.s[2], w8
454 ; CHECK-GI-NEXT: mov v0.s[3], w8
455 ; CHECK-GI-NEXT: mov v1.s[3], w8
456 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
459 %c = zext <3 x i10> %a to <3 x i32>
463 define <3 x i64> @zext_v3i10_v3i64(<3 x i10> %a) {
464 ; CHECK-SD-LABEL: zext_v3i10_v3i64:
465 ; CHECK-SD: // %bb.0: // %entry
466 ; CHECK-SD-NEXT: fmov s0, w0
467 ; CHECK-SD-NEXT: fmov s1, w2
468 ; CHECK-SD-NEXT: mov w8, #1023 // =0x3ff
469 ; CHECK-SD-NEXT: dup v2.2d, x8
470 ; CHECK-SD-NEXT: mov v0.s[1], w1
471 ; CHECK-SD-NEXT: ushll v3.2d, v1.2s, #0
472 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
473 ; CHECK-SD-NEXT: and v0.16b, v0.16b, v2.16b
474 ; CHECK-SD-NEXT: and v2.8b, v3.8b, v2.8b
475 ; CHECK-SD-NEXT: ext v1.16b, v0.16b, v0.16b, #8
476 ; CHECK-SD-NEXT: // kill: def $d0 killed $d0 killed $q0
477 ; CHECK-SD-NEXT: // kill: def $d1 killed $d1 killed $q1
480 ; CHECK-GI-LABEL: zext_v3i10_v3i64:
481 ; CHECK-GI: // %bb.0: // %entry
482 ; CHECK-GI-NEXT: // kill: def $w0 killed $w0 def $x0
483 ; CHECK-GI-NEXT: fmov d0, x0
484 ; CHECK-GI-NEXT: // kill: def $w1 killed $w1 def $x1
485 ; CHECK-GI-NEXT: adrp x8, .LCPI27_0
486 ; CHECK-GI-NEXT: // kill: def $w2 killed $w2 def $x2
487 ; CHECK-GI-NEXT: ldr q1, [x8, :lo12:.LCPI27_0]
488 ; CHECK-GI-NEXT: and x8, x2, #0x3ff
489 ; CHECK-GI-NEXT: fmov d2, x8
490 ; CHECK-GI-NEXT: mov v0.d[1], x1
491 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
492 ; CHECK-GI-NEXT: mov d1, v0.d[1]
493 ; CHECK-GI-NEXT: // kill: def $d0 killed $d0 killed $q0
496 %c = zext <3 x i10> %a to <3 x i64>
500 define <4 x i16> @zext_v4i8_v4i16(<4 x i8> %a) {
501 ; CHECK-SD-LABEL: zext_v4i8_v4i16:
502 ; CHECK-SD: // %bb.0: // %entry
503 ; CHECK-SD-NEXT: bic v0.4h, #255, lsl #8
506 ; CHECK-GI-LABEL: zext_v4i8_v4i16:
507 ; CHECK-GI: // %bb.0: // %entry
508 ; CHECK-GI-NEXT: movi d1, #0xff00ff00ff00ff
509 ; CHECK-GI-NEXT: and v0.8b, v0.8b, v1.8b
512 %c = zext <4 x i8> %a to <4 x i16>
516 define <4 x i32> @zext_v4i8_v4i32(<4 x i8> %a) {
517 ; CHECK-SD-LABEL: zext_v4i8_v4i32:
518 ; CHECK-SD: // %bb.0: // %entry
519 ; CHECK-SD-NEXT: bic v0.4h, #255, lsl #8
520 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
523 ; CHECK-GI-LABEL: zext_v4i8_v4i32:
524 ; CHECK-GI: // %bb.0: // %entry
525 ; CHECK-GI-NEXT: movi v1.2d, #0x0000ff000000ff
526 ; CHECK-GI-NEXT: ushll v0.4s, v0.4h, #0
527 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
530 %c = zext <4 x i8> %a to <4 x i32>
534 define <4 x i64> @zext_v4i8_v4i64(<4 x i8> %a) {
535 ; CHECK-SD-LABEL: zext_v4i8_v4i64:
536 ; CHECK-SD: // %bb.0: // %entry
537 ; CHECK-SD-NEXT: bic v0.4h, #255, lsl #8
538 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
539 ; CHECK-SD-NEXT: ushll2 v1.2d, v0.4s, #0
540 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
543 ; CHECK-GI-LABEL: zext_v4i8_v4i64:
544 ; CHECK-GI: // %bb.0: // %entry
545 ; CHECK-GI-NEXT: ushll v0.4s, v0.4h, #0
546 ; CHECK-GI-NEXT: movi v1.2d, #0x000000000000ff
547 ; CHECK-GI-NEXT: ushll v2.2d, v0.2s, #0
548 ; CHECK-GI-NEXT: ushll2 v3.2d, v0.4s, #0
549 ; CHECK-GI-NEXT: and v0.16b, v2.16b, v1.16b
550 ; CHECK-GI-NEXT: and v1.16b, v3.16b, v1.16b
553 %c = zext <4 x i8> %a to <4 x i64>
557 define <4 x i32> @zext_v4i16_v4i32(<4 x i16> %a) {
558 ; CHECK-LABEL: zext_v4i16_v4i32:
559 ; CHECK: // %bb.0: // %entry
560 ; CHECK-NEXT: ushll v0.4s, v0.4h, #0
563 %c = zext <4 x i16> %a to <4 x i32>
567 define <4 x i64> @zext_v4i16_v4i64(<4 x i16> %a) {
568 ; CHECK-SD-LABEL: zext_v4i16_v4i64:
569 ; CHECK-SD: // %bb.0: // %entry
570 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
571 ; CHECK-SD-NEXT: ushll2 v1.2d, v0.4s, #0
572 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
575 ; CHECK-GI-LABEL: zext_v4i16_v4i64:
576 ; CHECK-GI: // %bb.0: // %entry
577 ; CHECK-GI-NEXT: ushll v1.4s, v0.4h, #0
578 ; CHECK-GI-NEXT: ushll v0.2d, v1.2s, #0
579 ; CHECK-GI-NEXT: ushll2 v1.2d, v1.4s, #0
582 %c = zext <4 x i16> %a to <4 x i64>
586 define <4 x i64> @zext_v4i32_v4i64(<4 x i32> %a) {
587 ; CHECK-SD-LABEL: zext_v4i32_v4i64:
588 ; CHECK-SD: // %bb.0: // %entry
589 ; CHECK-SD-NEXT: ushll2 v1.2d, v0.4s, #0
590 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
593 ; CHECK-GI-LABEL: zext_v4i32_v4i64:
594 ; CHECK-GI: // %bb.0: // %entry
595 ; CHECK-GI-NEXT: ushll v2.2d, v0.2s, #0
596 ; CHECK-GI-NEXT: ushll2 v1.2d, v0.4s, #0
597 ; CHECK-GI-NEXT: mov v0.16b, v2.16b
600 %c = zext <4 x i32> %a to <4 x i64>
604 define <4 x i16> @zext_v4i10_v4i16(<4 x i10> %a) {
605 ; CHECK-SD-LABEL: zext_v4i10_v4i16:
606 ; CHECK-SD: // %bb.0: // %entry
607 ; CHECK-SD-NEXT: bic v0.4h, #252, lsl #8
610 ; CHECK-GI-LABEL: zext_v4i10_v4i16:
611 ; CHECK-GI: // %bb.0: // %entry
612 ; CHECK-GI-NEXT: mvni v1.4h, #252, lsl #8
613 ; CHECK-GI-NEXT: and v0.8b, v0.8b, v1.8b
616 %c = zext <4 x i10> %a to <4 x i16>
620 define <4 x i32> @zext_v4i10_v4i32(<4 x i10> %a) {
621 ; CHECK-SD-LABEL: zext_v4i10_v4i32:
622 ; CHECK-SD: // %bb.0: // %entry
623 ; CHECK-SD-NEXT: bic v0.4h, #252, lsl #8
624 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
627 ; CHECK-GI-LABEL: zext_v4i10_v4i32:
628 ; CHECK-GI: // %bb.0: // %entry
629 ; CHECK-GI-NEXT: movi v1.4s, #3, msl #8
630 ; CHECK-GI-NEXT: ushll v0.4s, v0.4h, #0
631 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
634 %c = zext <4 x i10> %a to <4 x i32>
638 define <4 x i64> @zext_v4i10_v4i64(<4 x i10> %a) {
639 ; CHECK-SD-LABEL: zext_v4i10_v4i64:
640 ; CHECK-SD: // %bb.0: // %entry
641 ; CHECK-SD-NEXT: bic v0.4h, #252, lsl #8
642 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
643 ; CHECK-SD-NEXT: ushll2 v1.2d, v0.4s, #0
644 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
647 ; CHECK-GI-LABEL: zext_v4i10_v4i64:
648 ; CHECK-GI: // %bb.0: // %entry
649 ; CHECK-GI-NEXT: ushll v0.4s, v0.4h, #0
650 ; CHECK-GI-NEXT: adrp x8, .LCPI36_0
651 ; CHECK-GI-NEXT: ldr q3, [x8, :lo12:.LCPI36_0]
652 ; CHECK-GI-NEXT: ushll v1.2d, v0.2s, #0
653 ; CHECK-GI-NEXT: ushll2 v2.2d, v0.4s, #0
654 ; CHECK-GI-NEXT: and v0.16b, v1.16b, v3.16b
655 ; CHECK-GI-NEXT: and v1.16b, v2.16b, v3.16b
658 %c = zext <4 x i10> %a to <4 x i64>
662 define <8 x i16> @zext_v8i8_v8i16(<8 x i8> %a) {
663 ; CHECK-LABEL: zext_v8i8_v8i16:
664 ; CHECK: // %bb.0: // %entry
665 ; CHECK-NEXT: ushll v0.8h, v0.8b, #0
668 %c = zext <8 x i8> %a to <8 x i16>
672 define <8 x i32> @zext_v8i8_v8i32(<8 x i8> %a) {
673 ; CHECK-SD-LABEL: zext_v8i8_v8i32:
674 ; CHECK-SD: // %bb.0: // %entry
675 ; CHECK-SD-NEXT: ushll v0.8h, v0.8b, #0
676 ; CHECK-SD-NEXT: ushll2 v1.4s, v0.8h, #0
677 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
680 ; CHECK-GI-LABEL: zext_v8i8_v8i32:
681 ; CHECK-GI: // %bb.0: // %entry
682 ; CHECK-GI-NEXT: ushll v1.8h, v0.8b, #0
683 ; CHECK-GI-NEXT: ushll v0.4s, v1.4h, #0
684 ; CHECK-GI-NEXT: ushll2 v1.4s, v1.8h, #0
687 %c = zext <8 x i8> %a to <8 x i32>
691 define <8 x i64> @zext_v8i8_v8i64(<8 x i8> %a) {
692 ; CHECK-SD-LABEL: zext_v8i8_v8i64:
693 ; CHECK-SD: // %bb.0: // %entry
694 ; CHECK-SD-NEXT: ushll v0.8h, v0.8b, #0
695 ; CHECK-SD-NEXT: ushll v1.4s, v0.4h, #0
696 ; CHECK-SD-NEXT: ushll2 v2.4s, v0.8h, #0
697 ; CHECK-SD-NEXT: ushll v0.2d, v1.2s, #0
698 ; CHECK-SD-NEXT: ushll2 v3.2d, v2.4s, #0
699 ; CHECK-SD-NEXT: ushll2 v1.2d, v1.4s, #0
700 ; CHECK-SD-NEXT: ushll v2.2d, v2.2s, #0
703 ; CHECK-GI-LABEL: zext_v8i8_v8i64:
704 ; CHECK-GI: // %bb.0: // %entry
705 ; CHECK-GI-NEXT: ushll v0.8h, v0.8b, #0
706 ; CHECK-GI-NEXT: ushll v1.4s, v0.4h, #0
707 ; CHECK-GI-NEXT: ushll2 v3.4s, v0.8h, #0
708 ; CHECK-GI-NEXT: ushll v0.2d, v1.2s, #0
709 ; CHECK-GI-NEXT: ushll2 v1.2d, v1.4s, #0
710 ; CHECK-GI-NEXT: ushll v2.2d, v3.2s, #0
711 ; CHECK-GI-NEXT: ushll2 v3.2d, v3.4s, #0
714 %c = zext <8 x i8> %a to <8 x i64>
718 define <8 x i32> @zext_v8i16_v8i32(<8 x i16> %a) {
719 ; CHECK-SD-LABEL: zext_v8i16_v8i32:
720 ; CHECK-SD: // %bb.0: // %entry
721 ; CHECK-SD-NEXT: ushll2 v1.4s, v0.8h, #0
722 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
725 ; CHECK-GI-LABEL: zext_v8i16_v8i32:
726 ; CHECK-GI: // %bb.0: // %entry
727 ; CHECK-GI-NEXT: ushll v2.4s, v0.4h, #0
728 ; CHECK-GI-NEXT: ushll2 v1.4s, v0.8h, #0
729 ; CHECK-GI-NEXT: mov v0.16b, v2.16b
732 %c = zext <8 x i16> %a to <8 x i32>
736 define <8 x i64> @zext_v8i16_v8i64(<8 x i16> %a) {
737 ; CHECK-SD-LABEL: zext_v8i16_v8i64:
738 ; CHECK-SD: // %bb.0: // %entry
739 ; CHECK-SD-NEXT: ushll v1.4s, v0.4h, #0
740 ; CHECK-SD-NEXT: ushll2 v2.4s, v0.8h, #0
741 ; CHECK-SD-NEXT: ushll v0.2d, v1.2s, #0
742 ; CHECK-SD-NEXT: ushll2 v3.2d, v2.4s, #0
743 ; CHECK-SD-NEXT: ushll2 v1.2d, v1.4s, #0
744 ; CHECK-SD-NEXT: ushll v2.2d, v2.2s, #0
747 ; CHECK-GI-LABEL: zext_v8i16_v8i64:
748 ; CHECK-GI: // %bb.0: // %entry
749 ; CHECK-GI-NEXT: ushll v1.4s, v0.4h, #0
750 ; CHECK-GI-NEXT: ushll2 v3.4s, v0.8h, #0
751 ; CHECK-GI-NEXT: ushll v0.2d, v1.2s, #0
752 ; CHECK-GI-NEXT: ushll2 v1.2d, v1.4s, #0
753 ; CHECK-GI-NEXT: ushll v2.2d, v3.2s, #0
754 ; CHECK-GI-NEXT: ushll2 v3.2d, v3.4s, #0
757 %c = zext <8 x i16> %a to <8 x i64>
761 define <8 x i64> @zext_v8i32_v8i64(<8 x i32> %a) {
762 ; CHECK-SD-LABEL: zext_v8i32_v8i64:
763 ; CHECK-SD: // %bb.0: // %entry
764 ; CHECK-SD-NEXT: ushll v5.2d, v0.2s, #0
765 ; CHECK-SD-NEXT: ushll2 v4.2d, v0.4s, #0
766 ; CHECK-SD-NEXT: ushll2 v3.2d, v1.4s, #0
767 ; CHECK-SD-NEXT: ushll v2.2d, v1.2s, #0
768 ; CHECK-SD-NEXT: mov v0.16b, v5.16b
769 ; CHECK-SD-NEXT: mov v1.16b, v4.16b
772 ; CHECK-GI-LABEL: zext_v8i32_v8i64:
773 ; CHECK-GI: // %bb.0: // %entry
774 ; CHECK-GI-NEXT: ushll v4.2d, v0.2s, #0
775 ; CHECK-GI-NEXT: ushll2 v5.2d, v0.4s, #0
776 ; CHECK-GI-NEXT: ushll v2.2d, v1.2s, #0
777 ; CHECK-GI-NEXT: ushll2 v3.2d, v1.4s, #0
778 ; CHECK-GI-NEXT: mov v0.16b, v4.16b
779 ; CHECK-GI-NEXT: mov v1.16b, v5.16b
782 %c = zext <8 x i32> %a to <8 x i64>
786 define <8 x i16> @zext_v8i10_v8i16(<8 x i10> %a) {
787 ; CHECK-SD-LABEL: zext_v8i10_v8i16:
788 ; CHECK-SD: // %bb.0: // %entry
789 ; CHECK-SD-NEXT: bic v0.8h, #252, lsl #8
792 ; CHECK-GI-LABEL: zext_v8i10_v8i16:
793 ; CHECK-GI: // %bb.0: // %entry
794 ; CHECK-GI-NEXT: mvni v1.8h, #252, lsl #8
795 ; CHECK-GI-NEXT: and v0.16b, v0.16b, v1.16b
798 %c = zext <8 x i10> %a to <8 x i16>
802 define <8 x i32> @zext_v8i10_v8i32(<8 x i10> %a) {
803 ; CHECK-SD-LABEL: zext_v8i10_v8i32:
804 ; CHECK-SD: // %bb.0: // %entry
805 ; CHECK-SD-NEXT: bic v0.8h, #252, lsl #8
806 ; CHECK-SD-NEXT: ushll2 v1.4s, v0.8h, #0
807 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
810 ; CHECK-GI-LABEL: zext_v8i10_v8i32:
811 ; CHECK-GI: // %bb.0: // %entry
812 ; CHECK-GI-NEXT: movi v1.4s, #3, msl #8
813 ; CHECK-GI-NEXT: ushll v2.4s, v0.4h, #0
814 ; CHECK-GI-NEXT: ushll2 v3.4s, v0.8h, #0
815 ; CHECK-GI-NEXT: and v0.16b, v2.16b, v1.16b
816 ; CHECK-GI-NEXT: and v1.16b, v3.16b, v1.16b
819 %c = zext <8 x i10> %a to <8 x i32>
823 define <8 x i64> @zext_v8i10_v8i64(<8 x i10> %a) {
824 ; CHECK-SD-LABEL: zext_v8i10_v8i64:
825 ; CHECK-SD: // %bb.0: // %entry
826 ; CHECK-SD-NEXT: bic v0.8h, #252, lsl #8
827 ; CHECK-SD-NEXT: ushll v1.4s, v0.4h, #0
828 ; CHECK-SD-NEXT: ushll2 v2.4s, v0.8h, #0
829 ; CHECK-SD-NEXT: ushll v0.2d, v1.2s, #0
830 ; CHECK-SD-NEXT: ushll2 v3.2d, v2.4s, #0
831 ; CHECK-SD-NEXT: ushll2 v1.2d, v1.4s, #0
832 ; CHECK-SD-NEXT: ushll v2.2d, v2.2s, #0
835 ; CHECK-GI-LABEL: zext_v8i10_v8i64:
836 ; CHECK-GI: // %bb.0: // %entry
837 ; CHECK-GI-NEXT: ushll v1.4s, v0.4h, #0
838 ; CHECK-GI-NEXT: ushll2 v0.4s, v0.8h, #0
839 ; CHECK-GI-NEXT: adrp x8, .LCPI45_0
840 ; CHECK-GI-NEXT: ldr q3, [x8, :lo12:.LCPI45_0]
841 ; CHECK-GI-NEXT: ushll v2.2d, v1.2s, #0
842 ; CHECK-GI-NEXT: ushll2 v1.2d, v1.4s, #0
843 ; CHECK-GI-NEXT: ushll v4.2d, v0.2s, #0
844 ; CHECK-GI-NEXT: ushll2 v5.2d, v0.4s, #0
845 ; CHECK-GI-NEXT: and v0.16b, v2.16b, v3.16b
846 ; CHECK-GI-NEXT: and v1.16b, v1.16b, v3.16b
847 ; CHECK-GI-NEXT: and v2.16b, v4.16b, v3.16b
848 ; CHECK-GI-NEXT: and v3.16b, v5.16b, v3.16b
851 %c = zext <8 x i10> %a to <8 x i64>
855 define <16 x i16> @zext_v16i8_v16i16(<16 x i8> %a) {
856 ; CHECK-SD-LABEL: zext_v16i8_v16i16:
857 ; CHECK-SD: // %bb.0: // %entry
858 ; CHECK-SD-NEXT: ushll2 v1.8h, v0.16b, #0
859 ; CHECK-SD-NEXT: ushll v0.8h, v0.8b, #0
862 ; CHECK-GI-LABEL: zext_v16i8_v16i16:
863 ; CHECK-GI: // %bb.0: // %entry
864 ; CHECK-GI-NEXT: ushll v2.8h, v0.8b, #0
865 ; CHECK-GI-NEXT: ushll2 v1.8h, v0.16b, #0
866 ; CHECK-GI-NEXT: mov v0.16b, v2.16b
869 %c = zext <16 x i8> %a to <16 x i16>
873 define <16 x i32> @zext_v16i8_v16i32(<16 x i8> %a) {
874 ; CHECK-SD-LABEL: zext_v16i8_v16i32:
875 ; CHECK-SD: // %bb.0: // %entry
876 ; CHECK-SD-NEXT: ushll v1.8h, v0.8b, #0
877 ; CHECK-SD-NEXT: ushll2 v2.8h, v0.16b, #0
878 ; CHECK-SD-NEXT: ushll v0.4s, v1.4h, #0
879 ; CHECK-SD-NEXT: ushll2 v3.4s, v2.8h, #0
880 ; CHECK-SD-NEXT: ushll2 v1.4s, v1.8h, #0
881 ; CHECK-SD-NEXT: ushll v2.4s, v2.4h, #0
884 ; CHECK-GI-LABEL: zext_v16i8_v16i32:
885 ; CHECK-GI: // %bb.0: // %entry
886 ; CHECK-GI-NEXT: ushll v1.8h, v0.8b, #0
887 ; CHECK-GI-NEXT: ushll2 v3.8h, v0.16b, #0
888 ; CHECK-GI-NEXT: ushll v0.4s, v1.4h, #0
889 ; CHECK-GI-NEXT: ushll2 v1.4s, v1.8h, #0
890 ; CHECK-GI-NEXT: ushll v2.4s, v3.4h, #0
891 ; CHECK-GI-NEXT: ushll2 v3.4s, v3.8h, #0
894 %c = zext <16 x i8> %a to <16 x i32>
898 define <16 x i64> @zext_v16i8_v16i64(<16 x i8> %a) {
899 ; CHECK-SD-LABEL: zext_v16i8_v16i64:
900 ; CHECK-SD: // %bb.0: // %entry
901 ; CHECK-SD-NEXT: ushll v1.8h, v0.8b, #0
902 ; CHECK-SD-NEXT: ushll2 v0.8h, v0.16b, #0
903 ; CHECK-SD-NEXT: ushll v2.4s, v1.4h, #0
904 ; CHECK-SD-NEXT: ushll2 v4.4s, v1.8h, #0
905 ; CHECK-SD-NEXT: ushll v5.4s, v0.4h, #0
906 ; CHECK-SD-NEXT: ushll2 v6.4s, v0.8h, #0
907 ; CHECK-SD-NEXT: ushll2 v1.2d, v2.4s, #0
908 ; CHECK-SD-NEXT: ushll v0.2d, v2.2s, #0
909 ; CHECK-SD-NEXT: ushll2 v3.2d, v4.4s, #0
910 ; CHECK-SD-NEXT: ushll v2.2d, v4.2s, #0
911 ; CHECK-SD-NEXT: ushll v4.2d, v5.2s, #0
912 ; CHECK-SD-NEXT: ushll2 v7.2d, v6.4s, #0
913 ; CHECK-SD-NEXT: ushll2 v5.2d, v5.4s, #0
914 ; CHECK-SD-NEXT: ushll v6.2d, v6.2s, #0
917 ; CHECK-GI-LABEL: zext_v16i8_v16i64:
918 ; CHECK-GI: // %bb.0: // %entry
919 ; CHECK-GI-NEXT: ushll v1.8h, v0.8b, #0
920 ; CHECK-GI-NEXT: ushll2 v0.8h, v0.16b, #0
921 ; CHECK-GI-NEXT: ushll v2.4s, v1.4h, #0
922 ; CHECK-GI-NEXT: ushll2 v3.4s, v1.8h, #0
923 ; CHECK-GI-NEXT: ushll v5.4s, v0.4h, #0
924 ; CHECK-GI-NEXT: ushll2 v7.4s, v0.8h, #0
925 ; CHECK-GI-NEXT: ushll v0.2d, v2.2s, #0
926 ; CHECK-GI-NEXT: ushll2 v1.2d, v2.4s, #0
927 ; CHECK-GI-NEXT: ushll v2.2d, v3.2s, #0
928 ; CHECK-GI-NEXT: ushll2 v3.2d, v3.4s, #0
929 ; CHECK-GI-NEXT: ushll v4.2d, v5.2s, #0
930 ; CHECK-GI-NEXT: ushll2 v5.2d, v5.4s, #0
931 ; CHECK-GI-NEXT: ushll v6.2d, v7.2s, #0
932 ; CHECK-GI-NEXT: ushll2 v7.2d, v7.4s, #0
935 %c = zext <16 x i8> %a to <16 x i64>
939 define <16 x i32> @zext_v16i16_v16i32(<16 x i16> %a) {
940 ; CHECK-SD-LABEL: zext_v16i16_v16i32:
941 ; CHECK-SD: // %bb.0: // %entry
942 ; CHECK-SD-NEXT: ushll v5.4s, v0.4h, #0
943 ; CHECK-SD-NEXT: ushll2 v4.4s, v0.8h, #0
944 ; CHECK-SD-NEXT: ushll2 v3.4s, v1.8h, #0
945 ; CHECK-SD-NEXT: ushll v2.4s, v1.4h, #0
946 ; CHECK-SD-NEXT: mov v0.16b, v5.16b
947 ; CHECK-SD-NEXT: mov v1.16b, v4.16b
950 ; CHECK-GI-LABEL: zext_v16i16_v16i32:
951 ; CHECK-GI: // %bb.0: // %entry
952 ; CHECK-GI-NEXT: ushll v4.4s, v0.4h, #0
953 ; CHECK-GI-NEXT: ushll2 v5.4s, v0.8h, #0
954 ; CHECK-GI-NEXT: ushll v2.4s, v1.4h, #0
955 ; CHECK-GI-NEXT: ushll2 v3.4s, v1.8h, #0
956 ; CHECK-GI-NEXT: mov v0.16b, v4.16b
957 ; CHECK-GI-NEXT: mov v1.16b, v5.16b
960 %c = zext <16 x i16> %a to <16 x i32>
964 define <16 x i64> @zext_v16i16_v16i64(<16 x i16> %a) {
965 ; CHECK-SD-LABEL: zext_v16i16_v16i64:
966 ; CHECK-SD: // %bb.0: // %entry
967 ; CHECK-SD-NEXT: ushll v2.4s, v0.4h, #0
968 ; CHECK-SD-NEXT: ushll2 v4.4s, v0.8h, #0
969 ; CHECK-SD-NEXT: ushll v5.4s, v1.4h, #0
970 ; CHECK-SD-NEXT: ushll2 v6.4s, v1.8h, #0
971 ; CHECK-SD-NEXT: ushll2 v1.2d, v2.4s, #0
972 ; CHECK-SD-NEXT: ushll v0.2d, v2.2s, #0
973 ; CHECK-SD-NEXT: ushll2 v3.2d, v4.4s, #0
974 ; CHECK-SD-NEXT: ushll v2.2d, v4.2s, #0
975 ; CHECK-SD-NEXT: ushll v4.2d, v5.2s, #0
976 ; CHECK-SD-NEXT: ushll2 v7.2d, v6.4s, #0
977 ; CHECK-SD-NEXT: ushll2 v5.2d, v5.4s, #0
978 ; CHECK-SD-NEXT: ushll v6.2d, v6.2s, #0
981 ; CHECK-GI-LABEL: zext_v16i16_v16i64:
982 ; CHECK-GI: // %bb.0: // %entry
983 ; CHECK-GI-NEXT: ushll v2.4s, v0.4h, #0
984 ; CHECK-GI-NEXT: ushll2 v3.4s, v0.8h, #0
985 ; CHECK-GI-NEXT: ushll v5.4s, v1.4h, #0
986 ; CHECK-GI-NEXT: ushll2 v7.4s, v1.8h, #0
987 ; CHECK-GI-NEXT: ushll v0.2d, v2.2s, #0
988 ; CHECK-GI-NEXT: ushll2 v1.2d, v2.4s, #0
989 ; CHECK-GI-NEXT: ushll v2.2d, v3.2s, #0
990 ; CHECK-GI-NEXT: ushll2 v3.2d, v3.4s, #0
991 ; CHECK-GI-NEXT: ushll v4.2d, v5.2s, #0
992 ; CHECK-GI-NEXT: ushll2 v5.2d, v5.4s, #0
993 ; CHECK-GI-NEXT: ushll v6.2d, v7.2s, #0
994 ; CHECK-GI-NEXT: ushll2 v7.2d, v7.4s, #0
997 %c = zext <16 x i16> %a to <16 x i64>
1001 define <16 x i64> @zext_v16i32_v16i64(<16 x i32> %a) {
1002 ; CHECK-SD-LABEL: zext_v16i32_v16i64:
1003 ; CHECK-SD: // %bb.0: // %entry
1004 ; CHECK-SD-NEXT: ushll2 v17.2d, v0.4s, #0
1005 ; CHECK-SD-NEXT: ushll2 v16.2d, v1.4s, #0
1006 ; CHECK-SD-NEXT: ushll v18.2d, v1.2s, #0
1007 ; CHECK-SD-NEXT: ushll v0.2d, v0.2s, #0
1008 ; CHECK-SD-NEXT: ushll v4.2d, v2.2s, #0
1009 ; CHECK-SD-NEXT: ushll2 v5.2d, v2.4s, #0
1010 ; CHECK-SD-NEXT: ushll2 v7.2d, v3.4s, #0
1011 ; CHECK-SD-NEXT: ushll v6.2d, v3.2s, #0
1012 ; CHECK-SD-NEXT: mov v1.16b, v17.16b
1013 ; CHECK-SD-NEXT: mov v2.16b, v18.16b
1014 ; CHECK-SD-NEXT: mov v3.16b, v16.16b
1015 ; CHECK-SD-NEXT: ret
1017 ; CHECK-GI-LABEL: zext_v16i32_v16i64:
1018 ; CHECK-GI: // %bb.0: // %entry
1019 ; CHECK-GI-NEXT: ushll v16.2d, v0.2s, #0
1020 ; CHECK-GI-NEXT: ushll2 v17.2d, v0.4s, #0
1021 ; CHECK-GI-NEXT: ushll v18.2d, v1.2s, #0
1022 ; CHECK-GI-NEXT: ushll2 v19.2d, v1.4s, #0
1023 ; CHECK-GI-NEXT: ushll v4.2d, v2.2s, #0
1024 ; CHECK-GI-NEXT: ushll2 v5.2d, v2.4s, #0
1025 ; CHECK-GI-NEXT: ushll v6.2d, v3.2s, #0
1026 ; CHECK-GI-NEXT: ushll2 v7.2d, v3.4s, #0
1027 ; CHECK-GI-NEXT: mov v0.16b, v16.16b
1028 ; CHECK-GI-NEXT: mov v1.16b, v17.16b
1029 ; CHECK-GI-NEXT: mov v2.16b, v18.16b
1030 ; CHECK-GI-NEXT: mov v3.16b, v19.16b
1031 ; CHECK-GI-NEXT: ret
1033 %c = zext <16 x i32> %a to <16 x i64>
1037 define <16 x i16> @zext_v16i10_v16i16(<16 x i10> %a) {
1038 ; CHECK-LABEL: zext_v16i10_v16i16:
1039 ; CHECK: // %bb.0: // %entry
1040 ; CHECK-NEXT: ldr w8, [sp]
1041 ; CHECK-NEXT: fmov s0, w0
1042 ; CHECK-NEXT: ldr w9, [sp, #8]
1043 ; CHECK-NEXT: fmov s1, w8
1044 ; CHECK-NEXT: ldr w8, [sp, #16]
1045 ; CHECK-NEXT: mov v0.h[1], w1
1046 ; CHECK-NEXT: mov v1.h[1], w9
1047 ; CHECK-NEXT: mov v0.h[2], w2
1048 ; CHECK-NEXT: mov v1.h[2], w8
1049 ; CHECK-NEXT: ldr w8, [sp, #24]
1050 ; CHECK-NEXT: mov v0.h[3], w3
1051 ; CHECK-NEXT: mov v1.h[3], w8
1052 ; CHECK-NEXT: ldr w8, [sp, #32]
1053 ; CHECK-NEXT: mov v0.h[4], w4
1054 ; CHECK-NEXT: mov v1.h[4], w8
1055 ; CHECK-NEXT: ldr w8, [sp, #40]
1056 ; CHECK-NEXT: mov v0.h[5], w5
1057 ; CHECK-NEXT: mov v1.h[5], w8
1058 ; CHECK-NEXT: ldr w8, [sp, #48]
1059 ; CHECK-NEXT: mov v0.h[6], w6
1060 ; CHECK-NEXT: mov v1.h[6], w8
1061 ; CHECK-NEXT: ldr w8, [sp, #56]
1062 ; CHECK-NEXT: mov v0.h[7], w7
1063 ; CHECK-NEXT: mov v1.h[7], w8
1064 ; CHECK-NEXT: bic v0.8h, #252, lsl #8
1065 ; CHECK-NEXT: bic v1.8h, #252, lsl #8
1068 %c = zext <16 x i10> %a to <16 x i16>
1072 define <16 x i32> @zext_v16i10_v16i32(<16 x i10> %a) {
1073 ; CHECK-SD-LABEL: zext_v16i10_v16i32:
1074 ; CHECK-SD: // %bb.0: // %entry
1075 ; CHECK-SD-NEXT: ldr w8, [sp, #32]
1076 ; CHECK-SD-NEXT: ldr w9, [sp]
1077 ; CHECK-SD-NEXT: fmov s0, w0
1078 ; CHECK-SD-NEXT: fmov s1, w4
1079 ; CHECK-SD-NEXT: ldr w10, [sp, #40]
1080 ; CHECK-SD-NEXT: ldr w11, [sp, #8]
1081 ; CHECK-SD-NEXT: fmov s2, w9
1082 ; CHECK-SD-NEXT: fmov s3, w8
1083 ; CHECK-SD-NEXT: ldr w8, [sp, #48]
1084 ; CHECK-SD-NEXT: mov v0.h[1], w1
1085 ; CHECK-SD-NEXT: ldr w9, [sp, #16]
1086 ; CHECK-SD-NEXT: movi v4.4s, #3, msl #8
1087 ; CHECK-SD-NEXT: mov v1.h[1], w5
1088 ; CHECK-SD-NEXT: mov v2.h[1], w11
1089 ; CHECK-SD-NEXT: mov v3.h[1], w10
1090 ; CHECK-SD-NEXT: mov v0.h[2], w2
1091 ; CHECK-SD-NEXT: mov v1.h[2], w6
1092 ; CHECK-SD-NEXT: mov v2.h[2], w9
1093 ; CHECK-SD-NEXT: mov v3.h[2], w8
1094 ; CHECK-SD-NEXT: ldr w8, [sp, #56]
1095 ; CHECK-SD-NEXT: ldr w9, [sp, #24]
1096 ; CHECK-SD-NEXT: mov v0.h[3], w3
1097 ; CHECK-SD-NEXT: mov v1.h[3], w7
1098 ; CHECK-SD-NEXT: mov v2.h[3], w9
1099 ; CHECK-SD-NEXT: mov v3.h[3], w8
1100 ; CHECK-SD-NEXT: ushll v0.4s, v0.4h, #0
1101 ; CHECK-SD-NEXT: ushll v1.4s, v1.4h, #0
1102 ; CHECK-SD-NEXT: ushll v2.4s, v2.4h, #0
1103 ; CHECK-SD-NEXT: ushll v3.4s, v3.4h, #0
1104 ; CHECK-SD-NEXT: and v0.16b, v0.16b, v4.16b
1105 ; CHECK-SD-NEXT: and v1.16b, v1.16b, v4.16b
1106 ; CHECK-SD-NEXT: and v2.16b, v2.16b, v4.16b
1107 ; CHECK-SD-NEXT: and v3.16b, v3.16b, v4.16b
1108 ; CHECK-SD-NEXT: ret
1110 ; CHECK-GI-LABEL: zext_v16i10_v16i32:
1111 ; CHECK-GI: // %bb.0: // %entry
1112 ; CHECK-GI-NEXT: fmov s4, w0
1113 ; CHECK-GI-NEXT: fmov s5, w4
1114 ; CHECK-GI-NEXT: ldr s2, [sp]
1115 ; CHECK-GI-NEXT: ldr s0, [sp, #8]
1116 ; CHECK-GI-NEXT: ldr s3, [sp, #32]
1117 ; CHECK-GI-NEXT: ldr s1, [sp, #40]
1118 ; CHECK-GI-NEXT: movi v6.4s, #3, msl #8
1119 ; CHECK-GI-NEXT: mov v4.s[1], w1
1120 ; CHECK-GI-NEXT: mov v5.s[1], w5
1121 ; CHECK-GI-NEXT: mov v2.s[1], v0.s[0]
1122 ; CHECK-GI-NEXT: mov v3.s[1], v1.s[0]
1123 ; CHECK-GI-NEXT: ldr s0, [sp, #16]
1124 ; CHECK-GI-NEXT: ldr s1, [sp, #48]
1125 ; CHECK-GI-NEXT: mov v4.s[2], w2
1126 ; CHECK-GI-NEXT: mov v5.s[2], w6
1127 ; CHECK-GI-NEXT: mov v2.s[2], v0.s[0]
1128 ; CHECK-GI-NEXT: mov v3.s[2], v1.s[0]
1129 ; CHECK-GI-NEXT: ldr s0, [sp, #24]
1130 ; CHECK-GI-NEXT: ldr s1, [sp, #56]
1131 ; CHECK-GI-NEXT: mov v4.s[3], w3
1132 ; CHECK-GI-NEXT: mov v5.s[3], w7
1133 ; CHECK-GI-NEXT: mov v2.s[3], v0.s[0]
1134 ; CHECK-GI-NEXT: mov v3.s[3], v1.s[0]
1135 ; CHECK-GI-NEXT: and v0.16b, v4.16b, v6.16b
1136 ; CHECK-GI-NEXT: and v1.16b, v5.16b, v6.16b
1137 ; CHECK-GI-NEXT: and v2.16b, v2.16b, v6.16b
1138 ; CHECK-GI-NEXT: and v3.16b, v3.16b, v6.16b
1139 ; CHECK-GI-NEXT: ret
1141 %c = zext <16 x i10> %a to <16 x i32>
1145 define <16 x i64> @zext_v16i10_v16i64(<16 x i10> %a) {
1146 ; CHECK-SD-LABEL: zext_v16i10_v16i64:
1147 ; CHECK-SD: // %bb.0: // %entry
1148 ; CHECK-SD-NEXT: fmov s0, w2
1149 ; CHECK-SD-NEXT: fmov s1, w0
1150 ; CHECK-SD-NEXT: ldr s2, [sp]
1151 ; CHECK-SD-NEXT: fmov s3, w4
1152 ; CHECK-SD-NEXT: fmov s4, w6
1153 ; CHECK-SD-NEXT: add x9, sp, #8
1154 ; CHECK-SD-NEXT: ldr s5, [sp, #16]
1155 ; CHECK-SD-NEXT: ldr s6, [sp, #32]
1156 ; CHECK-SD-NEXT: ldr s7, [sp, #48]
1157 ; CHECK-SD-NEXT: mov v1.s[1], w1
1158 ; CHECK-SD-NEXT: mov v0.s[1], w3
1159 ; CHECK-SD-NEXT: ld1 { v2.s }[1], [x9]
1160 ; CHECK-SD-NEXT: mov v3.s[1], w5
1161 ; CHECK-SD-NEXT: mov v4.s[1], w7
1162 ; CHECK-SD-NEXT: add x9, sp, #24
1163 ; CHECK-SD-NEXT: add x10, sp, #40
1164 ; CHECK-SD-NEXT: add x11, sp, #56
1165 ; CHECK-SD-NEXT: ld1 { v5.s }[1], [x9]
1166 ; CHECK-SD-NEXT: ld1 { v6.s }[1], [x10]
1167 ; CHECK-SD-NEXT: ld1 { v7.s }[1], [x11]
1168 ; CHECK-SD-NEXT: mov w8, #1023 // =0x3ff
1169 ; CHECK-SD-NEXT: ushll v1.2d, v1.2s, #0
1170 ; CHECK-SD-NEXT: dup v16.2d, x8
1171 ; CHECK-SD-NEXT: ushll v17.2d, v0.2s, #0
1172 ; CHECK-SD-NEXT: ushll v3.2d, v3.2s, #0
1173 ; CHECK-SD-NEXT: ushll v4.2d, v4.2s, #0
1174 ; CHECK-SD-NEXT: ushll v18.2d, v2.2s, #0
1175 ; CHECK-SD-NEXT: ushll v5.2d, v5.2s, #0
1176 ; CHECK-SD-NEXT: ushll v6.2d, v6.2s, #0
1177 ; CHECK-SD-NEXT: ushll v7.2d, v7.2s, #0
1178 ; CHECK-SD-NEXT: and v0.16b, v1.16b, v16.16b
1179 ; CHECK-SD-NEXT: and v1.16b, v17.16b, v16.16b
1180 ; CHECK-SD-NEXT: and v2.16b, v3.16b, v16.16b
1181 ; CHECK-SD-NEXT: and v3.16b, v4.16b, v16.16b
1182 ; CHECK-SD-NEXT: and v4.16b, v18.16b, v16.16b
1183 ; CHECK-SD-NEXT: and v5.16b, v5.16b, v16.16b
1184 ; CHECK-SD-NEXT: and v6.16b, v6.16b, v16.16b
1185 ; CHECK-SD-NEXT: and v7.16b, v7.16b, v16.16b
1186 ; CHECK-SD-NEXT: ret
1188 ; CHECK-GI-LABEL: zext_v16i10_v16i64:
1189 ; CHECK-GI: // %bb.0: // %entry
1190 ; CHECK-GI-NEXT: fmov s16, w0
1191 ; CHECK-GI-NEXT: fmov s17, w2
1192 ; CHECK-GI-NEXT: ldr s0, [sp]
1193 ; CHECK-GI-NEXT: fmov s18, w4
1194 ; CHECK-GI-NEXT: fmov s19, w6
1195 ; CHECK-GI-NEXT: ldr s1, [sp, #8]
1196 ; CHECK-GI-NEXT: ldr s2, [sp, #16]
1197 ; CHECK-GI-NEXT: ldr s3, [sp, #24]
1198 ; CHECK-GI-NEXT: ldr s4, [sp, #32]
1199 ; CHECK-GI-NEXT: ldr s5, [sp, #40]
1200 ; CHECK-GI-NEXT: ldr s6, [sp, #48]
1201 ; CHECK-GI-NEXT: ldr s7, [sp, #56]
1202 ; CHECK-GI-NEXT: mov v16.s[1], w1
1203 ; CHECK-GI-NEXT: mov v17.s[1], w3
1204 ; CHECK-GI-NEXT: mov v18.s[1], w5
1205 ; CHECK-GI-NEXT: mov v19.s[1], w7
1206 ; CHECK-GI-NEXT: mov v0.s[1], v1.s[0]
1207 ; CHECK-GI-NEXT: mov v2.s[1], v3.s[0]
1208 ; CHECK-GI-NEXT: mov v4.s[1], v5.s[0]
1209 ; CHECK-GI-NEXT: mov v6.s[1], v7.s[0]
1210 ; CHECK-GI-NEXT: adrp x8, .LCPI54_0
1211 ; CHECK-GI-NEXT: ushll v1.2d, v16.2s, #0
1212 ; CHECK-GI-NEXT: ushll v3.2d, v17.2s, #0
1213 ; CHECK-GI-NEXT: ushll v5.2d, v18.2s, #0
1214 ; CHECK-GI-NEXT: ushll v7.2d, v19.2s, #0
1215 ; CHECK-GI-NEXT: ushll v16.2d, v0.2s, #0
1216 ; CHECK-GI-NEXT: ushll v18.2d, v2.2s, #0
1217 ; CHECK-GI-NEXT: ushll v19.2d, v4.2s, #0
1218 ; CHECK-GI-NEXT: ushll v20.2d, v6.2s, #0
1219 ; CHECK-GI-NEXT: ldr q17, [x8, :lo12:.LCPI54_0]
1220 ; CHECK-GI-NEXT: and v0.16b, v1.16b, v17.16b
1221 ; CHECK-GI-NEXT: and v1.16b, v3.16b, v17.16b
1222 ; CHECK-GI-NEXT: and v2.16b, v5.16b, v17.16b
1223 ; CHECK-GI-NEXT: and v3.16b, v7.16b, v17.16b
1224 ; CHECK-GI-NEXT: and v4.16b, v16.16b, v17.16b
1225 ; CHECK-GI-NEXT: and v5.16b, v18.16b, v17.16b
1226 ; CHECK-GI-NEXT: and v6.16b, v19.16b, v17.16b
1227 ; CHECK-GI-NEXT: and v7.16b, v20.16b, v17.16b
1228 ; CHECK-GI-NEXT: ret
1230 %c = zext <16 x i10> %a to <16 x i64>