1 ; RUN: llc < %s -mcpu=x86-64 -mattr=+avx512f -x86-experimental-vector-shuffle-lowering | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512F
2 ; RUN: llc < %s -mcpu=x86-64 -mattr=+avx512bw -x86-experimental-vector-shuffle-lowering | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512BW
4 target triple = "x86_64-unknown-unknown"
6 define <8 x double> @shuffle_v8f64_00000000(<8 x double> %a, <8 x double> %b) {
7 ; ALL-LABEL: @shuffle_v8f64_00000000
9 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,0]
10 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm0, %zmm0
12 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0>
13 ret <8 x double> %shuffle
16 define <8 x double> @shuffle_v8f64_00000010(<8 x double> %a, <8 x double> %b) {
17 ; ALL-LABEL: @shuffle_v8f64_00000010
19 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,0,0]
20 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,1,0]
21 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
23 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1, i32 0>
24 ret <8 x double> %shuffle
27 define <8 x double> @shuffle_v8f64_00000200(<8 x double> %a, <8 x double> %b) {
28 ; ALL-LABEL: @shuffle_v8f64_00000200
30 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,0,0]
31 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,2,0,0]
32 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
34 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 0, i32 2, i32 0, i32 0>
35 ret <8 x double> %shuffle
38 define <8 x double> @shuffle_v8f64_00003000(<8 x double> %a, <8 x double> %b) {
39 ; ALL-LABEL: @shuffle_v8f64_00003000
41 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,0,0]
42 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[3,0,0,0]
43 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
45 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 3, i32 0, i32 0, i32 0>
46 ret <8 x double> %shuffle
49 define <8 x double> @shuffle_v8f64_00040000(<8 x double> %a, <8 x double> %b) {
50 ; ALL-LABEL: @shuffle_v8f64_00040000
52 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
53 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,1,2,0]
54 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm0[0,0,0,3]
55 ; ALL-NEXT: vblendpd {{.*}} # ymm1 = ymm2[0,1,2],ymm1[3]
56 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,0]
57 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
59 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 4, i32 0, i32 0, i32 0, i32 0>
60 ret <8 x double> %shuffle
63 define <8 x double> @shuffle_v8f64_00500000(<8 x double> %a, <8 x double> %b) {
64 ; ALL-LABEL: @shuffle_v8f64_00500000
66 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
67 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,1,1,3]
68 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm0[0,0,2,0]
69 ; ALL-NEXT: vblendpd {{.*}} # ymm1 = ymm2[0,1],ymm1[2],ymm2[3]
70 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,0]
71 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
73 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 5, i32 0, i32 0, i32 0, i32 0, i32 0>
74 ret <8 x double> %shuffle
77 define <8 x double> @shuffle_v8f64_06000000(<8 x double> %a, <8 x double> %b) {
78 ; ALL-LABEL: @shuffle_v8f64_06000000
80 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
81 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,2,2,3]
82 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm0[0,1,0,0]
83 ; ALL-NEXT: vblendpd {{.*}} # ymm1 = ymm2[0],ymm1[1],ymm2[2,3]
84 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,0]
85 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
87 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 6, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0>
88 ret <8 x double> %shuffle
91 define <8 x double> @shuffle_v8f64_70000000(<8 x double> %a, <8 x double> %b) {
92 ; ALL-LABEL: @shuffle_v8f64_70000000
94 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
95 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[3,1,2,3]
96 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,0]
97 ; ALL-NEXT: vblendpd {{.*}} # ymm1 = ymm1[0],ymm0[1,2,3]
98 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
100 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 7, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0>
101 ret <8 x double> %shuffle
104 define <8 x double> @shuffle_v8f64_01014545(<8 x double> %a, <8 x double> %b) {
105 ; ALL-LABEL: @shuffle_v8f64_01014545
107 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,1,0,1]
108 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
109 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,0,1]
110 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
112 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 1, i32 0, i32 1, i32 4, i32 5, i32 4, i32 5>
113 ret <8 x double> %shuffle
116 define <8 x double> @shuffle_v8f64_00112233(<8 x double> %a, <8 x double> %b) {
117 ; ALL-LABEL: @shuffle_v8f64_00112233
119 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,1,1]
120 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,2,3,3]
121 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
123 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 1, i32 1, i32 2, i32 2, i32 3, i32 3>
124 ret <8 x double> %shuffle
127 define <8 x double> @shuffle_v8f64_00001111(<8 x double> %a, <8 x double> %b) {
128 ; ALL-LABEL: @shuffle_v8f64_00001111
130 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,0,0]
131 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[1,1,1,1]
132 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
134 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 1, i32 1, i32 1, i32 1>
135 ret <8 x double> %shuffle
138 define <8 x double> @shuffle_v8f64_81a3c5e7(<8 x double> %a, <8 x double> %b) {
139 ; ALL-LABEL: @shuffle_v8f64_81a3c5e7
141 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
142 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
143 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
144 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm1[0],ymm0[1],ymm1[2],ymm0[3]
145 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
147 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 8, i32 1, i32 10, i32 3, i32 12, i32 5, i32 14, i32 7>
148 ret <8 x double> %shuffle
151 define <8 x double> @shuffle_v8f64_08080808(<8 x double> %a, <8 x double> %b) {
152 ; ALL-LABEL: @shuffle_v8f64_08080808
154 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,0,2,0]
155 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,0,3]
156 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1],ymm0[2],ymm1[3]
157 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm0, %zmm0
159 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 8, i32 0, i32 8, i32 0, i32 8, i32 0, i32 8>
160 ret <8 x double> %shuffle
163 define <8 x double> @shuffle_v8f64_08084c4c(<8 x double> %a, <8 x double> %b) {
164 ; ALL-LABEL: @shuffle_v8f64_08084c4c
166 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
167 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm2[0,0,2,0]
168 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
169 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm3[0,1,0,3]
170 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
171 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,0,2,0]
172 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,0,3]
173 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1],ymm0[2],ymm1[3]
174 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
176 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 8, i32 0, i32 8, i32 4, i32 12, i32 4, i32 12>
177 ret <8 x double> %shuffle
180 define <8 x double> @shuffle_v8f64_8823cc67(<8 x double> %a, <8 x double> %b) {
181 ; ALL-LABEL: @shuffle_v8f64_8823cc67
183 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
184 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
185 ; ALL-NEXT: vpermilpd {{.*}} # ymm3 = ymm3[0,0,2,2]
186 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3]
187 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[0,0,2,2]
188 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm1[0,1],ymm0[2,3]
189 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
191 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 8, i32 8, i32 2, i32 3, i32 12, i32 12, i32 6, i32 7>
192 ret <8 x double> %shuffle
195 define <8 x double> @shuffle_v8f64_9832dc76(<8 x double> %a, <8 x double> %b) {
196 ; ALL-LABEL: @shuffle_v8f64_9832dc76
198 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
199 ; ALL-NEXT: vpermilpd {{.*}} # ymm2 = ymm2[0,0,3,2]
200 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
201 ; ALL-NEXT: vpermilpd {{.*}} # ymm3 = ymm3[1,0,2,2]
202 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3]
203 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[0,0,3,2]
204 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[1,0,2,2]
205 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm1[0,1],ymm0[2,3]
206 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
208 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 9, i32 8, i32 3, i32 2, i32 13, i32 12, i32 7, i32 6>
209 ret <8 x double> %shuffle
212 define <8 x double> @shuffle_v8f64_9810dc54(<8 x double> %a, <8 x double> %b) {
213 ; ALL-LABEL: @shuffle_v8f64_9810dc54
215 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
216 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm2[0,1,1,0]
217 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
218 ; ALL-NEXT: vpermilpd {{.*}} # ymm3 = ymm3[1,0,2,2]
219 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3]
220 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,1,0]
221 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[1,0,2,2]
222 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm1[0,1],ymm0[2,3]
223 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
225 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 9, i32 8, i32 1, i32 0, i32 13, i32 12, i32 5, i32 4>
226 ret <8 x double> %shuffle
229 define <8 x double> @shuffle_v8f64_08194c5d(<8 x double> %a, <8 x double> %b) {
230 ; ALL-LABEL: @shuffle_v8f64_08194c5d
232 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
233 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm2[0,0,2,1]
234 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
235 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm3[0,1,1,3]
236 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
237 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,0,2,1]
238 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,1,3]
239 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1],ymm0[2],ymm1[3]
240 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
242 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 4, i32 12, i32 5, i32 13>
243 ret <8 x double> %shuffle
246 define <8 x double> @shuffle_v8f64_2a3b6e7f(<8 x double> %a, <8 x double> %b) {
247 ; ALL-LABEL: @shuffle_v8f64_2a3b6e7f
249 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
250 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm2[0,2,2,3]
251 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm3
252 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm3[2,1,3,3]
253 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
254 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,2,2,3]
255 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,1,3,3]
256 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1],ymm0[2],ymm1[3]
257 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
259 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 2, i32 10, i32 3, i32 11, i32 6, i32 14, i32 7, i32 15>
260 ret <8 x double> %shuffle
263 define <8 x double> @shuffle_v8f64_08192a3b(<8 x double> %a, <8 x double> %b) {
264 ; ALL-LABEL: @shuffle_v8f64_08192a3b
266 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm1[0,2,2,3]
267 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm0[2,1,3,3]
268 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
269 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,0,2,1]
270 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,1,3]
271 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1],ymm0[2],ymm1[3]
272 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
274 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
275 ret <8 x double> %shuffle
278 define <8 x double> @shuffle_v8f64_08991abb(<8 x double> %a, <8 x double> %b) {
279 ; ALL-LABEL: @shuffle_v8f64_08991abb
281 ; ALL-NEXT: vpermilpd {{.*}} # ymm2 = ymm0[1,0,2,2]
282 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm1[0,2,3,3]
283 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm2[0],ymm3[1,2,3]
284 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[0,0,1,1]
285 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1,2,3]
286 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
288 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 8, i32 9, i32 9, i32 1, i32 10, i32 11, i32 11>
289 ret <8 x double> %shuffle
292 define <8 x double> @shuffle_v8f64_091b2d3f(<8 x double> %a, <8 x double> %b) {
293 ; ALL-LABEL: @shuffle_v8f64_091b2d3f
295 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
296 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm0[2,1,3,3]
297 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1],ymm3[2],ymm2[3]
298 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,1,3]
299 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1],ymm0[2],ymm1[3]
300 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
302 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 9, i32 1, i32 11, i32 2, i32 13, i32 3, i32 15>
303 ret <8 x double> %shuffle
306 define <8 x double> @shuffle_v8f64_09ab1def(<8 x double> %a, <8 x double> %b) {
307 ; ALL-LABEL: @shuffle_v8f64_09ab1def
309 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm2
310 ; ALL-NEXT: vpermilpd {{.*}} # ymm3 = ymm0[1,0,2,2]
311 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0],ymm2[1,2,3]
312 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm1[1,2,3]
313 ; ALL-NEXT: vinsertf64x4 $1, %ymm2, %zmm0, %zmm0
315 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 9, i32 10, i32 11, i32 1, i32 13, i32 14, i32 15>
316 ret <8 x double> %shuffle
319 define <8 x double> @shuffle_v8f64_00014445(<8 x double> %a, <8 x double> %b) {
320 ; ALL-LABEL: @shuffle_v8f64_00014445
322 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,0,1]
323 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
324 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,1]
325 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
327 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 1, i32 4, i32 4, i32 4, i32 5>
328 ret <8 x double> %shuffle
331 define <8 x double> @shuffle_v8f64_00204464(<8 x double> %a, <8 x double> %b) {
332 ; ALL-LABEL: @shuffle_v8f64_00204464
334 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,2,0]
335 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
336 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,2,0]
337 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
339 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 0, i32 4, i32 4, i32 6, i32 4>
340 ret <8 x double> %shuffle
343 define <8 x double> @shuffle_v8f64_03004744(<8 x double> %a, <8 x double> %b) {
344 ; ALL-LABEL: @shuffle_v8f64_03004744
346 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,3,0,0]
347 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
348 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,3,0,0]
349 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
351 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 3, i32 0, i32 0, i32 4, i32 7, i32 4, i32 4>
352 ret <8 x double> %shuffle
355 define <8 x double> @shuffle_v8f64_10005444(<8 x double> %a, <8 x double> %b) {
356 ; ALL-LABEL: @shuffle_v8f64_10005444
358 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[1,0,0,0]
359 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
360 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[1,0,0,0]
361 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
363 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 0, i32 0, i32 5, i32 4, i32 4, i32 4>
364 ret <8 x double> %shuffle
367 define <8 x double> @shuffle_v8f64_22006644(<8 x double> %a, <8 x double> %b) {
368 ; ALL-LABEL: @shuffle_v8f64_22006644
370 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[2,2,0,0]
371 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
372 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,2,0,0]
373 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
375 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 2, i32 2, i32 0, i32 0, i32 6, i32 6, i32 4, i32 4>
376 ret <8 x double> %shuffle
379 define <8 x double> @shuffle_v8f64_33307774(<8 x double> %a, <8 x double> %b) {
380 ; ALL-LABEL: @shuffle_v8f64_33307774
382 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[3,3,3,0]
383 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
384 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[3,3,3,0]
385 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
387 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 3, i32 3, i32 3, i32 0, i32 7, i32 7, i32 7, i32 4>
388 ret <8 x double> %shuffle
391 define <8 x double> @shuffle_v8f64_32107654(<8 x double> %a, <8 x double> %b) {
392 ; ALL-LABEL: @shuffle_v8f64_32107654
394 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[3,2,1,0]
395 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
396 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[3,2,1,0]
397 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
399 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 3, i32 2, i32 1, i32 0, i32 7, i32 6, i32 5, i32 4>
400 ret <8 x double> %shuffle
403 define <8 x double> @shuffle_v8f64_00234467(<8 x double> %a, <8 x double> %b) {
404 ; ALL-LABEL: @shuffle_v8f64_00234467
406 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[0,0,2,3]
407 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
408 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[0,0,2,3]
409 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
411 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 3, i32 4, i32 4, i32 6, i32 7>
412 ret <8 x double> %shuffle
415 define <8 x double> @shuffle_v8f64_00224466(<8 x double> %a, <8 x double> %b) {
416 ; ALL-LABEL: @shuffle_v8f64_00224466
418 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[0,0,2,2]
419 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
420 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[0,0,2,2]
421 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
423 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 2, i32 4, i32 4, i32 6, i32 6>
424 ret <8 x double> %shuffle
427 define <8 x double> @shuffle_v8f64_10325476(<8 x double> %a, <8 x double> %b) {
428 ; ALL-LABEL: @shuffle_v8f64_10325476
430 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,0,3,2]
431 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
432 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[1,0,3,2]
433 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
435 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 3, i32 2, i32 5, i32 4, i32 7, i32 6>
436 ret <8 x double> %shuffle
439 define <8 x double> @shuffle_v8f64_11335577(<8 x double> %a, <8 x double> %b) {
440 ; ALL-LABEL: @shuffle_v8f64_11335577
442 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,1,3,3]
443 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
444 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[1,1,3,3]
445 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
447 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 5, i32 5, i32 7, i32 7>
448 ret <8 x double> %shuffle
451 define <8 x double> @shuffle_v8f64_10235467(<8 x double> %a, <8 x double> %b) {
452 ; ALL-LABEL: @shuffle_v8f64_10235467
454 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,0,2,3]
455 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
456 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[1,0,2,3]
457 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
459 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 2, i32 3, i32 5, i32 4, i32 6, i32 7>
460 ret <8 x double> %shuffle
463 define <8 x double> @shuffle_v8f64_10225466(<8 x double> %a, <8 x double> %b) {
464 ; ALL-LABEL: @shuffle_v8f64_10225466
466 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,0,2,2]
467 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
468 ; ALL-NEXT: vpermilpd {{.*}} # ymm0 = ymm0[1,0,2,2]
469 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
471 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 2, i32 2, i32 5, i32 4, i32 6, i32 6>
472 ret <8 x double> %shuffle
475 define <8 x double> @shuffle_v8f64_00015444(<8 x double> %a, <8 x double> %b) {
476 ; ALL-LABEL: @shuffle_v8f64_00015444
478 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,0,1]
479 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
480 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[1,0,0,0]
481 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
483 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 1, i32 5, i32 4, i32 4, i32 4>
484 ret <8 x double> %shuffle
487 define <8 x double> @shuffle_v8f64_00204644(<8 x double> %a, <8 x double> %b) {
488 ; ALL-LABEL: @shuffle_v8f64_00204644
490 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,0,2,0]
491 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
492 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,2,0,0]
493 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
495 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 0, i32 4, i32 6, i32 4, i32 4>
496 ret <8 x double> %shuffle
499 define <8 x double> @shuffle_v8f64_03004474(<8 x double> %a, <8 x double> %b) {
500 ; ALL-LABEL: @shuffle_v8f64_03004474
502 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[0,3,0,0]
503 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
504 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,3,0]
505 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
507 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 3, i32 0, i32 0, i32 4, i32 4, i32 7, i32 4>
508 ret <8 x double> %shuffle
511 define <8 x double> @shuffle_v8f64_10004444(<8 x double> %a, <8 x double> %b) {
512 ; ALL-LABEL: @shuffle_v8f64_10004444
514 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[1,0,0,0]
515 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
516 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,0,0,0]
517 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
519 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 0, i32 0, i32 4, i32 4, i32 4, i32 4>
520 ret <8 x double> %shuffle
523 define <8 x double> @shuffle_v8f64_22006446(<8 x double> %a, <8 x double> %b) {
524 ; ALL-LABEL: @shuffle_v8f64_22006446
526 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[2,2,0,0]
527 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
528 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,0,0,2]
529 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
531 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 2, i32 2, i32 0, i32 0, i32 6, i32 4, i32 4, i32 6>
532 ret <8 x double> %shuffle
535 define <8 x double> @shuffle_v8f64_33307474(<8 x double> %a, <8 x double> %b) {
536 ; ALL-LABEL: @shuffle_v8f64_33307474
538 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[3,3,3,0]
539 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
540 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[3,0,3,0]
541 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
543 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 3, i32 3, i32 3, i32 0, i32 7, i32 4, i32 7, i32 4>
544 ret <8 x double> %shuffle
547 define <8 x double> @shuffle_v8f64_32104567(<8 x double> %a, <8 x double> %b) {
548 ; ALL-LABEL: @shuffle_v8f64_32104567
550 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm0[3,2,1,0]
551 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
552 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
554 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 3, i32 2, i32 1, i32 0, i32 4, i32 5, i32 6, i32 7>
555 ret <8 x double> %shuffle
558 define <8 x double> @shuffle_v8f64_00236744(<8 x double> %a, <8 x double> %b) {
559 ; ALL-LABEL: @shuffle_v8f64_00236744
561 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[0,0,2,3]
562 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
563 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,3,0,0]
564 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
566 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 3, i32 6, i32 7, i32 4, i32 4>
567 ret <8 x double> %shuffle
570 define <8 x double> @shuffle_v8f64_00226644(<8 x double> %a, <8 x double> %b) {
571 ; ALL-LABEL: @shuffle_v8f64_00226644
573 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[0,0,2,2]
574 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
575 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,2,0,0]
576 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
578 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 2, i32 6, i32 6, i32 4, i32 4>
579 ret <8 x double> %shuffle
582 define <8 x double> @shuffle_v8f64_10324567(<8 x double> %a, <8 x double> %b) {
583 ; ALL-LABEL: @shuffle_v8f64_10324567
585 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,0,3,2]
586 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
587 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
589 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 3, i32 2, i32 4, i32 5, i32 6, i32 7>
590 ret <8 x double> %shuffle
593 define <8 x double> @shuffle_v8f64_11334567(<8 x double> %a, <8 x double> %b) {
594 ; ALL-LABEL: @shuffle_v8f64_11334567
596 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,1,3,3]
597 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
598 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
600 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 4, i32 5, i32 6, i32 7>
601 ret <8 x double> %shuffle
604 define <8 x double> @shuffle_v8f64_01235467(<8 x double> %a, <8 x double> %b) {
605 ; ALL-LABEL: @shuffle_v8f64_01235467
607 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
608 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[1,0,2,3]
609 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
611 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 5, i32 4, i32 6, i32 7>
612 ret <8 x double> %shuffle
615 define <8 x double> @shuffle_v8f64_01235466(<8 x double> %a, <8 x double> %b) {
616 ; ALL-LABEL: @shuffle_v8f64_01235466
618 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
619 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[1,0,2,2]
620 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
622 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 5, i32 4, i32 6, i32 6>
623 ret <8 x double> %shuffle
626 define <8 x double> @shuffle_v8f64_002u6u44(<8 x double> %a, <8 x double> %b) {
627 ; ALL-LABEL: @shuffle_v8f64_002u6u44
629 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[0,0,2,2]
630 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
631 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,1,0,0]
632 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
634 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 undef, i32 6, i32 undef, i32 4, i32 4>
635 ret <8 x double> %shuffle
638 define <8 x double> @shuffle_v8f64_00uu66uu(<8 x double> %a, <8 x double> %b) {
639 ; ALL-LABEL: @shuffle_v8f64_00uu66uu
641 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[0,0,2,2]
642 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
643 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[2,2,2,3]
644 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
646 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 0, i32 undef, i32 undef, i32 6, i32 6, i32 undef, i32 undef>
647 ret <8 x double> %shuffle
650 define <8 x double> @shuffle_v8f64_103245uu(<8 x double> %a, <8 x double> %b) {
651 ; ALL-LABEL: @shuffle_v8f64_103245uu
653 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,0,3,2]
654 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
655 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
657 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 0, i32 3, i32 2, i32 4, i32 5, i32 undef, i32 undef>
658 ret <8 x double> %shuffle
661 define <8 x double> @shuffle_v8f64_1133uu67(<8 x double> %a, <8 x double> %b) {
662 ; ALL-LABEL: @shuffle_v8f64_1133uu67
664 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm0[1,1,3,3]
665 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm0
666 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm1, %zmm0
668 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 undef, i32 undef, i32 6, i32 7>
669 ret <8 x double> %shuffle
672 define <8 x double> @shuffle_v8f64_0uu354uu(<8 x double> %a, <8 x double> %b) {
673 ; ALL-LABEL: @shuffle_v8f64_0uu354uu
675 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
676 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[1,0,2,2]
677 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
679 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 0, i32 undef, i32 undef, i32 3, i32 5, i32 4, i32 undef, i32 undef>
680 ret <8 x double> %shuffle
683 define <8 x double> @shuffle_v8f64_uuu3uu66(<8 x double> %a, <8 x double> %b) {
684 ; ALL-LABEL: @shuffle_v8f64_uuu3uu66
686 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm1
687 ; ALL-NEXT: vpermilpd {{.*}} # ymm1 = ymm1[0,0,2,2]
688 ; ALL-NEXT: vinsertf64x4 $1, %ymm1, %zmm0, %zmm0
690 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 undef, i32 undef, i32 undef, i32 3, i32 undef, i32 undef, i32 6, i32 6>
691 ret <8 x double> %shuffle
694 define <8 x double> @shuffle_v8f64_c348cda0(<8 x double> %a, <8 x double> %b) {
695 ; ALL-LABEL: @shuffle_v8f64_c348cda0
697 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
698 ; ALL-NEXT: vpermpd {{.*}} # ymm2 = ymm2[0,1,0,3]
699 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm0[0,3,2,3]
700 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm3[0,1],ymm2[2],ymm3[3]
701 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm3
702 ; ALL-NEXT: vpermpd {{.*}} # ymm4 = ymm1[0,1,2,0]
703 ; ALL-NEXT: vblendpd {{.*}} # ymm4 = ymm3[0,1,2],ymm4[3]
704 ; ALL-NEXT: vblendpd {{.*}} # ymm2 = ymm4[0],ymm2[1,2],ymm4[3]
705 ; ALL-NEXT: vblendpd {{.*}} # ymm1 = ymm3[0,1],ymm1[2],ymm3[3]
706 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,2,0]
707 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm1[0,1,2],ymm0[3]
708 ; ALL-NEXT: vinsertf64x4 $1, %ymm0, %zmm2, %zmm0
710 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 12, i32 3, i32 4, i32 8, i32 12, i32 13, i32 10, i32 0>
711 ret <8 x double> %shuffle
714 define <8 x double> @shuffle_v8f64_f511235a(<8 x double> %a, <8 x double> %b) {
715 ; ALL-LABEL: @shuffle_v8f64_f511235a
717 ; ALL-NEXT: vextractf64x4 $1, %zmm0, %ymm2
718 ; ALL-NEXT: vpermpd {{.*}} # ymm3 = ymm2[0,1,1,3]
719 ; ALL-NEXT: vpermpd {{.*}} # ymm4 = ymm0[2,3,2,3]
720 ; ALL-NEXT: vblendpd {{.*}} # ymm3 = ymm4[0,1],ymm3[2],ymm4[3]
721 ; ALL-NEXT: vpermilpd {{.*}} # ymm4 = ymm1[0,0,2,2]
722 ; ALL-NEXT: vblendpd {{.*}} # ymm3 = ymm3[0,1,2],ymm4[3]
723 ; ALL-NEXT: vpermpd {{.*}} # ymm0 = ymm0[0,1,1,1]
724 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm0[0],ymm2[1],ymm0[2,3]
725 ; ALL-NEXT: vextractf64x4 $1, %zmm1, %ymm1
726 ; ALL-NEXT: vpermpd {{.*}} # ymm1 = ymm1[3,1,2,3]
727 ; ALL-NEXT: vblendpd {{.*}} # ymm0 = ymm1[0],ymm0[1,2,3]
728 ; ALL-NEXT: vinsertf64x4 $1, %ymm3, %zmm0, %zmm0
730 %shuffle = shufflevector <8 x double> %a, <8 x double> %b, <8 x i32> <i32 15, i32 5, i32 1, i32 1, i32 2, i32 3, i32 5, i32 10>
731 ret <8 x double> %shuffle
734 define <8 x i64> @shuffle_v8i64_00000000(<8 x i64> %a, <8 x i64> %b) {
735 ; ALL-LABEL: @shuffle_v8i64_00000000
737 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,0]
738 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm0, %zmm0
740 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0>
741 ret <8 x i64> %shuffle
744 define <8 x i64> @shuffle_v8i64_00000010(<8 x i64> %a, <8 x i64> %b) {
745 ; ALL-LABEL: @shuffle_v8i64_00000010
747 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,0,0]
748 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,1,0]
749 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
751 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1, i32 0>
752 ret <8 x i64> %shuffle
755 define <8 x i64> @shuffle_v8i64_00000200(<8 x i64> %a, <8 x i64> %b) {
756 ; ALL-LABEL: @shuffle_v8i64_00000200
758 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,0,0]
759 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,2,0,0]
760 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
762 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 0, i32 2, i32 0, i32 0>
763 ret <8 x i64> %shuffle
766 define <8 x i64> @shuffle_v8i64_00003000(<8 x i64> %a, <8 x i64> %b) {
767 ; ALL-LABEL: @shuffle_v8i64_00003000
769 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,0,0]
770 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[3,0,0,0]
771 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
773 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 3, i32 0, i32 0, i32 0>
774 ret <8 x i64> %shuffle
777 define <8 x i64> @shuffle_v8i64_00040000(<8 x i64> %a, <8 x i64> %b) {
778 ; ALL-LABEL: @shuffle_v8i64_00040000
780 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
781 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,1,2,0]
782 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm0[0,0,0,3]
783 ; ALL-NEXT: vpblendd {{.*}} # ymm1 = ymm2[0,1,2,3,4,5],ymm1[6,7]
784 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,0]
785 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
787 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 4, i32 0, i32 0, i32 0, i32 0>
788 ret <8 x i64> %shuffle
791 define <8 x i64> @shuffle_v8i64_00500000(<8 x i64> %a, <8 x i64> %b) {
792 ; ALL-LABEL: @shuffle_v8i64_00500000
794 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
795 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,1,1,3]
796 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm0[0,0,2,0]
797 ; ALL-NEXT: vpblendd {{.*}} # ymm1 = ymm2[0,1,2,3],ymm1[4,5],ymm2[6,7]
798 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,0]
799 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
801 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 5, i32 0, i32 0, i32 0, i32 0, i32 0>
802 ret <8 x i64> %shuffle
805 define <8 x i64> @shuffle_v8i64_06000000(<8 x i64> %a, <8 x i64> %b) {
806 ; ALL-LABEL: @shuffle_v8i64_06000000
808 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
809 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,2,2,3]
810 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm0[0,1,0,0]
811 ; ALL-NEXT: vpblendd {{.*}} # ymm1 = ymm2[0,1],ymm1[2,3],ymm2[4,5,6,7]
812 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,0]
813 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
815 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 6, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0>
816 ret <8 x i64> %shuffle
819 define <8 x i64> @shuffle_v8i64_70000000(<8 x i64> %a, <8 x i64> %b) {
820 ; ALL-LABEL: @shuffle_v8i64_70000000
822 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
823 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[3,1,2,3]
824 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,0]
825 ; ALL-NEXT: vpblendd {{.*}} # ymm1 = ymm1[0,1],ymm0[2,3,4,5,6,7]
826 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
828 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 7, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0>
829 ret <8 x i64> %shuffle
832 define <8 x i64> @shuffle_v8i64_01014545(<8 x i64> %a, <8 x i64> %b) {
833 ; ALL-LABEL: @shuffle_v8i64_01014545
835 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,1,0,1]
836 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
837 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,0,1]
838 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
840 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 1, i32 0, i32 1, i32 4, i32 5, i32 4, i32 5>
841 ret <8 x i64> %shuffle
844 define <8 x i64> @shuffle_v8i64_00112233(<8 x i64> %a, <8 x i64> %b) {
845 ; ALL-LABEL: @shuffle_v8i64_00112233
847 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,1,1]
848 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,2,3,3]
849 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
851 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 1, i32 1, i32 2, i32 2, i32 3, i32 3>
852 ret <8 x i64> %shuffle
855 define <8 x i64> @shuffle_v8i64_00001111(<8 x i64> %a, <8 x i64> %b) {
856 ; ALL-LABEL: @shuffle_v8i64_00001111
858 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,0,0]
859 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[1,1,1,1]
860 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
862 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 0, i32 1, i32 1, i32 1, i32 1>
863 ret <8 x i64> %shuffle
866 define <8 x i64> @shuffle_v8i64_81a3c5e7(<8 x i64> %a, <8 x i64> %b) {
867 ; ALL-LABEL: @shuffle_v8i64_81a3c5e7
869 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
870 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
871 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
872 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm1[0,1],ymm0[2,3],ymm1[4,5],ymm0[6,7]
873 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
875 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 8, i32 1, i32 10, i32 3, i32 12, i32 5, i32 14, i32 7>
876 ret <8 x i64> %shuffle
879 define <8 x i64> @shuffle_v8i64_08080808(<8 x i64> %a, <8 x i64> %b) {
880 ; ALL-LABEL: @shuffle_v8i64_08080808
882 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,0,2,0]
883 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,0,3]
884 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3],ymm0[4,5],ymm1[6,7]
885 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm0, %zmm0
887 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 8, i32 0, i32 8, i32 0, i32 8, i32 0, i32 8>
888 ret <8 x i64> %shuffle
891 define <8 x i64> @shuffle_v8i64_08084c4c(<8 x i64> %a, <8 x i64> %b) {
892 ; ALL-LABEL: @shuffle_v8i64_08084c4c
894 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
895 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm2[0,0,2,0]
896 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
897 ; ALL-NEXT: vpermq {{.*}} # ymm3 = ymm3[0,1,0,3]
898 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
899 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,0,2,0]
900 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,0,3]
901 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3],ymm0[4,5],ymm1[6,7]
902 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
904 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 8, i32 0, i32 8, i32 4, i32 12, i32 4, i32 12>
905 ret <8 x i64> %shuffle
908 define <8 x i64> @shuffle_v8i64_8823cc67(<8 x i64> %a, <8 x i64> %b) {
909 ; ALL-LABEL: @shuffle_v8i64_8823cc67
911 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
912 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
913 ; ALL-NEXT: vpshufd {{.*}} # ymm3 = ymm3[0,1,0,1,4,5,4,5]
914 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1,2,3],ymm2[4,5,6,7]
915 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm1[0,1,0,1,4,5,4,5]
916 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm1[0,1,2,3],ymm0[4,5,6,7]
917 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
919 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 8, i32 8, i32 2, i32 3, i32 12, i32 12, i32 6, i32 7>
920 ret <8 x i64> %shuffle
923 define <8 x i64> @shuffle_v8i64_9832dc76(<8 x i64> %a, <8 x i64> %b) {
924 ; ALL-LABEL: @shuffle_v8i64_9832dc76
926 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
927 ; ALL-NEXT: vpshufd {{.*}} # ymm2 = ymm2[2,3,0,1,6,7,4,5]
928 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
929 ; ALL-NEXT: vpshufd {{.*}} # ymm3 = ymm3[2,3,0,1,6,7,4,5]
930 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1,2,3],ymm2[4,5,6,7]
931 ; ALL-NEXT: vpshufd {{.*}} # ymm0 = ymm0[2,3,0,1,6,7,4,5]
932 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm1[2,3,0,1,6,7,4,5]
933 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm1[0,1,2,3],ymm0[4,5,6,7]
934 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
936 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 9, i32 8, i32 3, i32 2, i32 13, i32 12, i32 7, i32 6>
937 ret <8 x i64> %shuffle
940 define <8 x i64> @shuffle_v8i64_9810dc54(<8 x i64> %a, <8 x i64> %b) {
941 ; ALL-LABEL: @shuffle_v8i64_9810dc54
943 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm2
944 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm2[0,1,1,0]
945 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm3
946 ; ALL-NEXT: vpshufd {{.*}} # ymm3 = ymm3[2,3,0,1,6,7,4,5]
947 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1,2,3],ymm2[4,5,6,7]
948 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,1,0]
949 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm1[2,3,0,1,6,7,4,5]
950 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm1[0,1,2,3],ymm0[4,5,6,7]
951 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
953 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 9, i32 8, i32 1, i32 0, i32 13, i32 12, i32 5, i32 4>
954 ret <8 x i64> %shuffle
957 define <8 x i64> @shuffle_v8i64_08194c5d(<8 x i64> %a, <8 x i64> %b) {
958 ; ALL-LABEL: @shuffle_v8i64_08194c5d
960 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
961 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm2[0,0,2,1]
962 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
963 ; ALL-NEXT: vpermq {{.*}} # ymm3 = ymm3[0,1,1,3]
964 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
965 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,0,2,1]
966 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,1,3]
967 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3],ymm0[4,5],ymm1[6,7]
968 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
970 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 4, i32 12, i32 5, i32 13>
971 ret <8 x i64> %shuffle
974 define <8 x i64> @shuffle_v8i64_2a3b6e7f(<8 x i64> %a, <8 x i64> %b) {
975 ; ALL-LABEL: @shuffle_v8i64_2a3b6e7f
977 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
978 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm2[0,2,2,3]
979 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm3
980 ; ALL-NEXT: vpermq {{.*}} # ymm3 = ymm3[2,1,3,3]
981 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
982 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,2,2,3]
983 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,1,3,3]
984 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3],ymm0[4,5],ymm1[6,7]
985 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
987 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 2, i32 10, i32 3, i32 11, i32 6, i32 14, i32 7, i32 15>
988 ret <8 x i64> %shuffle
991 define <8 x i64> @shuffle_v8i64_08192a3b(<8 x i64> %a, <8 x i64> %b) {
992 ; ALL-LABEL: @shuffle_v8i64_08192a3b
994 ; ALL-NEXT: vpermq {{.*}} # ymm2 = ymm1[0,2,2,3]
995 ; ALL-NEXT: vpermq {{.*}} # ymm3 = ymm0[2,1,3,3]
996 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
997 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,0,2,1]
998 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,1,3]
999 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3],ymm0[4,5],ymm1[6,7]
1000 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
1002 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
1003 ret <8 x i64> %shuffle
1006 define <8 x i64> @shuffle_v8i64_08991abb(<8 x i64> %a, <8 x i64> %b) {
1007 ; ALL-LABEL: @shuffle_v8i64_08991abb
1009 ; ALL-NEXT: vpshufd {{.*}} # ymm2 = ymm0[2,3,2,3,6,7,6,7]
1010 ; ALL-NEXT: vpermq {{.*}} # ymm3 = ymm1[0,2,3,3]
1011 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm2[0,1],ymm3[2,3,4,5,6,7]
1012 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[0,0,1,1]
1013 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3,4,5,6,7]
1014 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
1016 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 8, i32 9, i32 9, i32 1, i32 10, i32 11, i32 11>
1017 ret <8 x i64> %shuffle
1020 define <8 x i64> @shuffle_v8i64_091b2d3f(<8 x i64> %a, <8 x i64> %b) {
1021 ; ALL-LABEL: @shuffle_v8i64_091b2d3f
1023 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
1024 ; ALL-NEXT: vpermq {{.*}} # ymm3 = ymm0[2,1,3,3]
1025 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3],ymm3[4,5],ymm2[6,7]
1026 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,1,1,3]
1027 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3],ymm0[4,5],ymm1[6,7]
1028 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
1030 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 9, i32 1, i32 11, i32 2, i32 13, i32 3, i32 15>
1031 ret <8 x i64> %shuffle
1034 define <8 x i64> @shuffle_v8i64_09ab1def(<8 x i64> %a, <8 x i64> %b) {
1035 ; ALL-LABEL: @shuffle_v8i64_09ab1def
1037 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
1038 ; ALL-NEXT: vpshufd {{.*}} # ymm3 = ymm0[2,3,2,3,6,7,6,7]
1039 ; ALL-NEXT: vpblendd {{.*}} # ymm2 = ymm3[0,1],ymm2[2,3,4,5,6,7]
1040 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3,4,5,6,7]
1041 ; ALL-NEXT: vinserti64x4 $1, %ymm2, %zmm0, %zmm0
1043 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 9, i32 10, i32 11, i32 1, i32 13, i32 14, i32 15>
1044 ret <8 x i64> %shuffle
1047 define <8 x i64> @shuffle_v8i64_00014445(<8 x i64> %a, <8 x i64> %b) {
1048 ; ALL-LABEL: @shuffle_v8i64_00014445
1050 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,0,1]
1051 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1052 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,1]
1053 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1055 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 1, i32 4, i32 4, i32 4, i32 5>
1056 ret <8 x i64> %shuffle
1059 define <8 x i64> @shuffle_v8i64_00204464(<8 x i64> %a, <8 x i64> %b) {
1060 ; ALL-LABEL: @shuffle_v8i64_00204464
1062 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,2,0]
1063 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1064 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,2,0]
1065 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1067 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 0, i32 4, i32 4, i32 6, i32 4>
1068 ret <8 x i64> %shuffle
1071 define <8 x i64> @shuffle_v8i64_03004744(<8 x i64> %a, <8 x i64> %b) {
1072 ; ALL-LABEL: @shuffle_v8i64_03004744
1074 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,3,0,0]
1075 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1076 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,3,0,0]
1077 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1079 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 3, i32 0, i32 0, i32 4, i32 7, i32 4, i32 4>
1080 ret <8 x i64> %shuffle
1083 define <8 x i64> @shuffle_v8i64_10005444(<8 x i64> %a, <8 x i64> %b) {
1084 ; ALL-LABEL: @shuffle_v8i64_10005444
1086 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[1,0,0,0]
1087 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1088 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[1,0,0,0]
1089 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1091 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 0, i32 0, i32 5, i32 4, i32 4, i32 4>
1092 ret <8 x i64> %shuffle
1095 define <8 x i64> @shuffle_v8i64_22006644(<8 x i64> %a, <8 x i64> %b) {
1096 ; ALL-LABEL: @shuffle_v8i64_22006644
1098 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[2,2,0,0]
1099 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1100 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,2,0,0]
1101 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1103 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 2, i32 2, i32 0, i32 0, i32 6, i32 6, i32 4, i32 4>
1104 ret <8 x i64> %shuffle
1107 define <8 x i64> @shuffle_v8i64_33307774(<8 x i64> %a, <8 x i64> %b) {
1108 ; ALL-LABEL: @shuffle_v8i64_33307774
1110 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[3,3,3,0]
1111 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1112 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[3,3,3,0]
1113 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1115 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 3, i32 3, i32 3, i32 0, i32 7, i32 7, i32 7, i32 4>
1116 ret <8 x i64> %shuffle
1119 define <8 x i64> @shuffle_v8i64_32107654(<8 x i64> %a, <8 x i64> %b) {
1120 ; ALL-LABEL: @shuffle_v8i64_32107654
1122 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[3,2,1,0]
1123 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1124 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[3,2,1,0]
1125 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1127 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 3, i32 2, i32 1, i32 0, i32 7, i32 6, i32 5, i32 4>
1128 ret <8 x i64> %shuffle
1131 define <8 x i64> @shuffle_v8i64_00234467(<8 x i64> %a, <8 x i64> %b) {
1132 ; ALL-LABEL: @shuffle_v8i64_00234467
1134 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,2,3]
1135 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1136 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,2,3]
1137 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1139 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 3, i32 4, i32 4, i32 6, i32 7>
1140 ret <8 x i64> %shuffle
1143 define <8 x i64> @shuffle_v8i64_00224466(<8 x i64> %a, <8 x i64> %b) {
1144 ; ALL-LABEL: @shuffle_v8i64_00224466
1146 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[0,1,0,1,4,5,4,5]
1147 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1148 ; ALL-NEXT: vpshufd {{.*}} # ymm0 = ymm0[0,1,0,1,4,5,4,5]
1149 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1151 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 2, i32 4, i32 4, i32 6, i32 6>
1152 ret <8 x i64> %shuffle
1155 define <8 x i64> @shuffle_v8i64_10325476(<8 x i64> %a, <8 x i64> %b) {
1156 ; ALL-LABEL: @shuffle_v8i64_10325476
1158 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[2,3,0,1,6,7,4,5]
1159 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1160 ; ALL-NEXT: vpshufd {{.*}} # ymm0 = ymm0[2,3,0,1,6,7,4,5]
1161 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1163 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 3, i32 2, i32 5, i32 4, i32 7, i32 6>
1164 ret <8 x i64> %shuffle
1167 define <8 x i64> @shuffle_v8i64_11335577(<8 x i64> %a, <8 x i64> %b) {
1168 ; ALL-LABEL: @shuffle_v8i64_11335577
1170 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[2,3,2,3,6,7,6,7]
1171 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1172 ; ALL-NEXT: vpshufd {{.*}} # ymm0 = ymm0[2,3,2,3,6,7,6,7]
1173 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1175 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 5, i32 5, i32 7, i32 7>
1176 ret <8 x i64> %shuffle
1179 define <8 x i64> @shuffle_v8i64_10235467(<8 x i64> %a, <8 x i64> %b) {
1180 ; ALL-LABEL: @shuffle_v8i64_10235467
1182 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[1,0,2,3]
1183 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1184 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[1,0,2,3]
1185 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1187 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 2, i32 3, i32 5, i32 4, i32 6, i32 7>
1188 ret <8 x i64> %shuffle
1191 define <8 x i64> @shuffle_v8i64_10225466(<8 x i64> %a, <8 x i64> %b) {
1192 ; ALL-LABEL: @shuffle_v8i64_10225466
1194 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[1,0,2,2]
1195 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1196 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[1,0,2,2]
1197 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1199 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 2, i32 2, i32 5, i32 4, i32 6, i32 6>
1200 ret <8 x i64> %shuffle
1203 define <8 x i64> @shuffle_v8i64_00015444(<8 x i64> %a, <8 x i64> %b) {
1204 ; ALL-LABEL: @shuffle_v8i64_00015444
1206 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,0,1]
1207 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1208 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[1,0,0,0]
1209 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1211 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 0, i32 1, i32 5, i32 4, i32 4, i32 4>
1212 ret <8 x i64> %shuffle
1215 define <8 x i64> @shuffle_v8i64_00204644(<8 x i64> %a, <8 x i64> %b) {
1216 ; ALL-LABEL: @shuffle_v8i64_00204644
1218 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,2,0]
1219 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1220 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,2,0,0]
1221 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1223 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 0, i32 4, i32 6, i32 4, i32 4>
1224 ret <8 x i64> %shuffle
1227 define <8 x i64> @shuffle_v8i64_03004474(<8 x i64> %a, <8 x i64> %b) {
1228 ; ALL-LABEL: @shuffle_v8i64_03004474
1230 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,3,0,0]
1231 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1232 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,3,0]
1233 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1235 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 3, i32 0, i32 0, i32 4, i32 4, i32 7, i32 4>
1236 ret <8 x i64> %shuffle
1239 define <8 x i64> @shuffle_v8i64_10004444(<8 x i64> %a, <8 x i64> %b) {
1240 ; ALL-LABEL: @shuffle_v8i64_10004444
1242 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[1,0,0,0]
1243 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1244 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[0,0,0,0]
1245 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1247 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 0, i32 0, i32 4, i32 4, i32 4, i32 4>
1248 ret <8 x i64> %shuffle
1251 define <8 x i64> @shuffle_v8i64_22006446(<8 x i64> %a, <8 x i64> %b) {
1252 ; ALL-LABEL: @shuffle_v8i64_22006446
1254 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[2,2,0,0]
1255 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1256 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,0,0,2]
1257 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1259 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 2, i32 2, i32 0, i32 0, i32 6, i32 4, i32 4, i32 6>
1260 ret <8 x i64> %shuffle
1263 define <8 x i64> @shuffle_v8i64_33307474(<8 x i64> %a, <8 x i64> %b) {
1264 ; ALL-LABEL: @shuffle_v8i64_33307474
1266 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[3,3,3,0]
1267 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1268 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[3,0,3,0]
1269 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1271 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 3, i32 3, i32 3, i32 0, i32 7, i32 4, i32 7, i32 4>
1272 ret <8 x i64> %shuffle
1275 define <8 x i64> @shuffle_v8i64_32104567(<8 x i64> %a, <8 x i64> %b) {
1276 ; ALL-LABEL: @shuffle_v8i64_32104567
1278 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[3,2,1,0]
1279 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1280 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1282 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 3, i32 2, i32 1, i32 0, i32 4, i32 5, i32 6, i32 7>
1283 ret <8 x i64> %shuffle
1286 define <8 x i64> @shuffle_v8i64_00236744(<8 x i64> %a, <8 x i64> %b) {
1287 ; ALL-LABEL: @shuffle_v8i64_00236744
1289 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm0[0,0,2,3]
1290 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1291 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,3,0,0]
1292 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1294 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 3, i32 6, i32 7, i32 4, i32 4>
1295 ret <8 x i64> %shuffle
1298 define <8 x i64> @shuffle_v8i64_00226644(<8 x i64> %a, <8 x i64> %b) {
1299 ; ALL-LABEL: @shuffle_v8i64_00226644
1301 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[0,1,0,1,4,5,4,5]
1302 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1303 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,2,0,0]
1304 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1306 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 2, i32 6, i32 6, i32 4, i32 4>
1307 ret <8 x i64> %shuffle
1310 define <8 x i64> @shuffle_v8i64_10324567(<8 x i64> %a, <8 x i64> %b) {
1311 ; ALL-LABEL: @shuffle_v8i64_10324567
1313 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[2,3,0,1,6,7,4,5]
1314 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1315 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1317 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 3, i32 2, i32 4, i32 5, i32 6, i32 7>
1318 ret <8 x i64> %shuffle
1321 define <8 x i64> @shuffle_v8i64_11334567(<8 x i64> %a, <8 x i64> %b) {
1322 ; ALL-LABEL: @shuffle_v8i64_11334567
1324 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[2,3,2,3,6,7,6,7]
1325 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1326 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1328 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 4, i32 5, i32 6, i32 7>
1329 ret <8 x i64> %shuffle
1332 define <8 x i64> @shuffle_v8i64_01235467(<8 x i64> %a, <8 x i64> %b) {
1333 ; ALL-LABEL: @shuffle_v8i64_01235467
1335 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1336 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[1,0,2,3]
1337 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
1339 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 5, i32 4, i32 6, i32 7>
1340 ret <8 x i64> %shuffle
1343 define <8 x i64> @shuffle_v8i64_01235466(<8 x i64> %a, <8 x i64> %b) {
1344 ; ALL-LABEL: @shuffle_v8i64_01235466
1346 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1347 ; ALL-NEXT: vpermq {{.*}} # ymm1 = ymm1[1,0,2,2]
1348 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
1350 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 5, i32 4, i32 6, i32 6>
1351 ret <8 x i64> %shuffle
1354 define <8 x i64> @shuffle_v8i64_002u6u44(<8 x i64> %a, <8 x i64> %b) {
1355 ; ALL-LABEL: @shuffle_v8i64_002u6u44
1357 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[0,1,0,1,4,5,4,5]
1358 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1359 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,1,0,0]
1360 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1362 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 2, i32 undef, i32 6, i32 undef, i32 4, i32 4>
1363 ret <8 x i64> %shuffle
1366 define <8 x i64> @shuffle_v8i64_00uu66uu(<8 x i64> %a, <8 x i64> %b) {
1367 ; ALL-LABEL: @shuffle_v8i64_00uu66uu
1369 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[0,1,0,1,4,5,4,5]
1370 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1371 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,2,2,3]
1372 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1374 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 0, i32 undef, i32 undef, i32 6, i32 6, i32 undef, i32 undef>
1375 ret <8 x i64> %shuffle
1378 define <8 x i64> @shuffle_v8i64_103245uu(<8 x i64> %a, <8 x i64> %b) {
1379 ; ALL-LABEL: @shuffle_v8i64_103245uu
1381 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[2,3,0,1,6,7,4,5]
1382 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1383 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1385 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 0, i32 3, i32 2, i32 4, i32 5, i32 undef, i32 undef>
1386 ret <8 x i64> %shuffle
1389 define <8 x i64> @shuffle_v8i64_1133uu67(<8 x i64> %a, <8 x i64> %b) {
1390 ; ALL-LABEL: @shuffle_v8i64_1133uu67
1392 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm0[2,3,2,3,6,7,6,7]
1393 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1394 ; ALL-NEXT: vinserti64x4 $1, %ymm0, %zmm1, %zmm0
1396 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 undef, i32 undef, i32 6, i32 7>
1397 ret <8 x i64> %shuffle
1400 define <8 x i64> @shuffle_v8i64_0uu354uu(<8 x i64> %a, <8 x i64> %b) {
1401 ; ALL-LABEL: @shuffle_v8i64_0uu354uu
1403 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1404 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm1[2,3,0,1,6,7,4,5]
1405 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
1407 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 0, i32 undef, i32 undef, i32 3, i32 5, i32 4, i32 undef, i32 undef>
1408 ret <8 x i64> %shuffle
1411 define <8 x i64> @shuffle_v8i64_uuu3uu66(<8 x i64> %a, <8 x i64> %b) {
1412 ; ALL-LABEL: @shuffle_v8i64_uuu3uu66
1414 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm1
1415 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm1[0,1,0,1,4,5,4,5]
1416 ; ALL-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
1418 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 undef, i32 undef, i32 undef, i32 3, i32 undef, i32 undef, i32 6, i32 6>
1419 ret <8 x i64> %shuffle
1422 define <8 x i64> @shuffle_v8i64_6caa87e5(<8 x i64> %a, <8 x i64> %b) {
1423 ; ALL-LABEL: @shuffle_v8i64_6caa87e5
1425 ; ALL-NEXT: vextracti64x4 $1, %zmm1, %ymm2
1426 ; ALL-NEXT: vpblendd {{.*}} # ymm3 = ymm1[0,1,2,3],ymm2[4,5],ymm1[6,7]
1427 ; ALL-NEXT: vextracti64x4 $1, %zmm0, %ymm0
1428 ; ALL-NEXT: vpermq {{.*}} # ymm4 = ymm0[0,3,2,1]
1429 ; ALL-NEXT: vpblendd {{.*}} # ymm3 = ymm3[0,1],ymm4[2,3],ymm3[4,5],ymm4[6,7]
1430 ; ALL-NEXT: vpshufd {{.*}} # ymm2 = ymm2[0,1,0,1,4,5,4,5]
1431 ; ALL-NEXT: vpshufd {{.*}} # ymm1 = ymm1[0,1,0,1,4,5,4,5]
1432 ; ALL-NEXT: vpblendd {{.*}} # ymm1 = ymm1[0,1],ymm2[2,3],ymm1[4,5,6,7]
1433 ; ALL-NEXT: vpermq {{.*}} # ymm0 = ymm0[2,1,2,3]
1434 ; ALL-NEXT: vpblendd {{.*}} # ymm0 = ymm0[0,1],ymm1[2,3,4,5,6,7]
1435 ; ALL-NEXT: vinserti64x4 $1, %ymm3, %zmm0, %zmm0
1437 %shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 6, i32 12, i32 10, i32 10, i32 8, i32 7, i32 14, i32 5>
1438 ret <8 x i64> %shuffle