1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=x86_64-apple-darwin -mcpu=knl -mattr=+avx512vl --show-mc-encoding| FileCheck %s
4 define <8 x i32> @test_256_1(ptr %addr) {
5 ; CHECK-LABEL: test_256_1:
7 ; CHECK-NEXT: vmovups (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x10,0x07]
8 ; CHECK-NEXT: retq ## encoding: [0xc3]
9 %res = load <8 x i32>, ptr %addr, align 1
13 define <8 x i32> @test_256_2(ptr %addr) {
14 ; CHECK-LABEL: test_256_2:
16 ; CHECK-NEXT: vmovaps (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x28,0x07]
17 ; CHECK-NEXT: retq ## encoding: [0xc3]
18 %res = load <8 x i32>, ptr %addr, align 32
22 define void @test_256_3(ptr %addr, <4 x i64> %data) {
23 ; CHECK-LABEL: test_256_3:
25 ; CHECK-NEXT: vmovaps %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x29,0x07]
26 ; CHECK-NEXT: retq ## encoding: [0xc3]
27 store <4 x i64>%data, ptr %addr, align 32
31 define void @test_256_4(ptr %addr, <8 x i32> %data) {
32 ; CHECK-LABEL: test_256_4:
34 ; CHECK-NEXT: vmovups %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x11,0x07]
35 ; CHECK-NEXT: retq ## encoding: [0xc3]
36 store <8 x i32>%data, ptr %addr, align 1
40 define void @test_256_5(ptr %addr, <8 x i32> %data) {
41 ; CHECK-LABEL: test_256_5:
43 ; CHECK-NEXT: vmovaps %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x29,0x07]
44 ; CHECK-NEXT: retq ## encoding: [0xc3]
45 store <8 x i32>%data, ptr %addr, align 32
49 define <4 x i64> @test_256_6(ptr %addr) {
50 ; CHECK-LABEL: test_256_6:
52 ; CHECK-NEXT: vmovaps (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x28,0x07]
53 ; CHECK-NEXT: retq ## encoding: [0xc3]
54 %res = load <4 x i64>, ptr %addr, align 32
58 define void @test_256_7(ptr %addr, <4 x i64> %data) {
59 ; CHECK-LABEL: test_256_7:
61 ; CHECK-NEXT: vmovups %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x11,0x07]
62 ; CHECK-NEXT: retq ## encoding: [0xc3]
63 store <4 x i64>%data, ptr %addr, align 1
67 define <4 x i64> @test_256_8(ptr %addr) {
68 ; CHECK-LABEL: test_256_8:
70 ; CHECK-NEXT: vmovups (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x10,0x07]
71 ; CHECK-NEXT: retq ## encoding: [0xc3]
72 %res = load <4 x i64>, ptr %addr, align 1
76 define void @test_256_9(ptr %addr, <4 x double> %data) {
77 ; CHECK-LABEL: test_256_9:
79 ; CHECK-NEXT: vmovaps %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x29,0x07]
80 ; CHECK-NEXT: retq ## encoding: [0xc3]
81 store <4 x double>%data, ptr %addr, align 32
85 define <4 x double> @test_256_10(ptr %addr) {
86 ; CHECK-LABEL: test_256_10:
88 ; CHECK-NEXT: vmovaps (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x28,0x07]
89 ; CHECK-NEXT: retq ## encoding: [0xc3]
90 %res = load <4 x double>, ptr %addr, align 32
94 define void @test_256_11(ptr %addr, <8 x float> %data) {
95 ; CHECK-LABEL: test_256_11:
97 ; CHECK-NEXT: vmovaps %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x29,0x07]
98 ; CHECK-NEXT: retq ## encoding: [0xc3]
99 store <8 x float>%data, ptr %addr, align 32
103 define <8 x float> @test_256_12(ptr %addr) {
104 ; CHECK-LABEL: test_256_12:
106 ; CHECK-NEXT: vmovaps (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x28,0x07]
107 ; CHECK-NEXT: retq ## encoding: [0xc3]
108 %res = load <8 x float>, ptr %addr, align 32
112 define void @test_256_13(ptr %addr, <4 x double> %data) {
113 ; CHECK-LABEL: test_256_13:
115 ; CHECK-NEXT: vmovups %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x11,0x07]
116 ; CHECK-NEXT: retq ## encoding: [0xc3]
117 store <4 x double>%data, ptr %addr, align 1
121 define <4 x double> @test_256_14(ptr %addr) {
122 ; CHECK-LABEL: test_256_14:
124 ; CHECK-NEXT: vmovups (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x10,0x07]
125 ; CHECK-NEXT: retq ## encoding: [0xc3]
126 %res = load <4 x double>, ptr %addr, align 1
130 define void @test_256_15(ptr %addr, <8 x float> %data) {
131 ; CHECK-LABEL: test_256_15:
133 ; CHECK-NEXT: vmovups %ymm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x11,0x07]
134 ; CHECK-NEXT: retq ## encoding: [0xc3]
135 store <8 x float>%data, ptr %addr, align 1
139 define <8 x float> @test_256_16(ptr %addr) {
140 ; CHECK-LABEL: test_256_16:
142 ; CHECK-NEXT: vmovups (%rdi), %ymm0 ## EVEX TO VEX Compression encoding: [0xc5,0xfc,0x10,0x07]
143 ; CHECK-NEXT: retq ## encoding: [0xc3]
144 %res = load <8 x float>, ptr %addr, align 1
148 define <8 x i32> @test_256_17(ptr %addr, <8 x i32> %old, <8 x i32> %mask1) {
149 ; CHECK-LABEL: test_256_17:
151 ; CHECK-NEXT: vptestmd %ymm1, %ymm1, %k1 ## encoding: [0x62,0xf2,0x75,0x28,0x27,0xc9]
152 ; CHECK-NEXT: vmovdqa32 (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0x7d,0x29,0x6f,0x07]
153 ; CHECK-NEXT: retq ## encoding: [0xc3]
154 %mask = icmp ne <8 x i32> %mask1, zeroinitializer
155 %r = load <8 x i32>, ptr %addr, align 32
156 %res = select <8 x i1> %mask, <8 x i32> %r, <8 x i32> %old
160 define <8 x i32> @test_256_18(ptr %addr, <8 x i32> %old, <8 x i32> %mask1) {
161 ; CHECK-LABEL: test_256_18:
163 ; CHECK-NEXT: vptestmd %ymm1, %ymm1, %k1 ## encoding: [0x62,0xf2,0x75,0x28,0x27,0xc9]
164 ; CHECK-NEXT: vmovdqu32 (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0x7e,0x29,0x6f,0x07]
165 ; CHECK-NEXT: retq ## encoding: [0xc3]
166 %mask = icmp ne <8 x i32> %mask1, zeroinitializer
167 %r = load <8 x i32>, ptr %addr, align 1
168 %res = select <8 x i1> %mask, <8 x i32> %r, <8 x i32> %old
172 define <8 x i32> @test_256_19(ptr %addr, <8 x i32> %mask1) {
173 ; CHECK-LABEL: test_256_19:
175 ; CHECK-NEXT: vptestmd %ymm0, %ymm0, %k1 ## encoding: [0x62,0xf2,0x7d,0x28,0x27,0xc8]
176 ; CHECK-NEXT: vmovdqa32 (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7d,0xa9,0x6f,0x07]
177 ; CHECK-NEXT: retq ## encoding: [0xc3]
178 %mask = icmp ne <8 x i32> %mask1, zeroinitializer
179 %r = load <8 x i32>, ptr %addr, align 32
180 %res = select <8 x i1> %mask, <8 x i32> %r, <8 x i32> zeroinitializer
184 define <8 x i32> @test_256_20(ptr %addr, <8 x i32> %mask1) {
185 ; CHECK-LABEL: test_256_20:
187 ; CHECK-NEXT: vptestmd %ymm0, %ymm0, %k1 ## encoding: [0x62,0xf2,0x7d,0x28,0x27,0xc8]
188 ; CHECK-NEXT: vmovdqu32 (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7e,0xa9,0x6f,0x07]
189 ; CHECK-NEXT: retq ## encoding: [0xc3]
190 %mask = icmp ne <8 x i32> %mask1, zeroinitializer
191 %r = load <8 x i32>, ptr %addr, align 1
192 %res = select <8 x i1> %mask, <8 x i32> %r, <8 x i32> zeroinitializer
196 define <4 x i64> @test_256_21(ptr %addr, <4 x i64> %old, <4 x i64> %mask1) {
197 ; CHECK-LABEL: test_256_21:
199 ; CHECK-NEXT: vptestmq %ymm1, %ymm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x28,0x27,0xc9]
200 ; CHECK-NEXT: vmovdqa64 (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0xfd,0x29,0x6f,0x07]
201 ; CHECK-NEXT: retq ## encoding: [0xc3]
202 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
203 %r = load <4 x i64>, ptr %addr, align 32
204 %res = select <4 x i1> %mask, <4 x i64> %r, <4 x i64> %old
208 define <4 x i64> @test_256_22(ptr %addr, <4 x i64> %old, <4 x i64> %mask1) {
209 ; CHECK-LABEL: test_256_22:
211 ; CHECK-NEXT: vptestmq %ymm1, %ymm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x28,0x27,0xc9]
212 ; CHECK-NEXT: vmovdqu64 (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0xfe,0x29,0x6f,0x07]
213 ; CHECK-NEXT: retq ## encoding: [0xc3]
214 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
215 %r = load <4 x i64>, ptr %addr, align 1
216 %res = select <4 x i1> %mask, <4 x i64> %r, <4 x i64> %old
220 define <4 x i64> @test_256_23(ptr %addr, <4 x i64> %mask1) {
221 ; CHECK-LABEL: test_256_23:
223 ; CHECK-NEXT: vptestmq %ymm0, %ymm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x28,0x27,0xc8]
224 ; CHECK-NEXT: vmovdqa64 (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfd,0xa9,0x6f,0x07]
225 ; CHECK-NEXT: retq ## encoding: [0xc3]
226 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
227 %r = load <4 x i64>, ptr %addr, align 32
228 %res = select <4 x i1> %mask, <4 x i64> %r, <4 x i64> zeroinitializer
232 define <4 x i64> @test_256_24(ptr %addr, <4 x i64> %mask1) {
233 ; CHECK-LABEL: test_256_24:
235 ; CHECK-NEXT: vptestmq %ymm0, %ymm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x28,0x27,0xc8]
236 ; CHECK-NEXT: vmovdqu64 (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfe,0xa9,0x6f,0x07]
237 ; CHECK-NEXT: retq ## encoding: [0xc3]
238 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
239 %r = load <4 x i64>, ptr %addr, align 1
240 %res = select <4 x i1> %mask, <4 x i64> %r, <4 x i64> zeroinitializer
244 define <8 x float> @test_256_25(ptr %addr, <8 x float> %old, <8 x float> %mask1) {
245 ; CHECK-LABEL: test_256_25:
247 ; CHECK-NEXT: vxorps %xmm2, %xmm2, %xmm2 ## encoding: [0xc5,0xe8,0x57,0xd2]
248 ; CHECK-NEXT: vcmpneq_oqps %ymm2, %ymm1, %k1 ## encoding: [0x62,0xf1,0x74,0x28,0xc2,0xca,0x0c]
249 ; CHECK-NEXT: vmovaps (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0x7c,0x29,0x28,0x07]
250 ; CHECK-NEXT: retq ## encoding: [0xc3]
251 %mask = fcmp one <8 x float> %mask1, zeroinitializer
252 %r = load <8 x float>, ptr %addr, align 32
253 %res = select <8 x i1> %mask, <8 x float> %r, <8 x float> %old
257 define <8 x float> @test_256_26(ptr %addr, <8 x float> %old, <8 x float> %mask1) {
258 ; CHECK-LABEL: test_256_26:
260 ; CHECK-NEXT: vxorps %xmm2, %xmm2, %xmm2 ## encoding: [0xc5,0xe8,0x57,0xd2]
261 ; CHECK-NEXT: vcmpneq_oqps %ymm2, %ymm1, %k1 ## encoding: [0x62,0xf1,0x74,0x28,0xc2,0xca,0x0c]
262 ; CHECK-NEXT: vmovups (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0x7c,0x29,0x10,0x07]
263 ; CHECK-NEXT: retq ## encoding: [0xc3]
264 %mask = fcmp one <8 x float> %mask1, zeroinitializer
265 %r = load <8 x float>, ptr %addr, align 1
266 %res = select <8 x i1> %mask, <8 x float> %r, <8 x float> %old
270 define <8 x float> @test_256_27(ptr %addr, <8 x float> %mask1) {
271 ; CHECK-LABEL: test_256_27:
273 ; CHECK-NEXT: vxorps %xmm1, %xmm1, %xmm1 ## encoding: [0xc5,0xf0,0x57,0xc9]
274 ; CHECK-NEXT: vcmpneq_oqps %ymm1, %ymm0, %k1 ## encoding: [0x62,0xf1,0x7c,0x28,0xc2,0xc9,0x0c]
275 ; CHECK-NEXT: vmovaps (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7c,0xa9,0x28,0x07]
276 ; CHECK-NEXT: retq ## encoding: [0xc3]
277 %mask = fcmp one <8 x float> %mask1, zeroinitializer
278 %r = load <8 x float>, ptr %addr, align 32
279 %res = select <8 x i1> %mask, <8 x float> %r, <8 x float> zeroinitializer
283 define <8 x float> @test_256_28(ptr %addr, <8 x float> %mask1) {
284 ; CHECK-LABEL: test_256_28:
286 ; CHECK-NEXT: vxorps %xmm1, %xmm1, %xmm1 ## encoding: [0xc5,0xf0,0x57,0xc9]
287 ; CHECK-NEXT: vcmpneq_oqps %ymm1, %ymm0, %k1 ## encoding: [0x62,0xf1,0x7c,0x28,0xc2,0xc9,0x0c]
288 ; CHECK-NEXT: vmovups (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7c,0xa9,0x10,0x07]
289 ; CHECK-NEXT: retq ## encoding: [0xc3]
290 %mask = fcmp one <8 x float> %mask1, zeroinitializer
291 %r = load <8 x float>, ptr %addr, align 1
292 %res = select <8 x i1> %mask, <8 x float> %r, <8 x float> zeroinitializer
296 define <4 x double> @test_256_29(ptr %addr, <4 x double> %old, <4 x i64> %mask1) {
297 ; CHECK-LABEL: test_256_29:
299 ; CHECK-NEXT: vptestmq %ymm1, %ymm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x28,0x27,0xc9]
300 ; CHECK-NEXT: vmovapd (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0xfd,0x29,0x28,0x07]
301 ; CHECK-NEXT: retq ## encoding: [0xc3]
302 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
303 %r = load <4 x double>, ptr %addr, align 32
304 %res = select <4 x i1> %mask, <4 x double> %r, <4 x double> %old
308 define <4 x double> @test_256_30(ptr %addr, <4 x double> %old, <4 x i64> %mask1) {
309 ; CHECK-LABEL: test_256_30:
311 ; CHECK-NEXT: vptestmq %ymm1, %ymm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x28,0x27,0xc9]
312 ; CHECK-NEXT: vmovupd (%rdi), %ymm0 {%k1} ## encoding: [0x62,0xf1,0xfd,0x29,0x10,0x07]
313 ; CHECK-NEXT: retq ## encoding: [0xc3]
314 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
315 %r = load <4 x double>, ptr %addr, align 1
316 %res = select <4 x i1> %mask, <4 x double> %r, <4 x double> %old
320 define <4 x double> @test_256_31(ptr %addr, <4 x i64> %mask1) {
321 ; CHECK-LABEL: test_256_31:
323 ; CHECK-NEXT: vptestmq %ymm0, %ymm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x28,0x27,0xc8]
324 ; CHECK-NEXT: vmovapd (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfd,0xa9,0x28,0x07]
325 ; CHECK-NEXT: retq ## encoding: [0xc3]
326 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
327 %r = load <4 x double>, ptr %addr, align 32
328 %res = select <4 x i1> %mask, <4 x double> %r, <4 x double> zeroinitializer
332 define <4 x double> @test_256_32(ptr %addr, <4 x i64> %mask1) {
333 ; CHECK-LABEL: test_256_32:
335 ; CHECK-NEXT: vptestmq %ymm0, %ymm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x28,0x27,0xc8]
336 ; CHECK-NEXT: vmovupd (%rdi), %ymm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfd,0xa9,0x10,0x07]
337 ; CHECK-NEXT: retq ## encoding: [0xc3]
338 %mask = icmp ne <4 x i64> %mask1, zeroinitializer
339 %r = load <4 x double>, ptr %addr, align 1
340 %res = select <4 x i1> %mask, <4 x double> %r, <4 x double> zeroinitializer
344 define <4 x i32> @test_128_1(ptr %addr) {
345 ; CHECK-LABEL: test_128_1:
347 ; CHECK-NEXT: vmovups (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x10,0x07]
348 ; CHECK-NEXT: retq ## encoding: [0xc3]
349 %res = load <4 x i32>, ptr %addr, align 1
353 define <4 x i32> @test_128_2(ptr %addr) {
354 ; CHECK-LABEL: test_128_2:
356 ; CHECK-NEXT: vmovaps (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x28,0x07]
357 ; CHECK-NEXT: retq ## encoding: [0xc3]
358 %res = load <4 x i32>, ptr %addr, align 16
362 define void @test_128_3(ptr %addr, <2 x i64> %data) {
363 ; CHECK-LABEL: test_128_3:
365 ; CHECK-NEXT: vmovaps %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x29,0x07]
366 ; CHECK-NEXT: retq ## encoding: [0xc3]
367 store <2 x i64>%data, ptr %addr, align 16
371 define void @test_128_4(ptr %addr, <4 x i32> %data) {
372 ; CHECK-LABEL: test_128_4:
374 ; CHECK-NEXT: vmovups %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x11,0x07]
375 ; CHECK-NEXT: retq ## encoding: [0xc3]
376 store <4 x i32>%data, ptr %addr, align 1
380 define void @test_128_5(ptr %addr, <4 x i32> %data) {
381 ; CHECK-LABEL: test_128_5:
383 ; CHECK-NEXT: vmovaps %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x29,0x07]
384 ; CHECK-NEXT: retq ## encoding: [0xc3]
385 store <4 x i32>%data, ptr %addr, align 16
389 define <2 x i64> @test_128_6(ptr %addr) {
390 ; CHECK-LABEL: test_128_6:
392 ; CHECK-NEXT: vmovaps (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x28,0x07]
393 ; CHECK-NEXT: retq ## encoding: [0xc3]
394 %res = load <2 x i64>, ptr %addr, align 16
398 define void @test_128_7(ptr %addr, <2 x i64> %data) {
399 ; CHECK-LABEL: test_128_7:
401 ; CHECK-NEXT: vmovups %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x11,0x07]
402 ; CHECK-NEXT: retq ## encoding: [0xc3]
403 store <2 x i64>%data, ptr %addr, align 1
407 define <2 x i64> @test_128_8(ptr %addr) {
408 ; CHECK-LABEL: test_128_8:
410 ; CHECK-NEXT: vmovups (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x10,0x07]
411 ; CHECK-NEXT: retq ## encoding: [0xc3]
412 %res = load <2 x i64>, ptr %addr, align 1
416 define void @test_128_9(ptr %addr, <2 x double> %data) {
417 ; CHECK-LABEL: test_128_9:
419 ; CHECK-NEXT: vmovaps %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x29,0x07]
420 ; CHECK-NEXT: retq ## encoding: [0xc3]
421 store <2 x double>%data, ptr %addr, align 16
425 define <2 x double> @test_128_10(ptr %addr) {
426 ; CHECK-LABEL: test_128_10:
428 ; CHECK-NEXT: vmovaps (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x28,0x07]
429 ; CHECK-NEXT: retq ## encoding: [0xc3]
430 %res = load <2 x double>, ptr %addr, align 16
434 define void @test_128_11(ptr %addr, <4 x float> %data) {
435 ; CHECK-LABEL: test_128_11:
437 ; CHECK-NEXT: vmovaps %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x29,0x07]
438 ; CHECK-NEXT: retq ## encoding: [0xc3]
439 store <4 x float>%data, ptr %addr, align 16
443 define <4 x float> @test_128_12(ptr %addr) {
444 ; CHECK-LABEL: test_128_12:
446 ; CHECK-NEXT: vmovaps (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x28,0x07]
447 ; CHECK-NEXT: retq ## encoding: [0xc3]
448 %res = load <4 x float>, ptr %addr, align 16
452 define void @test_128_13(ptr %addr, <2 x double> %data) {
453 ; CHECK-LABEL: test_128_13:
455 ; CHECK-NEXT: vmovups %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x11,0x07]
456 ; CHECK-NEXT: retq ## encoding: [0xc3]
457 store <2 x double>%data, ptr %addr, align 1
461 define <2 x double> @test_128_14(ptr %addr) {
462 ; CHECK-LABEL: test_128_14:
464 ; CHECK-NEXT: vmovups (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x10,0x07]
465 ; CHECK-NEXT: retq ## encoding: [0xc3]
466 %res = load <2 x double>, ptr %addr, align 1
470 define void @test_128_15(ptr %addr, <4 x float> %data) {
471 ; CHECK-LABEL: test_128_15:
473 ; CHECK-NEXT: vmovups %xmm0, (%rdi) ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x11,0x07]
474 ; CHECK-NEXT: retq ## encoding: [0xc3]
475 store <4 x float>%data, ptr %addr, align 1
479 define <4 x float> @test_128_16(ptr %addr) {
480 ; CHECK-LABEL: test_128_16:
482 ; CHECK-NEXT: vmovups (%rdi), %xmm0 ## EVEX TO VEX Compression encoding: [0xc5,0xf8,0x10,0x07]
483 ; CHECK-NEXT: retq ## encoding: [0xc3]
484 %res = load <4 x float>, ptr %addr, align 1
488 define <4 x i32> @test_128_17(ptr %addr, <4 x i32> %old, <4 x i32> %mask1) {
489 ; CHECK-LABEL: test_128_17:
491 ; CHECK-NEXT: vptestmd %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0x75,0x08,0x27,0xc9]
492 ; CHECK-NEXT: vmovdqa32 (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0x7d,0x09,0x6f,0x07]
493 ; CHECK-NEXT: retq ## encoding: [0xc3]
494 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
495 %r = load <4 x i32>, ptr %addr, align 16
496 %res = select <4 x i1> %mask, <4 x i32> %r, <4 x i32> %old
500 define <4 x i32> @test_128_18(ptr %addr, <4 x i32> %old, <4 x i32> %mask1) {
501 ; CHECK-LABEL: test_128_18:
503 ; CHECK-NEXT: vptestmd %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0x75,0x08,0x27,0xc9]
504 ; CHECK-NEXT: vmovdqu32 (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0x7e,0x09,0x6f,0x07]
505 ; CHECK-NEXT: retq ## encoding: [0xc3]
506 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
507 %r = load <4 x i32>, ptr %addr, align 1
508 %res = select <4 x i1> %mask, <4 x i32> %r, <4 x i32> %old
512 define <4 x i32> @test_128_19(ptr %addr, <4 x i32> %mask1) {
513 ; CHECK-LABEL: test_128_19:
515 ; CHECK-NEXT: vptestmd %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0x7d,0x08,0x27,0xc8]
516 ; CHECK-NEXT: vmovdqa32 (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7d,0x89,0x6f,0x07]
517 ; CHECK-NEXT: retq ## encoding: [0xc3]
518 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
519 %r = load <4 x i32>, ptr %addr, align 16
520 %res = select <4 x i1> %mask, <4 x i32> %r, <4 x i32> zeroinitializer
524 define <4 x i32> @test_128_20(ptr %addr, <4 x i32> %mask1) {
525 ; CHECK-LABEL: test_128_20:
527 ; CHECK-NEXT: vptestmd %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0x7d,0x08,0x27,0xc8]
528 ; CHECK-NEXT: vmovdqu32 (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7e,0x89,0x6f,0x07]
529 ; CHECK-NEXT: retq ## encoding: [0xc3]
530 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
531 %r = load <4 x i32>, ptr %addr, align 1
532 %res = select <4 x i1> %mask, <4 x i32> %r, <4 x i32> zeroinitializer
536 define <2 x i64> @test_128_21(ptr %addr, <2 x i64> %old, <2 x i64> %mask1) {
537 ; CHECK-LABEL: test_128_21:
539 ; CHECK-NEXT: vptestmq %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x08,0x27,0xc9]
540 ; CHECK-NEXT: vmovdqa64 (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0xfd,0x09,0x6f,0x07]
541 ; CHECK-NEXT: retq ## encoding: [0xc3]
542 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
543 %r = load <2 x i64>, ptr %addr, align 16
544 %res = select <2 x i1> %mask, <2 x i64> %r, <2 x i64> %old
548 define <2 x i64> @test_128_22(ptr %addr, <2 x i64> %old, <2 x i64> %mask1) {
549 ; CHECK-LABEL: test_128_22:
551 ; CHECK-NEXT: vptestmq %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x08,0x27,0xc9]
552 ; CHECK-NEXT: vmovdqu64 (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0xfe,0x09,0x6f,0x07]
553 ; CHECK-NEXT: retq ## encoding: [0xc3]
554 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
555 %r = load <2 x i64>, ptr %addr, align 1
556 %res = select <2 x i1> %mask, <2 x i64> %r, <2 x i64> %old
560 define <2 x i64> @test_128_23(ptr %addr, <2 x i64> %mask1) {
561 ; CHECK-LABEL: test_128_23:
563 ; CHECK-NEXT: vptestmq %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x08,0x27,0xc8]
564 ; CHECK-NEXT: vmovdqa64 (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfd,0x89,0x6f,0x07]
565 ; CHECK-NEXT: retq ## encoding: [0xc3]
566 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
567 %r = load <2 x i64>, ptr %addr, align 16
568 %res = select <2 x i1> %mask, <2 x i64> %r, <2 x i64> zeroinitializer
572 define <2 x i64> @test_128_24(ptr %addr, <2 x i64> %mask1) {
573 ; CHECK-LABEL: test_128_24:
575 ; CHECK-NEXT: vptestmq %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x08,0x27,0xc8]
576 ; CHECK-NEXT: vmovdqu64 (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfe,0x89,0x6f,0x07]
577 ; CHECK-NEXT: retq ## encoding: [0xc3]
578 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
579 %r = load <2 x i64>, ptr %addr, align 1
580 %res = select <2 x i1> %mask, <2 x i64> %r, <2 x i64> zeroinitializer
584 define <4 x float> @test_128_25(ptr %addr, <4 x float> %old, <4 x i32> %mask1) {
585 ; CHECK-LABEL: test_128_25:
587 ; CHECK-NEXT: vptestmd %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0x75,0x08,0x27,0xc9]
588 ; CHECK-NEXT: vmovaps (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0x7c,0x09,0x28,0x07]
589 ; CHECK-NEXT: retq ## encoding: [0xc3]
590 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
591 %r = load <4 x float>, ptr %addr, align 16
592 %res = select <4 x i1> %mask, <4 x float> %r, <4 x float> %old
596 define <4 x float> @test_128_26(ptr %addr, <4 x float> %old, <4 x i32> %mask1) {
597 ; CHECK-LABEL: test_128_26:
599 ; CHECK-NEXT: vptestmd %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0x75,0x08,0x27,0xc9]
600 ; CHECK-NEXT: vmovups (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0x7c,0x09,0x10,0x07]
601 ; CHECK-NEXT: retq ## encoding: [0xc3]
602 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
603 %r = load <4 x float>, ptr %addr, align 1
604 %res = select <4 x i1> %mask, <4 x float> %r, <4 x float> %old
608 define <4 x float> @test_128_27(ptr %addr, <4 x i32> %mask1) {
609 ; CHECK-LABEL: test_128_27:
611 ; CHECK-NEXT: vptestmd %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0x7d,0x08,0x27,0xc8]
612 ; CHECK-NEXT: vmovaps (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7c,0x89,0x28,0x07]
613 ; CHECK-NEXT: retq ## encoding: [0xc3]
614 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
615 %r = load <4 x float>, ptr %addr, align 16
616 %res = select <4 x i1> %mask, <4 x float> %r, <4 x float> zeroinitializer
620 define <4 x float> @test_128_28(ptr %addr, <4 x i32> %mask1) {
621 ; CHECK-LABEL: test_128_28:
623 ; CHECK-NEXT: vptestmd %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0x7d,0x08,0x27,0xc8]
624 ; CHECK-NEXT: vmovups (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0x7c,0x89,0x10,0x07]
625 ; CHECK-NEXT: retq ## encoding: [0xc3]
626 %mask = icmp ne <4 x i32> %mask1, zeroinitializer
627 %r = load <4 x float>, ptr %addr, align 1
628 %res = select <4 x i1> %mask, <4 x float> %r, <4 x float> zeroinitializer
632 define <2 x double> @test_128_29(ptr %addr, <2 x double> %old, <2 x i64> %mask1) {
633 ; CHECK-LABEL: test_128_29:
635 ; CHECK-NEXT: vptestmq %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x08,0x27,0xc9]
636 ; CHECK-NEXT: vmovapd (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0xfd,0x09,0x28,0x07]
637 ; CHECK-NEXT: retq ## encoding: [0xc3]
638 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
639 %r = load <2 x double>, ptr %addr, align 16
640 %res = select <2 x i1> %mask, <2 x double> %r, <2 x double> %old
644 define <2 x double> @test_128_30(ptr %addr, <2 x double> %old, <2 x i64> %mask1) {
645 ; CHECK-LABEL: test_128_30:
647 ; CHECK-NEXT: vptestmq %xmm1, %xmm1, %k1 ## encoding: [0x62,0xf2,0xf5,0x08,0x27,0xc9]
648 ; CHECK-NEXT: vmovupd (%rdi), %xmm0 {%k1} ## encoding: [0x62,0xf1,0xfd,0x09,0x10,0x07]
649 ; CHECK-NEXT: retq ## encoding: [0xc3]
650 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
651 %r = load <2 x double>, ptr %addr, align 1
652 %res = select <2 x i1> %mask, <2 x double> %r, <2 x double> %old
656 define <2 x double> @test_128_31(ptr %addr, <2 x i64> %mask1) {
657 ; CHECK-LABEL: test_128_31:
659 ; CHECK-NEXT: vptestmq %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x08,0x27,0xc8]
660 ; CHECK-NEXT: vmovapd (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfd,0x89,0x28,0x07]
661 ; CHECK-NEXT: retq ## encoding: [0xc3]
662 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
663 %r = load <2 x double>, ptr %addr, align 16
664 %res = select <2 x i1> %mask, <2 x double> %r, <2 x double> zeroinitializer
668 define <2 x double> @test_128_32(ptr %addr, <2 x i64> %mask1) {
669 ; CHECK-LABEL: test_128_32:
671 ; CHECK-NEXT: vptestmq %xmm0, %xmm0, %k1 ## encoding: [0x62,0xf2,0xfd,0x08,0x27,0xc8]
672 ; CHECK-NEXT: vmovupd (%rdi), %xmm0 {%k1} {z} ## encoding: [0x62,0xf1,0xfd,0x89,0x10,0x07]
673 ; CHECK-NEXT: retq ## encoding: [0xc3]
674 %mask = icmp ne <2 x i64> %mask1, zeroinitializer
675 %r = load <2 x double>, ptr %addr, align 1
676 %res = select <2 x i1> %mask, <2 x double> %r, <2 x double> zeroinitializer