llvm.org GIT mirror llvm / 424a198
[x86] Mechanically update a bunch of tests' check lines using the latest version of the script. Changes include: - Using the VEX prefix - Skipping more detail when we have useful shuffle comments to match - Matching more shuffle comments that have been added to the printer (yay!) - Matching the destination registers of some AVX instructions - Stripping trailing whitespace that crept in - Fixing indentation issues Nothing interesting going on here. I'm just trying really hard to ensure these changes don't show up in the diffs with actual changes to the backend. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@228132 91177308-0d34-0410-b5e6-96231b3b80d8 Chandler Carruth 5 years ago
10 changed file(s) with 234 addition(s) and 247 deletion(s). Raw diff Collapse all Expand all
3737 define <4 x float> @vsel_float2(<4 x float> %v1, <4 x float> %v2) {
3838 ; SSE2-LABEL: vsel_float2:
3939 ; SSE2: # BB#0: # %entry
40 ; SSE2-NEXT: movss %xmm0, %xmm1
40 ; SSE2-NEXT: movss {{.*#+}} xmm1 = xmm0[0],xmm1[1,2,3]
4141 ; SSE2-NEXT: movaps %xmm1, %xmm0
4242 ; SSE2-NEXT: retq
4343 ;
4444 ; SSSE3-LABEL: vsel_float2:
4545 ; SSSE3: # BB#0: # %entry
46 ; SSSE3-NEXT: movss %xmm0, %xmm1
46 ; SSSE3-NEXT: movss {{.*#+}} xmm1 = xmm0[0],xmm1[1,2,3]
4747 ; SSSE3-NEXT: movaps %xmm1, %xmm0
4848 ; SSSE3-NEXT: retq
4949 ;
5454 ;
5555 ; AVX-LABEL: vsel_float2:
5656 ; AVX: # BB#0: # %entry
57 ; AVX-NEXT: blendps {{.*#+}} xmm0 = xmm0[0],xmm1[1,2,3]
57 ; AVX-NEXT: vblendps {{.*#+}} xmm0 = xmm0[0],xmm1[1,2,3]
5858 ; AVX-NEXT: retq
5959 entry:
6060 %vsel = select <4 x i1> , <4 x float> %v1, <4 x float> %v2
166166 define <2 x double> @vsel_double(<2 x double> %v1, <2 x double> %v2) {
167167 ; SSE2-LABEL: vsel_double:
168168 ; SSE2: # BB#0: # %entry
169 ; SSE2-NEXT: movsd %xmm0, %xmm1
169 ; SSE2-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
170170 ; SSE2-NEXT: movaps %xmm1, %xmm0
171171 ; SSE2-NEXT: retq
172172 ;
173173 ; SSSE3-LABEL: vsel_double:
174174 ; SSSE3: # BB#0: # %entry
175 ; SSSE3-NEXT: movsd %xmm0, %xmm1
175 ; SSSE3-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
176176 ; SSSE3-NEXT: movaps %xmm1, %xmm0
177177 ; SSSE3-NEXT: retq
178178 ;
193193 define <2 x i64> @vsel_i64(<2 x i64> %v1, <2 x i64> %v2) {
194194 ; SSE2-LABEL: vsel_i64:
195195 ; SSE2: # BB#0: # %entry
196 ; SSE2-NEXT: movsd %xmm0, %xmm1
196 ; SSE2-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
197197 ; SSE2-NEXT: movaps %xmm1, %xmm0
198198 ; SSE2-NEXT: retq
199199 ;
200200 ; SSSE3-LABEL: vsel_i64:
201201 ; SSSE3: # BB#0: # %entry
202 ; SSSE3-NEXT: movsd %xmm0, %xmm1
202 ; SSSE3-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
203203 ; SSSE3-NEXT: movaps %xmm1, %xmm0
204204 ; SSSE3-NEXT: retq
205205 ;
290290 define <8 x float> @vsel_float8(<8 x float> %v1, <8 x float> %v2) {
291291 ; SSE2-LABEL: vsel_float8:
292292 ; SSE2: # BB#0: # %entry
293 ; SSE2-NEXT: movss %xmm0, %xmm2
294 ; SSE2-NEXT: movss %xmm1, %xmm3
293 ; SSE2-NEXT: movss {{.*#+}} xmm2 = xmm0[0],xmm2[1,2,3]
294 ; SSE2-NEXT: movss {{.*#+}} xmm3 = xmm1[0],xmm3[1,2,3]
295295 ; SSE2-NEXT: movaps %xmm2, %xmm0
296296 ; SSE2-NEXT: movaps %xmm3, %xmm1
297297 ; SSE2-NEXT: retq
298298 ;
299299 ; SSSE3-LABEL: vsel_float8:
300300 ; SSSE3: # BB#0: # %entry
301 ; SSSE3-NEXT: movss %xmm0, %xmm2
302 ; SSSE3-NEXT: movss %xmm1, %xmm3
301 ; SSSE3-NEXT: movss {{.*#+}} xmm2 = xmm0[0],xmm2[1,2,3]
302 ; SSSE3-NEXT: movss {{.*#+}} xmm3 = xmm1[0],xmm3[1,2,3]
303303 ; SSSE3-NEXT: movaps %xmm2, %xmm0
304304 ; SSSE3-NEXT: movaps %xmm3, %xmm1
305305 ; SSSE3-NEXT: retq
322322 define <8 x i32> @vsel_i328(<8 x i32> %v1, <8 x i32> %v2) {
323323 ; SSE2-LABEL: vsel_i328:
324324 ; SSE2: # BB#0: # %entry
325 ; SSE2-NEXT: movss %xmm0, %xmm2
326 ; SSE2-NEXT: movss %xmm1, %xmm3
325 ; SSE2-NEXT: movss {{.*#+}} xmm2 = xmm0[0],xmm2[1,2,3]
326 ; SSE2-NEXT: movss {{.*#+}} xmm3 = xmm1[0],xmm3[1,2,3]
327327 ; SSE2-NEXT: movaps %xmm2, %xmm0
328328 ; SSE2-NEXT: movaps %xmm3, %xmm1
329329 ; SSE2-NEXT: retq
330330 ;
331331 ; SSSE3-LABEL: vsel_i328:
332332 ; SSSE3: # BB#0: # %entry
333 ; SSSE3-NEXT: movss %xmm0, %xmm2
334 ; SSSE3-NEXT: movss %xmm1, %xmm3
333 ; SSSE3-NEXT: movss {{.*#+}} xmm2 = xmm0[0],xmm2[1,2,3]
334 ; SSSE3-NEXT: movss {{.*#+}} xmm3 = xmm1[0],xmm3[1,2,3]
335335 ; SSSE3-NEXT: movaps %xmm2, %xmm0
336336 ; SSSE3-NEXT: movaps %xmm3, %xmm1
337337 ; SSSE3-NEXT: retq
359359 define <8 x double> @vsel_double8(<8 x double> %v1, <8 x double> %v2) {
360360 ; SSE2-LABEL: vsel_double8:
361361 ; SSE2: # BB#0: # %entry
362 ; SSE2-NEXT: movsd %xmm0, %xmm4
363 ; SSE2-NEXT: movsd %xmm2, %xmm6
362 ; SSE2-NEXT: movsd {{.*#+}} xmm4 = xmm0[0],xmm4[1]
363 ; SSE2-NEXT: movsd {{.*#+}} xmm6 = xmm2[0],xmm6[1]
364364 ; SSE2-NEXT: movaps %xmm4, %xmm0
365365 ; SSE2-NEXT: movaps %xmm5, %xmm1
366366 ; SSE2-NEXT: movaps %xmm6, %xmm2
369369 ;
370370 ; SSSE3-LABEL: vsel_double8:
371371 ; SSSE3: # BB#0: # %entry
372 ; SSSE3-NEXT: movsd %xmm0, %xmm4
373 ; SSSE3-NEXT: movsd %xmm2, %xmm6
372 ; SSSE3-NEXT: movsd {{.*#+}} xmm4 = xmm0[0],xmm4[1]
373 ; SSSE3-NEXT: movsd {{.*#+}} xmm6 = xmm2[0],xmm6[1]
374374 ; SSSE3-NEXT: movaps %xmm4, %xmm0
375375 ; SSSE3-NEXT: movaps %xmm5, %xmm1
376376 ; SSSE3-NEXT: movaps %xmm6, %xmm2
398398 define <8 x i64> @vsel_i648(<8 x i64> %v1, <8 x i64> %v2) {
399399 ; SSE2-LABEL: vsel_i648:
400400 ; SSE2: # BB#0: # %entry
401 ; SSE2-NEXT: movsd %xmm0, %xmm4
402 ; SSE2-NEXT: movsd %xmm2, %xmm6
401 ; SSE2-NEXT: movsd {{.*#+}} xmm4 = xmm0[0],xmm4[1]
402 ; SSE2-NEXT: movsd {{.*#+}} xmm6 = xmm2[0],xmm6[1]
403403 ; SSE2-NEXT: movaps %xmm4, %xmm0
404404 ; SSE2-NEXT: movaps %xmm5, %xmm1
405405 ; SSE2-NEXT: movaps %xmm6, %xmm2
408408 ;
409409 ; SSSE3-LABEL: vsel_i648:
410410 ; SSSE3: # BB#0: # %entry
411 ; SSSE3-NEXT: movsd %xmm0, %xmm4
412 ; SSSE3-NEXT: movsd %xmm2, %xmm6
411 ; SSSE3-NEXT: movsd {{.*#+}} xmm4 = xmm0[0],xmm4[1]
412 ; SSSE3-NEXT: movsd {{.*#+}} xmm6 = xmm2[0],xmm6[1]
413413 ; SSSE3-NEXT: movaps %xmm4, %xmm0
414414 ; SSSE3-NEXT: movaps %xmm5, %xmm1
415415 ; SSSE3-NEXT: movaps %xmm6, %xmm2
443443 define <4 x double> @vsel_double4(<4 x double> %v1, <4 x double> %v2) {
444444 ; SSE2-LABEL: vsel_double4:
445445 ; SSE2: # BB#0: # %entry
446 ; SSE2-NEXT: movsd %xmm0, %xmm2
447 ; SSE2-NEXT: movsd %xmm1, %xmm3
446 ; SSE2-NEXT: movsd {{.*#+}} xmm2 = xmm0[0],xmm2[1]
447 ; SSE2-NEXT: movsd {{.*#+}} xmm3 = xmm1[0],xmm3[1]
448448 ; SSE2-NEXT: movaps %xmm2, %xmm0
449449 ; SSE2-NEXT: movaps %xmm3, %xmm1
450450 ; SSE2-NEXT: retq
451451 ;
452452 ; SSSE3-LABEL: vsel_double4:
453453 ; SSSE3: # BB#0: # %entry
454 ; SSSE3-NEXT: movsd %xmm0, %xmm2
455 ; SSSE3-NEXT: movsd %xmm1, %xmm3
454 ; SSSE3-NEXT: movsd {{.*#+}} xmm2 = xmm0[0],xmm2[1]
455 ; SSSE3-NEXT: movsd {{.*#+}} xmm3 = xmm1[0],xmm3[1]
456456 ; SSSE3-NEXT: movaps %xmm2, %xmm0
457457 ; SSSE3-NEXT: movaps %xmm3, %xmm1
458458 ; SSSE3-NEXT: retq
555555 define <4 x double> @constant_blendvpd_avx(<4 x double> %xy, <4 x double> %ab) {
556556 ; SSE2-LABEL: constant_blendvpd_avx:
557557 ; SSE2: # BB#0: # %entry
558 ; SSE2-NEXT: movsd %xmm1, %xmm3
558 ; SSE2-NEXT: movsd {{.*#+}} xmm3 = xmm1[0],xmm3[1]
559559 ; SSE2-NEXT: movaps %xmm2, %xmm0
560560 ; SSE2-NEXT: movaps %xmm3, %xmm1
561561 ; SSE2-NEXT: retq
562562 ;
563563 ; SSSE3-LABEL: constant_blendvpd_avx:
564564 ; SSSE3: # BB#0: # %entry
565 ; SSSE3-NEXT: movsd %xmm1, %xmm3
565 ; SSSE3-NEXT: movsd {{.*#+}} xmm3 = xmm1[0],xmm3[1]
566566 ; SSSE3-NEXT: movaps %xmm2, %xmm0
567567 ; SSSE3-NEXT: movaps %xmm3, %xmm1
568568 ; SSSE3-NEXT: retq
708708 define <8 x float> @blend_shufflevector_8xfloat(<8 x float> %a, <8 x float> %b) {
709709 ; SSE2-LABEL: blend_shufflevector_8xfloat:
710710 ; SSE2: # BB#0: # %entry
711 ; SSE2-NEXT: movss %xmm0, %xmm2
711 ; SSE2-NEXT: movss {{.*#+}} xmm2 = xmm0[0],xmm2[1,2,3]
712712 ; SSE2-NEXT: shufps {{.*#+}} xmm1 = xmm1[2,0],xmm3[3,0]
713713 ; SSE2-NEXT: shufps {{.*#+}} xmm3 = xmm3[0,1],xmm1[0,2]
714714 ; SSE2-NEXT: movaps %xmm2, %xmm0
717717 ;
718718 ; SSSE3-LABEL: blend_shufflevector_8xfloat:
719719 ; SSSE3: # BB#0: # %entry
720 ; SSSE3-NEXT: movss %xmm0, %xmm2
720 ; SSSE3-NEXT: movss {{.*#+}} xmm2 = xmm0[0],xmm2[1,2,3]
721721 ; SSSE3-NEXT: shufps {{.*#+}} xmm1 = xmm1[2,0],xmm3[3,0]
722722 ; SSSE3-NEXT: shufps {{.*#+}} xmm3 = xmm3[0,1],xmm1[0,2]
723723 ; SSSE3-NEXT: movaps %xmm2, %xmm0
742742 define <4 x double> @blend_shufflevector_4xdouble(<4 x double> %a, <4 x double> %b) {
743743 ; SSE2-LABEL: blend_shufflevector_4xdouble:
744744 ; SSE2: # BB#0: # %entry
745 ; SSE2-NEXT: movsd %xmm0, %xmm2
745 ; SSE2-NEXT: movsd {{.*#+}} xmm2 = xmm0[0],xmm2[1]
746746 ; SSE2-NEXT: movaps %xmm2, %xmm0
747747 ; SSE2-NEXT: retq
748748 ;
749749 ; SSSE3-LABEL: blend_shufflevector_4xdouble:
750750 ; SSSE3: # BB#0: # %entry
751 ; SSSE3-NEXT: movsd %xmm0, %xmm2
751 ; SSSE3-NEXT: movsd {{.*#+}} xmm2 = xmm0[0],xmm2[1]
752752 ; SSSE3-NEXT: movaps %xmm2, %xmm0
753753 ; SSSE3-NEXT: retq
754754 ;
769769 define <4 x i64> @blend_shufflevector_4xi64(<4 x i64> %a, <4 x i64> %b) {
770770 ; SSE2-LABEL: blend_shufflevector_4xi64:
771771 ; SSE2: # BB#0: # %entry
772 ; SSE2-NEXT: movsd %xmm2, %xmm0
772 ; SSE2-NEXT: movsd {{.*#+}} xmm0 = xmm2[0],xmm0[1]
773773 ; SSE2-NEXT: movaps %xmm3, %xmm1
774774 ; SSE2-NEXT: retq
775775 ;
776776 ; SSSE3-LABEL: blend_shufflevector_4xi64:
777777 ; SSSE3: # BB#0: # %entry
778 ; SSSE3-NEXT: movsd %xmm2, %xmm0
778 ; SSSE3-NEXT: movsd {{.*#+}} xmm0 = xmm2[0],xmm0[1]
779779 ; SSSE3-NEXT: movaps %xmm3, %xmm1
780780 ; SSSE3-NEXT: retq
781781 ;
718718 ; AVX-LABEL: shuffle_v16i8_zz_zz_19_zz_zz_zz_zz_zz_zz_zz_zz_zz_zz_zz_zz_zz:
719719 ; AVX: # BB#0:
720720 ; AVX-NEXT: vmovd %edi, %xmm0
721 ; AVX-NEXT: vpslld $24, %xmm0
721 ; AVX-NEXT: vpslld $24, %xmm0, %xmm0
722722 ; AVX-NEXT: vpshufb {{.*#+}} xmm0 = zero,zero,xmm0[3],zero,zero,zero,zero,zero,zero,zero,zero,zero,zero,zero,zero,zero
723723 ; AVX-NEXT: retq
724724 %a = insertelement <16 x i8> undef, i8 %i, i32 3
11961196 ;
11971197 ; AVX-LABEL: shuffle_v16i8_zz_00_zz_02_zz_04_zz_06_zz_08_zz_10_zz_12_zz_14:
11981198 ; AVX: # BB#0:
1199 ; AVX-NEXT: vpsllw $8, %xmm0
1199 ; AVX-NEXT: vpsllw $8, %xmm0, %xmm0
12001200 ; AVX-NEXT: retq
12011201 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12021202 ret <16 x i8> %shuffle
12101210 ;
12111211 ; AVX-LABEL: shuffle_v16i8_zz_zz_zz_00_zz_zz_zz_04_zz_zz_zz_08_zz_zz_zz_12:
12121212 ; AVX: # BB#0:
1213 ; AVX-NEXT: vpslld $24, %xmm0
1213 ; AVX-NEXT: vpslld $24, %xmm0, %xmm0
12141214 ; AVX-NEXT: retq
12151215 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12161216 ret <16 x i8> %shuffle
12241224 ;
12251225 ; AVX-LABEL: shuffle_v16i8_zz_zz_zz_zz_zz_zz_zz_00_zz_zz_zz_zz_zz_zz_zz_08:
12261226 ; AVX: # BB#0:
1227 ; AVX-NEXT: vpsllq $56, %xmm0
1227 ; AVX-NEXT: vpsllq $56, %xmm0, %xmm0
12281228 ; AVX-NEXT: retq
12291229 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12301230 ret <16 x i8> %shuffle
12381238 ;
12391239 ; AVX-LABEL: shuffle_v16i8_zz_00_uu_02_03_uu_05_06_zz_08_09_uu_11_12_13_14:
12401240 ; AVX: # BB#0:
1241 ; AVX-NEXT: vpsllq $8, %xmm0
1241 ; AVX-NEXT: vpsllq $8, %xmm0, %xmm0
12421242 ; AVX-NEXT: retq
12431243 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12441244 ret <16 x i8> %shuffle
12521252 ;
12531253 ; AVX-LABEL: shuffle_v16i8_01_uu_uu_uu_uu_zz_uu_zz_uu_zz_11_zz_13_zz_15_zz:
12541254 ; AVX: # BB#0:
1255 ; AVX-NEXT: vpsrlw $8, %xmm0
1255 ; AVX-NEXT: vpsrlw $8, %xmm0, %xmm0
12561256 ; AVX-NEXT: retq
12571257 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12581258 ret <16 x i8> %shuffle
12661266 ;
12671267 ; AVX-LABEL: shuffle_v16i8_02_03_zz_zz_06_07_uu_uu_uu_uu_uu_uu_14_15_zz_zz:
12681268 ; AVX: # BB#0:
1269 ; AVX-NEXT: vpsrld $16, %xmm0
1269 ; AVX-NEXT: vpsrld $16, %xmm0, %xmm0
12701270 ; AVX-NEXT: retq
12711271 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12721272 ret <16 x i8> %shuffle
12801280 ;
12811281 ; AVX-LABEL: shuffle_v16i8_07_zz_zz_zz_zz_zz_uu_uu_15_uu_uu_uu_uu_uu_zz_zz:
12821282 ; AVX: # BB#0:
1283 ; AVX-NEXT: vpsrlq $56, %xmm0
1283 ; AVX-NEXT: vpsrlq $56, %xmm0, %xmm0
12841284 ; AVX-NEXT: retq
12851285 %shuffle = shufflevector <16 x i8> %a, <16 x i8> zeroinitializer, <16 x i32>
12861286 ret <16 x i8> %shuffle
10901090 ;
10911091 ; SSE3-LABEL: insert_dup_mem_v2f64:
10921092 ; SSE3: # BB#0:
1093 ; SSE3-NEXT: movddup (%rdi), %xmm0
1093 ; SSE3-NEXT: movddup {{.*#+}} xmm0 = mem[0,0]
10941094 ; SSE3-NEXT: retq
10951095 ;
10961096 ; SSSE3-LABEL: insert_dup_mem_v2f64:
10971097 ; SSSE3: # BB#0:
1098 ; SSSE3-NEXT: movddup (%rdi), %xmm0
1098 ; SSSE3-NEXT: movddup {{.*#+}} xmm0 = mem[0,0]
10991099 ; SSSE3-NEXT: retq
11001100 ;
11011101 ; SSE41-LABEL: insert_dup_mem_v2f64:
11021102 ; SSE41: # BB#0:
1103 ; SSE41-NEXT: movddup (%rdi), %xmm0
1103 ; SSE41-NEXT: movddup {{.*#+}} xmm0 = mem[0,0]
11041104 ; SSE41-NEXT: retq
11051105 ;
11061106 ; AVX-LABEL: insert_dup_mem_v2f64:
11071107 ; AVX: # BB#0:
1108 ; AVX-NEXT: vmovddup (%rdi), %xmm0
1108 ; AVX-NEXT: vmovddup {{.*#+}} xmm0 = mem[0,0]
11091109 ; AVX-NEXT: retq
11101110 %a = load double* %ptr
11111111 %v = insertelement <2 x double> undef, double %a, i32 0
13821382 ;
13831383 ; AVX2-LABEL: shuffle_v16i16_zz_00_zz_02_zz_04_zz_06_zz_08_zz_10_zz_12_zz_14:
13841384 ; AVX2: # BB#0:
1385 ; AVX2-NEXT: vpslld $16, %ymm0
1385 ; AVX2-NEXT: vpslld $16, %ymm0, %ymm0
13861386 ; AVX2-NEXT: retq
13871387 %shuffle = shufflevector <16 x i16> %a, <16 x i16> zeroinitializer, <16 x i32>
13881388 ret <16 x i16> %shuffle
14091409 ;
14101410 ; AVX2-LABEL: shuffle_v16i16_zz_zz_zz_00_zz_zz_zz_04_zz_zz_zz_08_zz_zz_zz_12:
14111411 ; AVX2: # BB#0:
1412 ; AVX2-NEXT: vpsllq $48, %ymm0
1412 ; AVX2-NEXT: vpsllq $48, %ymm0, %ymm0
14131413 ; AVX2-NEXT: retq
14141414 %shuffle = shufflevector <16 x i16> %a, <16 x i16> zeroinitializer, <16 x i32>
14151415 ret <16 x i16> %shuffle
14311431 ;
14321432 ; AVX2-LABEL: shuffle_v16i16_01_zz_03_zz_05_zz_07_zz_09_zz_11_zz_13_zz_15_zz:
14331433 ; AVX2: # BB#0:
1434 ; AVX2-NEXT: vpsrld $16, %ymm0
1434 ; AVX2-NEXT: vpsrld $16, %ymm0, %ymm0
14351435 ; AVX2-NEXT: retq
14361436 %shuffle = shufflevector <16 x i16> %a, <16 x i16> zeroinitializer, <16 x i32>
14371437 ret <16 x i16> %shuffle
14601460 ;
14611461 ; AVX2-LABEL: shuffle_v16i16_02_03_zz_zz_06_07_zz_zz_10_11_zz_zz_14_15_zz_zz:
14621462 ; AVX2: # BB#0:
1463 ; AVX2-NEXT: vpsrlq $32, %ymm0
1463 ; AVX2-NEXT: vpsrlq $32, %ymm0, %ymm0
14641464 ; AVX2-NEXT: retq
14651465 %shuffle = shufflevector <16 x i16> %a, <16 x i16> zeroinitializer, <16 x i32>
14661466 ret <16 x i16> %shuffle
16661666 ; AVX1-NEXT: vpshufb %xmm2, %xmm1, %xmm1
16671667 ; AVX1-NEXT: vpxor %xmm3, %xmm3, %xmm3
16681668 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm3 = xmm3[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
1669 ; AVX1-NEXT: vpshuflw $0, %xmm3, %xmm3 # xmm3 = xmm3[0,0,0,0,4,5,6,7]
1669 ; AVX1-NEXT: vpshuflw {{.*#+}} xmm3 = xmm3[0,0,0,0,4,5,6,7]
16701670 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm1 = xmm3[0],xmm1[0],xmm3[1],xmm1[1],xmm3[2],xmm1[2],xmm3[3],xmm1[3],xmm3[4],xmm1[4],xmm3[5],xmm1[5],xmm3[6],xmm1[6],xmm3[7],xmm1[7]
16711671 ; AVX1-NEXT: vpshufb %xmm2, %xmm0, %xmm0
16721672 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm0 = xmm3[0],xmm0[0],xmm3[1],xmm0[1],xmm3[2],xmm0[2],xmm3[3],xmm0[3],xmm3[4],xmm0[4],xmm3[5],xmm0[5],xmm3[6],xmm0[6],xmm3[7],xmm0[7]
16751675 ;
16761676 ; AVX2-LABEL: shuffle_v32i8_zz_00_zz_02_zz_04_zz_06_zz_08_zz_10_zz_12_zz_14_zz_16_zz_18_zz_20_zz_22_zz_24_zz_26_zz_28_zz_30:
16771677 ; AVX2: # BB#0:
1678 ; AVX2-NEXT: vpsllw $8, %ymm0
1678 ; AVX2-NEXT: vpsllw $8, %ymm0, %ymm0
16791679 ; AVX2-NEXT: retq
16801680 %shuffle = shufflevector <32 x i8> %a, <32 x i8> zeroinitializer, <32 x i32>
16811681 ret <32 x i8> %shuffle
16971697 ;
16981698 ; AVX2-LABEL: shuffle_v32i8_zz_zz_00_01_zz_zz_04_05_zz_zz_08_09_zz_zz_12_13_zz_zz_16_17_zz_zz_20_21_zz_zz_24_25_zz_zz_28_29:
16991699 ; AVX2: # BB#0:
1700 ; AVX2-NEXT: vpslld $16, %ymm0
1700 ; AVX2-NEXT: vpslld $16, %ymm0, %ymm0
17011701 ; AVX2-NEXT: retq
17021702 %shuffle = shufflevector <32 x i8> %a, <32 x i8> zeroinitializer, <32 x i32>
17031703 ret <32 x i8> %shuffle
17191719 ;
17201720 ; AVX2-LABEL: shuffle_v32i8_zz_zz_zz_zz_zz_zz_00_01_zz_zz_zz_zz_zz_zz_08_09_zz_zz_zz_zz_zz_zz_16_17_zz_zz_zz_zz_zz_zz_24_25:
17211721 ; AVX2: # BB#0:
1722 ; AVX2-NEXT: vpsllq $48, %ymm0
1722 ; AVX2-NEXT: vpsllq $48, %ymm0, %ymm0
17231723 ; AVX2-NEXT: retq
17241724 %shuffle = shufflevector <32 x i8> %a, <32 x i8> zeroinitializer, <32 x i32>
17251725 ret <32 x i8> %shuffle
17331733 ; AVX1-NEXT: vpshufb %xmm2, %xmm1, %xmm1
17341734 ; AVX1-NEXT: vpxor %xmm3, %xmm3, %xmm3
17351735 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm3 = xmm3[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
1736 ; AVX1-NEXT: vpshuflw $0, %xmm3, %xmm3 # xmm3 = xmm3[0,0,0,0,4,5,6,7]
1736 ; AVX1-NEXT: vpshuflw {{.*#+}} xmm3 = xmm3[0,0,0,0,4,5,6,7]
17371737 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm1 = xmm1[0],xmm3[0],xmm1[1],xmm3[1],xmm1[2],xmm3[2],xmm1[3],xmm3[3],xmm1[4],xmm3[4],xmm1[5],xmm3[5],xmm1[6],xmm3[6],xmm1[7],xmm3[7]
17381738 ; AVX1-NEXT: vpshufb %xmm2, %xmm0, %xmm0
17391739 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm0 = xmm0[0],xmm3[0],xmm0[1],xmm3[1],xmm0[2],xmm3[2],xmm0[3],xmm3[3],xmm0[4],xmm3[4],xmm0[5],xmm3[5],xmm0[6],xmm3[6],xmm0[7],xmm3[7]
17421742 ;
17431743 ; AVX2-LABEL: shuffle_v32i8_01_zz_03_zz_05_zz_07_zz_09_zz_11_zz_13_zz_15_zz_17_zz_19_zz_21_zz_23_zz_25_zz_27_zz_29_zz_31_zz:
17441744 ; AVX2: # BB#0:
1745 ; AVX2-NEXT: vpsrlw $8, %ymm0
1745 ; AVX2-NEXT: vpsrlw $8, %ymm0, %ymm0
17461746 ; AVX2-NEXT: retq
17471747 %shuffle = shufflevector <32 x i8> %a, <32 x i8> zeroinitializer, <32 x i32>
17481748 ret <32 x i8> %shuffle
17641764 ;
17651765 ; AVX2-LABEL: shuffle_v32i8_02_03_zz_zz_06_07_zz_zz_10_11_zz_zz_14_15_zz_zz_18_19_zz_zz_22_23_zz_zz_26_27_zz_zz_30_31_zz_zz:
17661766 ; AVX2: # BB#0:
1767 ; AVX2-NEXT: vpsrld $16, %ymm0
1767 ; AVX2-NEXT: vpsrld $16, %ymm0, %ymm0
17681768 ; AVX2-NEXT: retq
17691769 %shuffle = shufflevector <32 x i8> %a, <32 x i8> zeroinitializer, <32 x i32>
17701770 ret <32 x i8> %shuffle
17901790 ;
17911791 ; AVX2-LABEL: shuffle_v32i8_07_zz_zz_zz_zz_zz_zz_zz_15_zz_zz_zz_zz_z_zz_zz_23_zz_zz_zz_zz_zz_zz_zz_31_zz_zz_zz_zz_zz_zz_zz:
17921792 ; AVX2: # BB#0:
1793 ; AVX2-NEXT: vpsrlq $56, %ymm0
1793 ; AVX2-NEXT: vpsrlq $56, %ymm0, %ymm0
17941794 ; AVX2-NEXT: retq
17951795 %shuffle = shufflevector <32 x i8> %a, <32 x i8> zeroinitializer, <32 x i32>
17961796 ret <32 x i8> %shuffle
18111811 ; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm0 = xmm0[0],xmm2[0],xmm0[1],xmm2[1],xmm0[2],xmm2[2],xmm0[3],xmm2[3],xmm0[4],xmm2[4],xmm0[5],xmm2[5],xmm0[6],xmm2[6],xmm0[7],xmm2[7]
18121812 ; AVX1-NEXT: vinsertf128 $1, %xmm1, %ymm0, %ymm0
18131813 ; AVX1-NEXT: retq
1814
18151814 ;
18161815 ; AVX2-LABEL: shuffle_v32i8_32_zz_zz_zz_zz_zz_zz_zz_33_zz_zz_zz_zz_zz_zz_zz_34_zz_zz_zz_zz_zz_zz_zz_35_zz_zz_zz_zz_zz_zz_zz:
18171816 ; AVX2: # BB#0:
18181817 ; AVX2-NEXT: vpmovzxbq {{.*#+}} ymm0 = xmm0[0],zero,zero,zero,zero,zero,zero,zero,xmm0[1],zero,zero,zero,zero,zero,zero,zero,xmm0[2],zero,zero,zero,zero,zero,zero,zero,xmm0[3],zero,zero,zero,zero,zero,zero,zero
18191818 ; AVX2-NEXT: retq
1819
18201820 %shuffle = shufflevector <32 x i8> zeroinitializer, <32 x i8> %a, <32 x i32>
18211821 ret <32 x i8> %shuffle
18221822 }
748748 }
749749
750750 define <4 x i64> @stress_test1(<4 x i64> %a, <4 x i64> %b) {
751 ; AVX1-LABEL: stress_test1:
752 ; AVX1: # BB#0:
753 ; AVX1-NEXT: vperm2f128 {{.*#+}} ymm0 = ymm1[2,3,0,1]
754 ; AVX1-NEXT: vpermilpd {{.*#+}} ymm2 = ymm0[1,0,3,2]
755 ; AVX1-NEXT: vblendpd {{.*#+}} ymm1 = ymm2[0],ymm1[1],ymm2[2,3]
756 ; AVX1-NEXT: vpermilpd {{.*#+}} ymm0 = ymm0[1,1,3,2]
757 ; AVX1-NEXT: vunpckhpd {{.*#+}} ymm0 = ymm0[1],ymm1[1],ymm0[3],ymm1[3]
758 ; AVX1-NEXT: retq
759 ;
760 ; AVX2-LABEL: stress_test1:
761 ; AVX2: # BB#0:
762 ; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm1[3,1,1,0]
763 ; AVX2-NEXT: vpermq {{.*#+}} ymm1 = ymm1[3,3,1,3]
764 ; AVX2-NEXT: vpunpckhqdq {{.*#+}} ymm0 = ymm1[1],ymm0[1],ymm1[3],ymm0[3]
765 ; AVX2-NEXT: retq
751 ; ALL-LABEL: stress_test1:
752 ; ALL: retq
766753 %c = shufflevector <4 x i64> %b, <4 x i64> undef, <4 x i32>
767754 %d = shufflevector <4 x i64> %c, <4 x i64> undef, <4 x i32>
768755 %e = shufflevector <4 x i64> %b, <4 x i64> undef, <4 x i32>
846833 define <4 x i64> @splat_mem_v4i64(i64* %ptr) {
847834 ; AVX1-LABEL: splat_mem_v4i64:
848835 ; AVX1: # BB#0:
849 ; AVX1-NEXT: vmovddup (%rdi), %xmm0
836 ; AVX1-NEXT: vmovddup {{.*#+}} xmm0 = mem[0,0]
850837 ; AVX1-NEXT: vinsertf128 $1, %xmm0, %ymm0, %ymm0
851838 ; AVX1-NEXT: retq
852839 ;
18611861 ;
18621862 ; AVX2-LABEL: shuffle_v8i32_z0U2zUz6:
18631863 ; AVX2: # BB#0:
1864 ; AVX2-NEXT: vpsllq $32, %ymm0
1864 ; AVX2-NEXT: vpsllq $32, %ymm0, %ymm0
18651865 ; AVX2-NEXT: retq
18661866 %shuffle = shufflevector <8 x i32> %a, <8 x i32> zeroinitializer, <8 x i32>
18671867 ret <8 x i32> %shuffle
18771877 ;
18781878 ; AVX2-LABEL: shuffle_v8i32_1U3z5zUU:
18791879 ; AVX2: # BB#0:
1880 ; AVX2-NEXT: vpsrlq $32, %ymm0
1880 ; AVX2-NEXT: vpsrlq $32, %ymm0, %ymm0
18811881 ; AVX2-NEXT: retq
18821882 %shuffle = shufflevector <8 x i32> %a, <8 x i32> zeroinitializer, <8 x i32>
18831883 ret <8 x i32> %shuffle
55 define <8 x double> @shuffle_v8f64_00000000(<8 x double> %a, <8 x double> %b) {
66 ; ALL-LABEL: shuffle_v8f64_00000000:
77 ; ALL: # BB#0:
8 ; ALL-NEXT: vbroadcastsd %xmm0, %zmm0
8 ; ALL-NEXT: vbroadcastsd %xmm0, %zmm0
99 ; ALL-NEXT: retq
1010 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
1111 ret <8 x double> %shuffle
4747 define <8 x double> @shuffle_v8f64_00040000(<8 x double> %a, <8 x double> %b) {
4848 ; ALL-LABEL: shuffle_v8f64_00040000:
4949 ; ALL: # BB#0:
50 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
50 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
5151 ; ALL-NEXT: vbroadcastsd %xmm1, %ymm1
5252 ; ALL-NEXT: vbroadcastsd %xmm0, %ymm0
5353 ; ALL-NEXT: vblendpd {{.*#+}} ymm1 = ymm0[0,1,2],ymm1[3]
6060 define <8 x double> @shuffle_v8f64_00500000(<8 x double> %a, <8 x double> %b) {
6161 ; ALL-LABEL: shuffle_v8f64_00500000:
6262 ; ALL: # BB#0:
63 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
63 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
6464 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm1[0,1,1,3]
6565 ; ALL-NEXT: vbroadcastsd %xmm0, %ymm0
6666 ; ALL-NEXT: vblendpd {{.*#+}} ymm1 = ymm0[0,1],ymm1[2],ymm0[3]
7373 define <8 x double> @shuffle_v8f64_06000000(<8 x double> %a, <8 x double> %b) {
7474 ; ALL-LABEL: shuffle_v8f64_06000000:
7575 ; ALL: # BB#0:
76 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
76 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
7777 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm1[0,2,2,3]
7878 ; ALL-NEXT: vbroadcastsd %xmm0, %ymm0
7979 ; ALL-NEXT: vblendpd {{.*#+}} ymm1 = ymm0[0],ymm1[1],ymm0[2,3]
8686 define <8 x double> @shuffle_v8f64_70000000(<8 x double> %a, <8 x double> %b) {
8787 ; ALL-LABEL: shuffle_v8f64_70000000:
8888 ; ALL: # BB#0:
89 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
89 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
9090 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm1[3,1,2,3]
9191 ; ALL-NEXT: vbroadcastsd %xmm0, %ymm0
9292 ; ALL-NEXT: vblendpd {{.*#+}} ymm1 = ymm1[0],ymm0[1,2,3]
9999 define <8 x double> @shuffle_v8f64_01014545(<8 x double> %a, <8 x double> %b) {
100100 ; ALL-LABEL: shuffle_v8f64_01014545:
101101 ; ALL: # BB#0:
102 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
102 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
103103 ; ALL-NEXT: vinsertf128 $1, %xmm1, %ymm1, %ymm1
104104 ; ALL-NEXT: vinsertf128 $1, %xmm0, %ymm0, %ymm0
105105 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
133133 define <8 x double> @shuffle_v8f64_81a3c5e7(<8 x double> %a, <8 x double> %b) {
134134 ; ALL-LABEL: shuffle_v8f64_81a3c5e7:
135135 ; ALL: # BB#0:
136 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
137 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
136 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
137 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
138138 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
139139 ; ALL-NEXT: vblendpd {{.*#+}} ymm0 = ymm1[0],ymm0[1],ymm1[2],ymm0[3]
140140 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
158158 define <8 x double> @shuffle_v8f64_08084c4c(<8 x double> %a, <8 x double> %b) {
159159 ; ALL-LABEL: shuffle_v8f64_08084c4c:
160160 ; ALL: # BB#0:
161 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
161 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
162162 ; ALL-NEXT: vinsertf128 $1, %xmm2, %ymm2, %ymm2
163 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
163 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
164164 ; ALL-NEXT: vbroadcastsd %xmm3, %ymm3
165165 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm2[0],ymm3[1],ymm2[2],ymm3[3]
166166 ; ALL-NEXT: vinsertf128 $1, %xmm0, %ymm0, %ymm0
175175 define <8 x double> @shuffle_v8f64_8823cc67(<8 x double> %a, <8 x double> %b) {
176176 ; ALL-LABEL: shuffle_v8f64_8823cc67:
177177 ; ALL: # BB#0:
178 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
179 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
178 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
179 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
180180 ; ALL-NEXT: vbroadcastsd %xmm3, %ymm3
181181 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm3[0,1],ymm2[2,3]
182182 ; ALL-NEXT: vbroadcastsd %xmm1, %ymm1
220220 define <8 x double> @shuffle_v8f64_08194c5d(<8 x double> %a, <8 x double> %b) {
221221 ; ALL-LABEL: shuffle_v8f64_08194c5d:
222222 ; ALL: # BB#0:
223 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
223 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
224224 ; ALL-NEXT: vpermpd {{.*#+}} ymm2 = ymm2[0,0,2,1]
225 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
225 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
226226 ; ALL-NEXT: vpermpd {{.*#+}} ymm3 = ymm3[0,1,1,3]
227227 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
228228 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm1[0,0,2,1]
237237 define <8 x double> @shuffle_v8f64_2a3b6e7f(<8 x double> %a, <8 x double> %b) {
238238 ; ALL-LABEL: shuffle_v8f64_2a3b6e7f:
239239 ; ALL: # BB#0:
240 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
240 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
241241 ; ALL-NEXT: vpermpd {{.*#+}} ymm2 = ymm2[0,2,2,3]
242 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
242 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
243243 ; ALL-NEXT: vpermpd {{.*#+}} ymm3 = ymm3[2,1,3,3]
244244 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
245245 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm1[0,2,2,3]
283283 define <8 x double> @shuffle_v8f64_091b2d3f(<8 x double> %a, <8 x double> %b) {
284284 ; ALL-LABEL: shuffle_v8f64_091b2d3f:
285285 ; ALL: # BB#0:
286 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
286 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
287287 ; ALL-NEXT: vpermpd {{.*#+}} ymm3 = ymm0[2,1,3,3]
288288 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
289289 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,1,1,3]
297297 define <8 x double> @shuffle_v8f64_09ab1def(<8 x double> %a, <8 x double> %b) {
298298 ; ALL-LABEL: shuffle_v8f64_09ab1def:
299299 ; ALL: # BB#0:
300 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
300 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
301301 ; ALL-NEXT: vpermilpd {{.*#+}} ymm3 = ymm0[1,0,2,2]
302302 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm3[0],ymm2[1,2,3]
303303 ; ALL-NEXT: vblendpd {{.*#+}} ymm0 = ymm0[0],ymm1[1,2,3]
311311 ; ALL-LABEL: shuffle_v8f64_00014445:
312312 ; ALL: # BB#0:
313313 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[0,0,0,1]
314 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
314 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
315315 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,0,0,1]
316316 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
317317 ; ALL-NEXT: retq
323323 ; ALL-LABEL: shuffle_v8f64_00204464:
324324 ; ALL: # BB#0:
325325 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[0,0,2,0]
326 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
326 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
327327 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,0,2,0]
328328 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
329329 ; ALL-NEXT: retq
335335 ; ALL-LABEL: shuffle_v8f64_03004744:
336336 ; ALL: # BB#0:
337337 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[0,3,0,0]
338 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
338 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
339339 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,3,0,0]
340340 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
341341 ; ALL-NEXT: retq
347347 ; ALL-LABEL: shuffle_v8f64_10005444:
348348 ; ALL: # BB#0:
349349 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[1,0,0,0]
350 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
350 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
351351 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[1,0,0,0]
352352 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
353353 ; ALL-NEXT: retq
359359 ; ALL-LABEL: shuffle_v8f64_22006644:
360360 ; ALL: # BB#0:
361361 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[2,2,0,0]
362 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
362 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
363363 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,2,0,0]
364364 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
365365 ; ALL-NEXT: retq
371371 ; ALL-LABEL: shuffle_v8f64_33307774:
372372 ; ALL: # BB#0:
373373 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[3,3,3,0]
374 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
374 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
375375 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[3,3,3,0]
376376 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
377377 ; ALL-NEXT: retq
383383 ; ALL-LABEL: shuffle_v8f64_32107654:
384384 ; ALL: # BB#0:
385385 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[3,2,1,0]
386 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
386 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
387387 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[3,2,1,0]
388388 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
389389 ; ALL-NEXT: retq
395395 ; ALL-LABEL: shuffle_v8f64_00234467:
396396 ; ALL: # BB#0:
397397 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[0,0,2,3]
398 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
398 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
399399 ; ALL-NEXT: vpermilpd {{.*#+}} ymm0 = ymm0[0,0,2,3]
400400 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
401401 ; ALL-NEXT: retq
403403 ret <8 x double> %shuffle
404404 }
405405
406 define <8 x double> @shuffle_v8f64_00224466(<8 x double> %a, <8 x double> %b) {
407 ; ALL-LABEL: shuffle_v8f64_00224466:
408 ; ALL: # BB#0:
409 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm0[0,0,2,2]
410 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
411 ; ALL-NEXT: vmovddup {{.*#+}} ymm0 = ymm0[0,0,2,2]
412 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
413 ; ALL-NEXT: retq
414 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
406 define <8 x double> @shuffle_v8f64_00224466(<8 x double> %a, <8 x double> %b) {
407 ; ALL-LABEL: shuffle_v8f64_00224466:
408 ; ALL: # BB#0:
409 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm0[0,0,2,2]
410 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
411 ; ALL-NEXT: vmovddup {{.*#+}} ymm0 = ymm0[0,0,2,2]
412 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
413 ; ALL-NEXT: retq
414 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
415415 ret <8 x double> %shuffle
416416 }
417417
419419 ; ALL-LABEL: shuffle_v8f64_10325476:
420420 ; ALL: # BB#0:
421421 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,0,3,2]
422 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
422 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
423423 ; ALL-NEXT: vpermilpd {{.*#+}} ymm0 = ymm0[1,0,3,2]
424424 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
425425 ; ALL-NEXT: retq
431431 ; ALL-LABEL: shuffle_v8f64_11335577:
432432 ; ALL: # BB#0:
433433 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,1,3,3]
434 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
434 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
435435 ; ALL-NEXT: vpermilpd {{.*#+}} ymm0 = ymm0[1,1,3,3]
436436 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
437437 ; ALL-NEXT: retq
443443 ; ALL-LABEL: shuffle_v8f64_10235467:
444444 ; ALL: # BB#0:
445445 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,0,2,3]
446 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
446 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
447447 ; ALL-NEXT: vpermilpd {{.*#+}} ymm0 = ymm0[1,0,2,3]
448448 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
449449 ; ALL-NEXT: retq
455455 ; ALL-LABEL: shuffle_v8f64_10225466:
456456 ; ALL: # BB#0:
457457 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,0,2,2]
458 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
458 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
459459 ; ALL-NEXT: vpermilpd {{.*#+}} ymm0 = ymm0[1,0,2,2]
460460 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
461461 ; ALL-NEXT: retq
467467 ; ALL-LABEL: shuffle_v8f64_00015444:
468468 ; ALL: # BB#0:
469469 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[0,0,0,1]
470 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
470 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
471471 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[1,0,0,0]
472472 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
473473 ; ALL-NEXT: retq
479479 ; ALL-LABEL: shuffle_v8f64_00204644:
480480 ; ALL: # BB#0:
481481 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[0,0,2,0]
482 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
482 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
483483 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,2,0,0]
484484 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
485485 ; ALL-NEXT: retq
491491 ; ALL-LABEL: shuffle_v8f64_03004474:
492492 ; ALL: # BB#0:
493493 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[0,3,0,0]
494 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
494 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
495495 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,0,3,0]
496496 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
497497 ; ALL-NEXT: retq
503503 ; ALL-LABEL: shuffle_v8f64_10004444:
504504 ; ALL: # BB#0:
505505 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[1,0,0,0]
506 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
506 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
507507 ; ALL-NEXT: vbroadcastsd %xmm0, %ymm0
508508 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
509509 ; ALL-NEXT: retq
515515 ; ALL-LABEL: shuffle_v8f64_22006446:
516516 ; ALL: # BB#0:
517517 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[2,2,0,0]
518 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
518 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
519519 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,0,0,2]
520520 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
521521 ; ALL-NEXT: retq
527527 ; ALL-LABEL: shuffle_v8f64_33307474:
528528 ; ALL: # BB#0:
529529 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[3,3,3,0]
530 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
530 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
531531 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[3,0,3,0]
532532 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
533533 ; ALL-NEXT: retq
539539 ; ALL-LABEL: shuffle_v8f64_32104567:
540540 ; ALL: # BB#0:
541541 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm0[3,2,1,0]
542 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
542 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
543543 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
544544 ; ALL-NEXT: retq
545545 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
550550 ; ALL-LABEL: shuffle_v8f64_00236744:
551551 ; ALL: # BB#0:
552552 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[0,0,2,3]
553 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
553 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
554554 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,3,0,0]
555555 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
556556 ; ALL-NEXT: retq
558558 ret <8 x double> %shuffle
559559 }
560560
561 define <8 x double> @shuffle_v8f64_00226644(<8 x double> %a, <8 x double> %b) {
562 ; ALL-LABEL: shuffle_v8f64_00226644:
563 ; ALL: # BB#0:
564 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm0[0,0,2,2]
565 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
566 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,2,0,0]
567 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
561 define <8 x double> @shuffle_v8f64_00226644(<8 x double> %a, <8 x double> %b) {
562 ; ALL-LABEL: shuffle_v8f64_00226644:
563 ; ALL: # BB#0:
564 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm0[0,0,2,2]
565 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
566 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,2,0,0]
567 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
568568 ; ALL-NEXT: retq
569569 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
570570 ret <8 x double> %shuffle
574574 ; ALL-LABEL: shuffle_v8f64_10324567:
575575 ; ALL: # BB#0:
576576 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,0,3,2]
577 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
577 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
578578 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
579579 ; ALL-NEXT: retq
580580 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
585585 ; ALL-LABEL: shuffle_v8f64_11334567:
586586 ; ALL: # BB#0:
587587 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,1,3,3]
588 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
588 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
589589 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
590590 ; ALL-NEXT: retq
591591 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
595595 define <8 x double> @shuffle_v8f64_01235467(<8 x double> %a, <8 x double> %b) {
596596 ; ALL-LABEL: shuffle_v8f64_01235467:
597597 ; ALL: # BB#0:
598 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
598 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
599599 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm1[1,0,2,3]
600600 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
601601 ; ALL-NEXT: retq
606606 define <8 x double> @shuffle_v8f64_01235466(<8 x double> %a, <8 x double> %b) {
607607 ; ALL-LABEL: shuffle_v8f64_01235466:
608608 ; ALL: # BB#0:
609 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
609 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
610610 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm1[1,0,2,2]
611611 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
612612 ; ALL-NEXT: retq
614614 ret <8 x double> %shuffle
615615 }
616616
617 define <8 x double> @shuffle_v8f64_002u6u44(<8 x double> %a, <8 x double> %b) {
618 ; ALL-LABEL: shuffle_v8f64_002u6u44:
619 ; ALL: # BB#0:
620 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm0[0,0,2,2]
621 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
622 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,1,0,0]
623 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
617 define <8 x double> @shuffle_v8f64_002u6u44(<8 x double> %a, <8 x double> %b) {
618 ; ALL-LABEL: shuffle_v8f64_002u6u44:
619 ; ALL: # BB#0:
620 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm0[0,0,2,2]
621 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
622 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,1,0,0]
623 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
624624 ; ALL-NEXT: retq
625625 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
626626 ret <8 x double> %shuffle
630630 ; ALL-LABEL: shuffle_v8f64_00uu66uu:
631631 ; ALL: # BB#0:
632632 ; ALL-NEXT: vbroadcastsd %xmm0, %ymm1
633 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
633 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
634634 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[2,2,2,3]
635635 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
636636 ; ALL-NEXT: retq
642642 ; ALL-LABEL: shuffle_v8f64_103245uu:
643643 ; ALL: # BB#0:
644644 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,0,3,2]
645 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
645 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
646646 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
647647 ; ALL-NEXT: retq
648648 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
653653 ; ALL-LABEL: shuffle_v8f64_1133uu67:
654654 ; ALL: # BB#0:
655655 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm0[1,1,3,3]
656 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
656 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
657657 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
658658 ; ALL-NEXT: retq
659659 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
663663 define <8 x double> @shuffle_v8f64_0uu354uu(<8 x double> %a, <8 x double> %b) {
664664 ; ALL-LABEL: shuffle_v8f64_0uu354uu:
665665 ; ALL: # BB#0:
666 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
666 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
667667 ; ALL-NEXT: vpermilpd {{.*#+}} ymm1 = ymm1[1,0,2,2]
668668 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
669669 ; ALL-NEXT: retq
672672 }
673673
674674 define <8 x double> @shuffle_v8f64_uuu3uu66(<8 x double> %a, <8 x double> %b) {
675 ; ALL-LABEL: shuffle_v8f64_uuu3uu66:
676 ; ALL: # BB#0:
677 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
678 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm1[0,0,2,2]
679 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
680 ; ALL-NEXT: retq
681 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
675 ; ALL-LABEL: shuffle_v8f64_uuu3uu66:
676 ; ALL: # BB#0:
677 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
678 ; ALL-NEXT: vmovddup {{.*#+}} ymm1 = ymm1[0,0,2,2]
679 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
680 ; ALL-NEXT: retq
681 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32>
682682 ret <8 x double> %shuffle
683683 }
684684
685685 define <8 x double> @shuffle_v8f64_c348cda0(<8 x double> %a, <8 x double> %b) {
686686 ; ALL-LABEL: shuffle_v8f64_c348cda0:
687687 ; ALL: # BB#0:
688 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
688 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
689689 ; ALL-NEXT: vperm2f128 {{.*#+}} ymm2 = ymm0[0,1],ymm2[0,1]
690 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
690 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
691691 ; ALL-NEXT: vbroadcastsd %xmm1, %ymm4
692692 ; ALL-NEXT: vblendpd {{.*#+}} ymm4 = ymm3[0,1,2],ymm4[3]
693693 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm4[0],ymm2[1,2],ymm4[3]
704704 ; ALL-LABEL: shuffle_v8f64_f511235a:
705705 ; ALL: # BB#0:
706706 ; ALL-NEXT: vperm2f128 {{.*#+}} ymm2 = ymm0[2,3,0,1]
707 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
708 ; ALL-NEXT: vpermpd {{.*#+}} ymm4 = ymm3[0,1,1,3]
709 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm2[0,1],ymm4[2],ymm2[3]
710 ; ALL-NEXT: vmovddup {{.*#+}} ymm4 = ymm1[0,0,2,2]
711 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm2[0,1,2],ymm4[3]
712 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,1,1,1]
713 ; ALL-NEXT: vblendpd {{.*#+}} ymm0 = ymm0[0],ymm3[1],ymm0[2,3]
714 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm1
707 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
708 ; ALL-NEXT: vpermpd {{.*#+}} ymm4 = ymm3[0,1,1,3]
709 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm2[0,1],ymm4[2],ymm2[3]
710 ; ALL-NEXT: vmovddup {{.*#+}} ymm4 = ymm1[0,0,2,2]
711 ; ALL-NEXT: vblendpd {{.*#+}} ymm2 = ymm2[0,1,2],ymm4[3]
712 ; ALL-NEXT: vpermpd {{.*#+}} ymm0 = ymm0[0,1,1,1]
713 ; ALL-NEXT: vblendpd {{.*#+}} ymm0 = ymm0[0],ymm3[1],ymm0[2,3]
714 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm1
715715 ; ALL-NEXT: vpermpd {{.*#+}} ymm1 = ymm1[3,1,2,3]
716716 ; ALL-NEXT: vblendpd {{.*#+}} ymm0 = ymm1[0],ymm0[1,2,3]
717717 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
765765 define <8 x i64> @shuffle_v8i64_00040000(<8 x i64> %a, <8 x i64> %b) {
766766 ; ALL-LABEL: shuffle_v8i64_00040000:
767767 ; ALL: # BB#0:
768 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
768 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
769769 ; ALL-NEXT: vpbroadcastq %xmm1, %ymm1
770770 ; ALL-NEXT: vpbroadcastq %xmm0, %ymm0
771771 ; ALL-NEXT: vpblendd {{.*#+}} ymm1 = ymm0[0,1,2,3,4,5],ymm1[6,7]
778778 define <8 x i64> @shuffle_v8i64_00500000(<8 x i64> %a, <8 x i64> %b) {
779779 ; ALL-LABEL: shuffle_v8i64_00500000:
780780 ; ALL: # BB#0:
781 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
781 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
782782 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[0,1,1,3]
783783 ; ALL-NEXT: vpbroadcastq %xmm0, %ymm0
784784 ; ALL-NEXT: vpblendd {{.*#+}} ymm1 = ymm0[0,1,2,3],ymm1[4,5],ymm0[6,7]
791791 define <8 x i64> @shuffle_v8i64_06000000(<8 x i64> %a, <8 x i64> %b) {
792792 ; ALL-LABEL: shuffle_v8i64_06000000:
793793 ; ALL: # BB#0:
794 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
794 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
795795 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[0,2,2,3]
796796 ; ALL-NEXT: vpbroadcastq %xmm0, %ymm0
797797 ; ALL-NEXT: vpblendd {{.*#+}} ymm1 = ymm0[0,1],ymm1[2,3],ymm0[4,5,6,7]
804804 define <8 x i64> @shuffle_v8i64_70000000(<8 x i64> %a, <8 x i64> %b) {
805805 ; ALL-LABEL: shuffle_v8i64_70000000:
806806 ; ALL: # BB#0:
807 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
807 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
808808 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[3,1,2,3]
809809 ; ALL-NEXT: vpbroadcastq %xmm0, %ymm0
810810 ; ALL-NEXT: vpblendd {{.*#+}} ymm1 = ymm1[0,1],ymm0[2,3,4,5,6,7]
817817 define <8 x i64> @shuffle_v8i64_01014545(<8 x i64> %a, <8 x i64> %b) {
818818 ; ALL-LABEL: shuffle_v8i64_01014545:
819819 ; ALL: # BB#0:
820 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
820 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
821821 ; ALL-NEXT: vinserti128 $1, %xmm1, %ymm1, %ymm1
822822 ; ALL-NEXT: vinserti128 $1, %xmm0, %ymm0, %ymm0
823823 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
851851 define <8 x i64> @shuffle_v8i64_81a3c5e7(<8 x i64> %a, <8 x i64> %b) {
852852 ; ALL-LABEL: shuffle_v8i64_81a3c5e7:
853853 ; ALL: # BB#0:
854 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
855 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
854 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
855 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
856856 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
857857 ; ALL-NEXT: vpblendd {{.*#+}} ymm0 = ymm1[0,1],ymm0[2,3],ymm1[4,5],ymm0[6,7]
858858 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
876876 define <8 x i64> @shuffle_v8i64_08084c4c(<8 x i64> %a, <8 x i64> %b) {
877877 ; ALL-LABEL: shuffle_v8i64_08084c4c:
878878 ; ALL: # BB#0:
879 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
879 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
880880 ; ALL-NEXT: vinserti128 $1, %xmm2, %ymm2, %ymm2
881 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
881 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
882882 ; ALL-NEXT: vpbroadcastq %xmm3, %ymm3
883883 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm2[0,1],ymm3[2,3],ymm2[4,5],ymm3[6,7]
884884 ; ALL-NEXT: vinserti128 $1, %xmm0, %ymm0, %ymm0
893893 define <8 x i64> @shuffle_v8i64_8823cc67(<8 x i64> %a, <8 x i64> %b) {
894894 ; ALL-LABEL: shuffle_v8i64_8823cc67:
895895 ; ALL: # BB#0:
896 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
897 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
896 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
897 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
898898 ; ALL-NEXT: vpbroadcastq %xmm3, %ymm3
899899 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm3[0,1,2,3],ymm2[4,5,6,7]
900900 ; ALL-NEXT: vpbroadcastq %xmm1, %ymm1
938938 define <8 x i64> @shuffle_v8i64_08194c5d(<8 x i64> %a, <8 x i64> %b) {
939939 ; ALL-LABEL: shuffle_v8i64_08194c5d:
940940 ; ALL: # BB#0:
941 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
941 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
942942 ; ALL-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,0,2,1]
943 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
943 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
944944 ; ALL-NEXT: vpermq {{.*#+}} ymm3 = ymm3[0,1,1,3]
945945 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
946946 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[0,0,2,1]
955955 define <8 x i64> @shuffle_v8i64_2a3b6e7f(<8 x i64> %a, <8 x i64> %b) {
956956 ; ALL-LABEL: shuffle_v8i64_2a3b6e7f:
957957 ; ALL: # BB#0:
958 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
958 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
959959 ; ALL-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,2,3]
960 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
960 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
961961 ; ALL-NEXT: vpermq {{.*#+}} ymm3 = ymm3[2,1,3,3]
962962 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
963963 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[0,2,2,3]
10011001 define <8 x i64> @shuffle_v8i64_091b2d3f(<8 x i64> %a, <8 x i64> %b) {
10021002 ; ALL-LABEL: shuffle_v8i64_091b2d3f:
10031003 ; ALL: # BB#0:
1004 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
1004 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
10051005 ; ALL-NEXT: vpermq {{.*#+}} ymm3 = ymm0[2,1,3,3]
10061006 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
10071007 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,1,1,3]
10151015 define <8 x i64> @shuffle_v8i64_09ab1def(<8 x i64> %a, <8 x i64> %b) {
10161016 ; ALL-LABEL: shuffle_v8i64_09ab1def:
10171017 ; ALL: # BB#0:
1018 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
1018 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
10191019 ; ALL-NEXT: vpshufd {{.*#+}} ymm3 = ymm0[2,3,2,3,6,7,6,7]
10201020 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm3[0,1],ymm2[2,3,4,5,6,7]
10211021 ; ALL-NEXT: vpblendd {{.*#+}} ymm0 = ymm0[0,1],ymm1[2,3,4,5,6,7]
10291029 ; ALL-LABEL: shuffle_v8i64_00014445:
10301030 ; ALL: # BB#0:
10311031 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,0,0,1]
1032 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1032 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
10331033 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,0,0,1]
10341034 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
10351035 ; ALL-NEXT: retq
10411041 ; ALL-LABEL: shuffle_v8i64_00204464:
10421042 ; ALL: # BB#0:
10431043 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,0,2,0]
1044 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1044 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
10451045 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,0,2,0]
10461046 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
10471047 ; ALL-NEXT: retq
10531053 ; ALL-LABEL: shuffle_v8i64_03004744:
10541054 ; ALL: # BB#0:
10551055 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,3,0,0]
1056 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1056 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
10571057 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,3,0,0]
10581058 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
10591059 ; ALL-NEXT: retq
10651065 ; ALL-LABEL: shuffle_v8i64_10005444:
10661066 ; ALL: # BB#0:
10671067 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[1,0,0,0]
1068 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1068 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
10691069 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[1,0,0,0]
10701070 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
10711071 ; ALL-NEXT: retq
10771077 ; ALL-LABEL: shuffle_v8i64_22006644:
10781078 ; ALL: # BB#0:
10791079 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[2,2,0,0]
1080 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1080 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
10811081 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[2,2,0,0]
10821082 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
10831083 ; ALL-NEXT: retq
10891089 ; ALL-LABEL: shuffle_v8i64_33307774:
10901090 ; ALL: # BB#0:
10911091 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[3,3,3,0]
1092 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1092 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
10931093 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[3,3,3,0]
10941094 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
10951095 ; ALL-NEXT: retq
11011101 ; ALL-LABEL: shuffle_v8i64_32107654:
11021102 ; ALL: # BB#0:
11031103 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[3,2,1,0]
1104 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1104 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11051105 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[3,2,1,0]
11061106 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11071107 ; ALL-NEXT: retq
11131113 ; ALL-LABEL: shuffle_v8i64_00234467:
11141114 ; ALL: # BB#0:
11151115 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,0,2,3]
1116 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1116 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11171117 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,0,2,3]
11181118 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11191119 ; ALL-NEXT: retq
11251125 ; ALL-LABEL: shuffle_v8i64_00224466:
11261126 ; ALL: # BB#0:
11271127 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[0,1,0,1,4,5,4,5]
1128 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1128 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11291129 ; ALL-NEXT: vpshufd {{.*#+}} ymm0 = ymm0[0,1,0,1,4,5,4,5]
11301130 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11311131 ; ALL-NEXT: retq
11371137 ; ALL-LABEL: shuffle_v8i64_10325476:
11381138 ; ALL: # BB#0:
11391139 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[2,3,0,1,6,7,4,5]
1140 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1140 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11411141 ; ALL-NEXT: vpshufd {{.*#+}} ymm0 = ymm0[2,3,0,1,6,7,4,5]
11421142 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11431143 ; ALL-NEXT: retq
11491149 ; ALL-LABEL: shuffle_v8i64_11335577:
11501150 ; ALL: # BB#0:
11511151 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[2,3,2,3,6,7,6,7]
1152 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1152 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11531153 ; ALL-NEXT: vpshufd {{.*#+}} ymm0 = ymm0[2,3,2,3,6,7,6,7]
11541154 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11551155 ; ALL-NEXT: retq
11611161 ; ALL-LABEL: shuffle_v8i64_10235467:
11621162 ; ALL: # BB#0:
11631163 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[1,0,2,3]
1164 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1164 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11651165 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[1,0,2,3]
11661166 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11671167 ; ALL-NEXT: retq
11731173 ; ALL-LABEL: shuffle_v8i64_10225466:
11741174 ; ALL: # BB#0:
11751175 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[1,0,2,2]
1176 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1176 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11771177 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[1,0,2,2]
11781178 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11791179 ; ALL-NEXT: retq
11851185 ; ALL-LABEL: shuffle_v8i64_00015444:
11861186 ; ALL: # BB#0:
11871187 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,0,0,1]
1188 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1188 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
11891189 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[1,0,0,0]
11901190 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
11911191 ; ALL-NEXT: retq
11971197 ; ALL-LABEL: shuffle_v8i64_00204644:
11981198 ; ALL: # BB#0:
11991199 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,0,2,0]
1200 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1200 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12011201 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,0,0]
12021202 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12031203 ; ALL-NEXT: retq
12091209 ; ALL-LABEL: shuffle_v8i64_03004474:
12101210 ; ALL: # BB#0:
12111211 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,3,0,0]
1212 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1212 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12131213 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,0,3,0]
12141214 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12151215 ; ALL-NEXT: retq
12211221 ; ALL-LABEL: shuffle_v8i64_10004444:
12221222 ; ALL: # BB#0:
12231223 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[1,0,0,0]
1224 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1224 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12251225 ; ALL-NEXT: vpbroadcastq %xmm0, %ymm0
12261226 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12271227 ; ALL-NEXT: retq
12331233 ; ALL-LABEL: shuffle_v8i64_22006446:
12341234 ; ALL: # BB#0:
12351235 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[2,2,0,0]
1236 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1236 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12371237 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[2,0,0,2]
12381238 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12391239 ; ALL-NEXT: retq
12451245 ; ALL-LABEL: shuffle_v8i64_33307474:
12461246 ; ALL: # BB#0:
12471247 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[3,3,3,0]
1248 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1248 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12491249 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[3,0,3,0]
12501250 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12511251 ; ALL-NEXT: retq
12571257 ; ALL-LABEL: shuffle_v8i64_32104567:
12581258 ; ALL: # BB#0:
12591259 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[3,2,1,0]
1260 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1260 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12611261 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12621262 ; ALL-NEXT: retq
12631263 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32>
12681268 ; ALL-LABEL: shuffle_v8i64_00236744:
12691269 ; ALL: # BB#0:
12701270 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm0[0,0,2,3]
1271 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1271 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12721272 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[2,3,0,0]
12731273 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12741274 ; ALL-NEXT: retq
12801280 ; ALL-LABEL: shuffle_v8i64_00226644:
12811281 ; ALL: # BB#0:
12821282 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[0,1,0,1,4,5,4,5]
1283 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1283 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12841284 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[2,2,0,0]
12851285 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12861286 ; ALL-NEXT: retq
12921292 ; ALL-LABEL: shuffle_v8i64_10324567:
12931293 ; ALL: # BB#0:
12941294 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[2,3,0,1,6,7,4,5]
1295 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1295 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
12961296 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
12971297 ; ALL-NEXT: retq
12981298 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32>
13031303 ; ALL-LABEL: shuffle_v8i64_11334567:
13041304 ; ALL: # BB#0:
13051305 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[2,3,2,3,6,7,6,7]
1306 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1306 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
13071307 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
13081308 ; ALL-NEXT: retq
13091309 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32>
13131313 define <8 x i64> @shuffle_v8i64_01235467(<8 x i64> %a, <8 x i64> %b) {
13141314 ; ALL-LABEL: shuffle_v8i64_01235467:
13151315 ; ALL: # BB#0:
1316 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1316 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
13171317 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[1,0,2,3]
13181318 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
13191319 ; ALL-NEXT: retq
13241324 define <8 x i64> @shuffle_v8i64_01235466(<8 x i64> %a, <8 x i64> %b) {
13251325 ; ALL-LABEL: shuffle_v8i64_01235466:
13261326 ; ALL: # BB#0:
1327 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1327 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
13281328 ; ALL-NEXT: vpermq {{.*#+}} ymm1 = ymm1[1,0,2,2]
13291329 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
13301330 ; ALL-NEXT: retq
13361336 ; ALL-LABEL: shuffle_v8i64_002u6u44:
13371337 ; ALL: # BB#0:
13381338 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[0,1,0,1,4,5,4,5]
1339 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1339 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
13401340 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[2,1,0,0]
13411341 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
13421342 ; ALL-NEXT: retq
13481348 ; ALL-LABEL: shuffle_v8i64_00uu66uu:
13491349 ; ALL: # BB#0:
13501350 ; ALL-NEXT: vpbroadcastq %xmm0, %ymm1
1351 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1351 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
13521352 ; ALL-NEXT: vpermq {{.*#+}} ymm0 = ymm0[2,2,2,3]
13531353 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
13541354 ; ALL-NEXT: retq
13601360 ; ALL-LABEL: shuffle_v8i64_103245uu:
13611361 ; ALL: # BB#0:
13621362 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[2,3,0,1,6,7,4,5]
1363 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1363 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
13641364 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
13651365 ; ALL-NEXT: retq
13661366 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32>
13711371 ; ALL-LABEL: shuffle_v8i64_1133uu67:
13721372 ; ALL: # BB#0:
13731373 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm0[2,3,2,3,6,7,6,7]
1374 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1374 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
13751375 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
13761376 ; ALL-NEXT: retq
13771377 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32>
13811381 define <8 x i64> @shuffle_v8i64_0uu354uu(<8 x i64> %a, <8 x i64> %b) {
13821382 ; ALL-LABEL: shuffle_v8i64_0uu354uu:
13831383 ; ALL: # BB#0:
1384 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1384 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
13851385 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm1[2,3,0,1,6,7,4,5]
13861386 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
13871387 ; ALL-NEXT: retq
13921392 define <8 x i64> @shuffle_v8i64_uuu3uu66(<8 x i64> %a, <8 x i64> %b) {
13931393 ; ALL-LABEL: shuffle_v8i64_uuu3uu66:
13941394 ; ALL: # BB#0:
1395 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1395 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
13961396 ; ALL-NEXT: vpshufd {{.*#+}} ymm1 = ymm1[0,1,0,1,4,5,4,5]
13971397 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
13981398 ; ALL-NEXT: retq
14031403 define <8 x i64> @shuffle_v8i64_6caa87e5(<8 x i64> %a, <8 x i64> %b) {
14041404 ; ALL-LABEL: shuffle_v8i64_6caa87e5:
14051405 ; ALL: # BB#0:
1406 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1406 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
14071407 ; ALL-NEXT: vperm2i128 {{.*#+}} ymm2 = ymm0[0,1,0,1]
1408 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
1408 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
14091409 ; ALL-NEXT: vpblendd {{.*#+}} ymm4 = ymm1[0,1,2,3],ymm3[4,5],ymm1[6,7]
14101410 ; ALL-NEXT: vpblendd {{.*#+}} ymm2 = ymm4[0,1],ymm2[2,3],ymm4[4,5],ymm2[6,7]
14111411 ; ALL-NEXT: vperm2i128 {{.*#+}} ymm0 = ymm0[2,3,0,1]
11 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+sse4.1 | FileCheck %s --check-prefix=SSE41
22
33 define <4 x i32> @test1(<4 x i32> %A, <4 x i32> %B) {
4 ; SSE2-LABEL: test1
5 ; SSE2: # BB#0:
6 ; SSE2-NEXT: movsd %xmm0, %xmm1
7 ; SSE2-NEXT: movaps %xmm1, %xmm0
8 ; SSE2-NEXT: retq
4 ; SSE2-LABEL: test1:
5 ; SSE2: # BB#0:
6 ; SSE2-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
7 ; SSE2-NEXT: movaps %xmm1, %xmm0
8 ; SSE2-NEXT: retq
99 ;
10 ; SSE41-LABEL: test1
10 ; SSE41-LABEL: test1:
1111 ; SSE41: # BB#0:
1212 ; SSE41-NEXT: pblendw {{.*#+}} xmm0 = xmm0[0,1,2,3],xmm1[4,5,6,7]
1313 ; SSE41-NEXT: retq
1616 }
1717
1818 define <4 x i32> @test2(<4 x i32> %A, <4 x i32> %B) {
19 ; SSE2-LABEL: test2
20 ; SSE2: # BB#0:
21 ; SSE2-NEXT: movsd %xmm1, %xmm0
22 ; SSE2-NEXT: retq
19 ; SSE2-LABEL: test2:
20 ; SSE2: # BB#0:
21 ; SSE2-NEXT: movsd {{.*#+}} xmm0 = xmm1[0],xmm0[1]
22 ; SSE2-NEXT: retq
2323 ;
24 ; SSE41-LABEL: test2
24 ; SSE41-LABEL: test2:
2525 ; SSE41: # BB#0:
2626 ; SSE41-NEXT: pblendw {{.*#+}} xmm0 = xmm1[0,1,2,3],xmm0[4,5,6,7]
2727 ; SSE41-NEXT: retq
3030 }
3131
3232 define <4 x float> @test3(<4 x float> %A, <4 x float> %B) {
33 ; SSE2-LABEL: test3
34 ; SSE2: # BB#0:
35 ; SSE2-NEXT: movsd %xmm0, %xmm1
36 ; SSE2-NEXT: movaps %xmm1, %xmm0
37 ; SSE2-NEXT: retq
33 ; SSE2-LABEL: test3:
34 ; SSE2: # BB#0:
35 ; SSE2-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
36 ; SSE2-NEXT: movaps %xmm1, %xmm0
37 ; SSE2-NEXT: retq
3838 ;
39 ; SSE41-LABEL: test3
39 ; SSE41-LABEL: test3:
4040 ; SSE41: # BB#0:
4141 ; SSE41-NEXT: blendpd {{.*#+}} xmm0 = xmm0[0],xmm1[1]
4242 ; SSE41-NEXT: retq
4545 }
4646
4747 define <4 x float> @test4(<4 x float> %A, <4 x float> %B) {
48 ; SSE2-LABEL: test4
49 ; SSE2: # BB#0:
50 ; SSE2-NEXT: movsd %xmm1, %xmm0
51 ; SSE2-NEXT: retq
48 ; SSE2-LABEL: test4:
49 ; SSE2: # BB#0:
50 ; SSE2-NEXT: movsd {{.*#+}} xmm0 = xmm1[0],xmm0[1]
51 ; SSE2-NEXT: retq
5252 ;
53 ; SSE41-LABEL: test4
53 ; SSE41-LABEL: test4:
5454 ; SSE41: # BB#0:
5555 ; SSE41-NEXT: blendpd {{.*#+}} xmm0 = xmm1[0],xmm0[1]
5656 ; SSE41-NEXT: retq
1616 define <4 x float> @test2(<4 x float> %a, <4 x float> %b) {
1717 ; CHECK-LABEL: test2:
1818 ; CHECK: # BB#0:
19 ; CHECK-NEXT: movsd %xmm0, %xmm1
19 ; CHECK-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
2020 ; CHECK-NEXT: movaps %xmm1, %xmm0
2121 ; CHECK-NEXT: retq
2222 %1 = select <4 x i1> , <4 x float> %a, <4 x float> %b
2626 define <4 x float> @test3(<4 x float> %a, <4 x float> %b) {
2727 ; CHECK-LABEL: test3:
2828 ; CHECK: # BB#0:
29 ; CHECK-NEXT: movsd %xmm1, %xmm0
29 ; CHECK-NEXT: movsd {{.*#+}} xmm0 = xmm1[0],xmm0[1]
3030 ; CHECK-NEXT: retq
3131 %1 = select <4 x i1> , <4 x float> %a, <4 x float> %b
3232 ret <4 x float> %1
168168 define <4 x float> @test18(<4 x float> %a, <4 x float> %b) {
169169 ; CHECK-LABEL: test18:
170170 ; CHECK: # BB#0:
171 ; CHECK-NEXT: movss %xmm1, %xmm0
171 ; CHECK-NEXT: movss {{.*#+}} xmm0 = xmm1[0],xmm0[1,2,3]
172172 ; CHECK-NEXT: retq
173173 %1 = select <4 x i1> , <4 x float> %a, <4 x float> %b
174174 ret <4 x float> %1
177177 define <4 x i32> @test19(<4 x i32> %a, <4 x i32> %b) {
178178 ; CHECK-LABEL: test19:
179179 ; CHECK: # BB#0:
180 ; CHECK-NEXT: movss %xmm1, %xmm0
180 ; CHECK-NEXT: movss {{.*#+}} xmm0 = xmm1[0],xmm0[1,2,3]
181181 ; CHECK-NEXT: retq
182182 %1 = select <4 x i1> , <4 x i32> %a, <4 x i32> %b
183183 ret <4 x i32> %1
186186 define <2 x double> @test20(<2 x double> %a, <2 x double> %b) {
187187 ; CHECK-LABEL: test20:
188188 ; CHECK: # BB#0:
189 ; CHECK-NEXT: movsd %xmm1, %xmm0
189 ; CHECK-NEXT: movsd {{.*#+}} xmm0 = xmm1[0],xmm0[1]
190190 ; CHECK-NEXT: retq
191191 %1 = select <2 x i1> , <2 x double> %a, <2 x double> %b
192192 ret <2 x double> %1
195195 define <2 x i64> @test21(<2 x i64> %a, <2 x i64> %b) {
196196 ; CHECK-LABEL: test21:
197197 ; CHECK: # BB#0:
198 ; CHECK-NEXT: movsd %xmm1, %xmm0
198 ; CHECK-NEXT: movsd {{.*#+}} xmm0 = xmm1[0],xmm0[1]
199199 ; CHECK-NEXT: retq
200200 %1 = select <2 x i1> , <2 x i64> %a, <2 x i64> %b
201201 ret <2 x i64> %1
204204 define <4 x float> @test22(<4 x float> %a, <4 x float> %b) {
205205 ; CHECK-LABEL: test22:
206206 ; CHECK: # BB#0:
207 ; CHECK-NEXT: movss %xmm0, %xmm1
207 ; CHECK-NEXT: movss {{.*#+}} xmm1 = xmm0[0],xmm1[1,2,3]
208208 ; CHECK-NEXT: movaps %xmm1, %xmm0
209209 ; CHECK-NEXT: retq
210210 %1 = select <4 x i1> , <4 x float> %a, <4 x float> %b
214214 define <4 x i32> @test23(<4 x i32> %a, <4 x i32> %b) {
215215 ; CHECK-LABEL: test23:
216216 ; CHECK: # BB#0:
217 ; CHECK-NEXT: movss %xmm0, %xmm1
217 ; CHECK-NEXT: movss {{.*#+}} xmm1 = xmm0[0],xmm1[1,2,3]
218218 ; CHECK-NEXT: movaps %xmm1, %xmm0
219219 ; CHECK-NEXT: retq
220220 %1 = select <4 x i1> , <4 x i32> %a, <4 x i32> %b
224224 define <2 x double> @test24(<2 x double> %a, <2 x double> %b) {
225225 ; CHECK-LABEL: test24:
226226 ; CHECK: # BB#0:
227 ; CHECK-NEXT: movsd %xmm0, %xmm1
227 ; CHECK-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
228228 ; CHECK-NEXT: movaps %xmm1, %xmm0
229229 ; CHECK-NEXT: retq
230230 %1 = select <2 x i1> , <2 x double> %a, <2 x double> %b
234234 define <2 x i64> @test25(<2 x i64> %a, <2 x i64> %b) {
235235 ; CHECK-LABEL: test25:
236236 ; CHECK: # BB#0:
237 ; CHECK-NEXT: movsd %xmm0, %xmm1
237 ; CHECK-NEXT: movsd {{.*#+}} xmm1 = xmm0[0],xmm1[1]
238238 ; CHECK-NEXT: movaps %xmm1, %xmm0
239239 ; CHECK-NEXT: retq
240240 %1 = select <2 x i1> , <2 x i64> %a, <2 x i64> %b