1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mattr=+sve -force-streaming-compatible-sve < %s | FileCheck %s
5 target triple = "aarch64-unknown-linux-gnu"
7 define void @zip1_v32i8(ptr %a, ptr %b) {
8 ; CHECK-LABEL: zip1_v32i8:
10 ; CHECK-NEXT: sub sp, sp, #16
11 ; CHECK-NEXT: .cfi_def_cfa_offset 16
12 ; CHECK-NEXT: ldr q0, [x0, #16]
13 ; CHECK-NEXT: ldr q0, [x0]
14 ; CHECK-NEXT: ldr q1, [x1, #16]
15 ; CHECK-NEXT: ldr q1, [x1]
16 ; CHECK-NEXT: mov z2.b, z0.b[15]
17 ; CHECK-NEXT: mov z3.b, z0.b[14]
18 ; CHECK-NEXT: mov z4.b, z0.b[13]
19 ; CHECK-NEXT: fmov w8, s2
20 ; CHECK-NEXT: mov z2.b, z0.b[12]
21 ; CHECK-NEXT: strb w8, [sp, #14]
22 ; CHECK-NEXT: fmov w8, s3
23 ; CHECK-NEXT: mov z3.b, z0.b[11]
24 ; CHECK-NEXT: strb w8, [sp, #12]
25 ; CHECK-NEXT: fmov w8, s4
26 ; CHECK-NEXT: mov z4.b, z0.b[10]
27 ; CHECK-NEXT: strb w8, [sp, #10]
28 ; CHECK-NEXT: fmov w8, s2
29 ; CHECK-NEXT: mov z2.b, z0.b[9]
30 ; CHECK-NEXT: strb w8, [sp, #8]
31 ; CHECK-NEXT: fmov w8, s3
32 ; CHECK-NEXT: mov z3.b, z0.b[8]
33 ; CHECK-NEXT: zip1 z0.b, z0.b, z1.b
34 ; CHECK-NEXT: strb w8, [sp, #6]
35 ; CHECK-NEXT: fmov w8, s4
36 ; CHECK-NEXT: mov z4.b, z1.b[15]
37 ; CHECK-NEXT: strb w8, [sp, #4]
38 ; CHECK-NEXT: fmov w8, s2
39 ; CHECK-NEXT: mov z2.b, z1.b[14]
40 ; CHECK-NEXT: strb w8, [sp, #2]
41 ; CHECK-NEXT: fmov w8, s3
42 ; CHECK-NEXT: mov z3.b, z1.b[13]
43 ; CHECK-NEXT: strb w8, [sp]
44 ; CHECK-NEXT: fmov w8, s4
45 ; CHECK-NEXT: mov z4.b, z1.b[12]
46 ; CHECK-NEXT: strb w8, [sp, #15]
47 ; CHECK-NEXT: fmov w8, s2
48 ; CHECK-NEXT: mov z2.b, z1.b[11]
49 ; CHECK-NEXT: strb w8, [sp, #13]
50 ; CHECK-NEXT: fmov w8, s3
51 ; CHECK-NEXT: mov z3.b, z1.b[10]
52 ; CHECK-NEXT: strb w8, [sp, #11]
53 ; CHECK-NEXT: fmov w8, s4
54 ; CHECK-NEXT: mov z4.b, z1.b[9]
55 ; CHECK-NEXT: strb w8, [sp, #9]
56 ; CHECK-NEXT: fmov w8, s2
57 ; CHECK-NEXT: mov z2.b, z1.b[8]
58 ; CHECK-NEXT: strb w8, [sp, #7]
59 ; CHECK-NEXT: fmov w8, s3
60 ; CHECK-NEXT: strb w8, [sp, #5]
61 ; CHECK-NEXT: fmov w8, s4
62 ; CHECK-NEXT: strb w8, [sp, #3]
63 ; CHECK-NEXT: fmov w8, s2
64 ; CHECK-NEXT: strb w8, [sp, #1]
65 ; CHECK-NEXT: ldr q1, [sp]
66 ; CHECK-NEXT: str q0, [x0]
67 ; CHECK-NEXT: str q1, [x0, #16]
68 ; CHECK-NEXT: add sp, sp, #16
70 %tmp1 = load volatile <32 x i8>, ptr %a
71 %tmp2 = load volatile <32 x i8>, ptr %b
72 %tmp3 = shufflevector <32 x i8> %tmp1, <32 x i8> %tmp2, <32 x i32> <i32 0, i32 32, i32 1, i32 33, i32 2, i32 34, i32 3, i32 35, i32 4, i32 36, i32 5, i32 37, i32 6, i32 38, i32 7, i32 39, i32 8, i32 40, i32 9, i32 41, i32 10, i32 42, i32 11, i32 43, i32 12, i32 44, i32 13, i32 45, i32 14, i32 46, i32 15, i32 47>
73 store volatile <32 x i8> %tmp3, ptr %a
77 define void @zip_v32i16(ptr %a, ptr %b) {
78 ; CHECK-LABEL: zip_v32i16:
80 ; CHECK-NEXT: sub sp, sp, #64
81 ; CHECK-NEXT: .cfi_def_cfa_offset 64
82 ; CHECK-NEXT: ldp q1, q3, [x1]
83 ; CHECK-NEXT: ldp q0, q4, [x0]
84 ; CHECK-NEXT: ldp q2, q5, [x0, #32]
85 ; CHECK-NEXT: mov z16.h, z3.h[7]
86 ; CHECK-NEXT: mov z18.h, z3.h[6]
87 ; CHECK-NEXT: mov z17.h, z4.h[7]
88 ; CHECK-NEXT: ldp q6, q7, [x1, #32]
89 ; CHECK-NEXT: mov z19.h, z4.h[6]
90 ; CHECK-NEXT: fmov w8, s16
91 ; CHECK-NEXT: mov z16.h, z3.h[5]
92 ; CHECK-NEXT: strh w8, [sp, #30]
93 ; CHECK-NEXT: fmov w8, s17
94 ; CHECK-NEXT: mov z17.h, z4.h[5]
95 ; CHECK-NEXT: strh w8, [sp, #28]
96 ; CHECK-NEXT: fmov w8, s18
97 ; CHECK-NEXT: mov z18.h, z3.h[4]
98 ; CHECK-NEXT: zip1 z3.h, z4.h, z3.h
99 ; CHECK-NEXT: strh w8, [sp, #26]
100 ; CHECK-NEXT: fmov w8, s19
101 ; CHECK-NEXT: mov z19.h, z7.h[6]
102 ; CHECK-NEXT: strh w8, [sp, #24]
103 ; CHECK-NEXT: fmov w8, s16
104 ; CHECK-NEXT: mov z16.h, z4.h[4]
105 ; CHECK-NEXT: zip1 z4.h, z5.h, z7.h
106 ; CHECK-NEXT: strh w8, [sp, #22]
107 ; CHECK-NEXT: fmov w8, s17
108 ; CHECK-NEXT: mov z17.h, z1.h[7]
109 ; CHECK-NEXT: add z3.h, z3.h, z4.h
110 ; CHECK-NEXT: strh w8, [sp, #20]
111 ; CHECK-NEXT: fmov w8, s18
112 ; CHECK-NEXT: mov z18.h, z0.h[7]
113 ; CHECK-NEXT: strh w8, [sp, #18]
114 ; CHECK-NEXT: fmov w8, s16
115 ; CHECK-NEXT: mov z16.h, z1.h[6]
116 ; CHECK-NEXT: strh w8, [sp, #16]
117 ; CHECK-NEXT: fmov w8, s17
118 ; CHECK-NEXT: mov z17.h, z0.h[6]
119 ; CHECK-NEXT: strh w8, [sp, #62]
120 ; CHECK-NEXT: fmov w8, s18
121 ; CHECK-NEXT: mov z18.h, z1.h[5]
122 ; CHECK-NEXT: strh w8, [sp, #60]
123 ; CHECK-NEXT: fmov w8, s16
124 ; CHECK-NEXT: mov z16.h, z0.h[5]
125 ; CHECK-NEXT: strh w8, [sp, #58]
126 ; CHECK-NEXT: fmov w8, s17
127 ; CHECK-NEXT: mov z17.h, z1.h[4]
128 ; CHECK-NEXT: strh w8, [sp, #56]
129 ; CHECK-NEXT: fmov w8, s18
130 ; CHECK-NEXT: mov z18.h, z0.h[4]
131 ; CHECK-NEXT: zip1 z0.h, z0.h, z1.h
132 ; CHECK-NEXT: zip1 z1.h, z2.h, z6.h
133 ; CHECK-NEXT: strh w8, [sp, #54]
134 ; CHECK-NEXT: fmov w8, s16
135 ; CHECK-NEXT: mov z16.h, z7.h[7]
136 ; CHECK-NEXT: add z0.h, z0.h, z1.h
137 ; CHECK-NEXT: strh w8, [sp, #52]
138 ; CHECK-NEXT: fmov w8, s17
139 ; CHECK-NEXT: mov z17.h, z5.h[7]
140 ; CHECK-NEXT: strh w8, [sp, #50]
141 ; CHECK-NEXT: fmov w8, s18
142 ; CHECK-NEXT: ldr q18, [sp, #16]
143 ; CHECK-NEXT: strh w8, [sp, #48]
144 ; CHECK-NEXT: fmov w8, s16
145 ; CHECK-NEXT: mov z16.h, z5.h[6]
146 ; CHECK-NEXT: ldr q20, [sp, #48]
147 ; CHECK-NEXT: strh w8, [sp, #46]
148 ; CHECK-NEXT: fmov w8, s17
149 ; CHECK-NEXT: mov z17.h, z7.h[5]
150 ; CHECK-NEXT: strh w8, [sp, #44]
151 ; CHECK-NEXT: fmov w8, s19
152 ; CHECK-NEXT: mov z19.h, z5.h[5]
153 ; CHECK-NEXT: strh w8, [sp, #42]
154 ; CHECK-NEXT: fmov w8, s16
155 ; CHECK-NEXT: mov z16.h, z7.h[4]
156 ; CHECK-NEXT: strh w8, [sp, #40]
157 ; CHECK-NEXT: fmov w8, s17
158 ; CHECK-NEXT: mov z17.h, z5.h[4]
159 ; CHECK-NEXT: strh w8, [sp, #38]
160 ; CHECK-NEXT: fmov w8, s19
161 ; CHECK-NEXT: mov z19.h, z6.h[7]
162 ; CHECK-NEXT: strh w8, [sp, #36]
163 ; CHECK-NEXT: fmov w8, s16
164 ; CHECK-NEXT: mov z16.h, z2.h[7]
165 ; CHECK-NEXT: strh w8, [sp, #34]
166 ; CHECK-NEXT: fmov w8, s17
167 ; CHECK-NEXT: mov z17.h, z6.h[6]
168 ; CHECK-NEXT: strh w8, [sp, #32]
169 ; CHECK-NEXT: fmov w8, s19
170 ; CHECK-NEXT: mov z19.h, z2.h[6]
171 ; CHECK-NEXT: strh w8, [sp, #14]
172 ; CHECK-NEXT: fmov w8, s16
173 ; CHECK-NEXT: mov z16.h, z6.h[5]
174 ; CHECK-NEXT: strh w8, [sp, #12]
175 ; CHECK-NEXT: fmov w8, s17
176 ; CHECK-NEXT: mov z17.h, z2.h[5]
177 ; CHECK-NEXT: strh w8, [sp, #10]
178 ; CHECK-NEXT: fmov w8, s19
179 ; CHECK-NEXT: mov z19.h, z6.h[4]
180 ; CHECK-NEXT: strh w8, [sp, #8]
181 ; CHECK-NEXT: fmov w8, s16
182 ; CHECK-NEXT: mov z16.h, z2.h[4]
183 ; CHECK-NEXT: ldr q2, [sp, #32]
184 ; CHECK-NEXT: strh w8, [sp, #6]
185 ; CHECK-NEXT: fmov w8, s17
186 ; CHECK-NEXT: add z2.h, z18.h, z2.h
187 ; CHECK-NEXT: strh w8, [sp, #4]
188 ; CHECK-NEXT: fmov w8, s19
189 ; CHECK-NEXT: strh w8, [sp, #2]
190 ; CHECK-NEXT: fmov w8, s16
191 ; CHECK-NEXT: strh w8, [sp]
192 ; CHECK-NEXT: ldr q4, [sp]
193 ; CHECK-NEXT: stp q3, q2, [x0, #32]
194 ; CHECK-NEXT: add z1.h, z20.h, z4.h
195 ; CHECK-NEXT: stp q0, q1, [x0]
196 ; CHECK-NEXT: add sp, sp, #64
198 %tmp1 = load <32 x i16>, ptr %a
199 %tmp2 = load <32 x i16>, ptr %b
200 %tmp3 = shufflevector <32 x i16> %tmp1, <32 x i16> %tmp2, <32 x i32> <i32 0, i32 32, i32 1, i32 33, i32 2, i32 34, i32 3, i32 35, i32 4, i32 36, i32 5, i32 37, i32 6, i32 38, i32 7, i32 39, i32 8, i32 40, i32 9, i32 41, i32 10, i32 42, i32 11, i32 43, i32 12, i32 44, i32 13, i32 45, i32 14, i32 46, i32 15, i32 47>
201 %tmp4 = shufflevector <32 x i16> %tmp1, <32 x i16> %tmp2, <32 x i32> <i32 16, i32 48, i32 17, i32 49, i32 18, i32 50, i32 19, i32 51, i32 20, i32 52, i32 21, i32 53, i32 22, i32 54, i32 23, i32 55, i32 24, i32 56, i32 25, i32 57, i32 26, i32 58, i32 27, i32 59, i32 28, i32 60, i32 29, i32 61, i32 30, i32 62, i32 31, i32 63>
202 %tmp5 = add <32 x i16> %tmp3, %tmp4
203 store <32 x i16> %tmp5, ptr %a
207 define void @zip1_v16i16(ptr %a, ptr %b) {
208 ; CHECK-LABEL: zip1_v16i16:
210 ; CHECK-NEXT: sub sp, sp, #16
211 ; CHECK-NEXT: .cfi_def_cfa_offset 16
212 ; CHECK-NEXT: ldr q0, [x0, #16]
213 ; CHECK-NEXT: ldr q0, [x0]
214 ; CHECK-NEXT: ldr q1, [x1, #16]
215 ; CHECK-NEXT: ldr q1, [x1]
216 ; CHECK-NEXT: mov z2.h, z0.h[7]
217 ; CHECK-NEXT: mov z3.h, z0.h[6]
218 ; CHECK-NEXT: mov z4.h, z0.h[5]
219 ; CHECK-NEXT: fmov w8, s2
220 ; CHECK-NEXT: mov z2.h, z0.h[4]
221 ; CHECK-NEXT: zip1 z0.h, z0.h, z1.h
222 ; CHECK-NEXT: strh w8, [sp, #12]
223 ; CHECK-NEXT: fmov w8, s3
224 ; CHECK-NEXT: mov z3.h, z1.h[7]
225 ; CHECK-NEXT: strh w8, [sp, #8]
226 ; CHECK-NEXT: fmov w8, s4
227 ; CHECK-NEXT: mov z4.h, z1.h[6]
228 ; CHECK-NEXT: strh w8, [sp, #4]
229 ; CHECK-NEXT: fmov w8, s2
230 ; CHECK-NEXT: mov z2.h, z1.h[5]
231 ; CHECK-NEXT: strh w8, [sp]
232 ; CHECK-NEXT: fmov w8, s3
233 ; CHECK-NEXT: mov z3.h, z1.h[4]
234 ; CHECK-NEXT: strh w8, [sp, #14]
235 ; CHECK-NEXT: fmov w8, s4
236 ; CHECK-NEXT: strh w8, [sp, #10]
237 ; CHECK-NEXT: fmov w8, s2
238 ; CHECK-NEXT: strh w8, [sp, #6]
239 ; CHECK-NEXT: fmov w8, s3
240 ; CHECK-NEXT: strh w8, [sp, #2]
241 ; CHECK-NEXT: ldr q1, [sp]
242 ; CHECK-NEXT: str q0, [x0]
243 ; CHECK-NEXT: str q1, [x0, #16]
244 ; CHECK-NEXT: add sp, sp, #16
246 %tmp1 = load volatile <16 x i16>, ptr %a
247 %tmp2 = load volatile <16 x i16>, ptr %b
248 %tmp3 = shufflevector <16 x i16> %tmp1, <16 x i16> %tmp2, <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 4, i32 20, i32 5, i32 21, i32 6, i32 22, i32 7, i32 23>
249 store volatile <16 x i16> %tmp3, ptr %a
253 define void @zip1_v8i32(ptr %a, ptr %b) {
254 ; CHECK-LABEL: zip1_v8i32:
256 ; CHECK-NEXT: sub sp, sp, #16
257 ; CHECK-NEXT: .cfi_def_cfa_offset 16
258 ; CHECK-NEXT: ldr q0, [x0, #16]
259 ; CHECK-NEXT: ldr q0, [x0]
260 ; CHECK-NEXT: ldr q1, [x1, #16]
261 ; CHECK-NEXT: ldr q1, [x1]
262 ; CHECK-NEXT: mov z2.s, z0.s[3]
263 ; CHECK-NEXT: mov z4.s, z0.s[2]
264 ; CHECK-NEXT: mov z3.s, z1.s[3]
265 ; CHECK-NEXT: zip1 z0.s, z0.s, z1.s
266 ; CHECK-NEXT: fmov w8, s2
267 ; CHECK-NEXT: mov z2.s, z1.s[2]
268 ; CHECK-NEXT: fmov w9, s3
269 ; CHECK-NEXT: stp w8, w9, [sp, #8]
270 ; CHECK-NEXT: fmov w8, s4
271 ; CHECK-NEXT: fmov w9, s2
272 ; CHECK-NEXT: stp w8, w9, [sp]
273 ; CHECK-NEXT: ldr q1, [sp]
274 ; CHECK-NEXT: str q0, [x0]
275 ; CHECK-NEXT: str q1, [x0, #16]
276 ; CHECK-NEXT: add sp, sp, #16
278 %tmp1 = load volatile <8 x i32>, ptr %a
279 %tmp2 = load volatile <8 x i32>, ptr %b
280 %tmp3 = shufflevector <8 x i32> %tmp1, <8 x i32> %tmp2, <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
281 store volatile <8 x i32> %tmp3, ptr %a
285 define void @zip_v4f64(ptr %a, ptr %b) {
286 ; CHECK-LABEL: zip_v4f64:
288 ; CHECK-NEXT: ldp q1, q0, [x0]
289 ; CHECK-NEXT: ptrue p0.d, vl2
290 ; CHECK-NEXT: ldp q3, q2, [x1]
291 ; CHECK-NEXT: zip1 z4.d, z1.d, z3.d
292 ; CHECK-NEXT: zip1 z5.d, z0.d, z2.d
293 ; CHECK-NEXT: trn2 z1.d, z1.d, z3.d
294 ; CHECK-NEXT: trn2 z0.d, z0.d, z2.d
295 ; CHECK-NEXT: movprfx z2, z4
296 ; CHECK-NEXT: fadd z2.d, p0/m, z2.d, z5.d
297 ; CHECK-NEXT: fadd z0.d, p0/m, z0.d, z1.d
298 ; CHECK-NEXT: stp q2, q0, [x0]
300 %tmp1 = load <4 x double>, ptr %a
301 %tmp2 = load <4 x double>, ptr %b
302 %tmp3 = shufflevector <4 x double> %tmp1, <4 x double> %tmp2, <4 x i32> <i32 0, i32 4, i32 1, i32 5>
303 %tmp4 = shufflevector <4 x double> %tmp1, <4 x double> %tmp2, <4 x i32> <i32 2, i32 6, i32 3, i32 7>
304 %tmp5 = fadd <4 x double> %tmp3, %tmp4
305 store <4 x double> %tmp5, ptr %a
309 define void @zip_v4i32(ptr %a, ptr %b) {
310 ; CHECK-LABEL: zip_v4i32:
312 ; CHECK-NEXT: sub sp, sp, #16
313 ; CHECK-NEXT: .cfi_def_cfa_offset 16
314 ; CHECK-NEXT: ldr q0, [x1]
315 ; CHECK-NEXT: ldr q1, [x0]
316 ; CHECK-NEXT: mov z2.s, z0.s[3]
317 ; CHECK-NEXT: mov z3.s, z1.s[3]
318 ; CHECK-NEXT: mov z4.s, z0.s[2]
319 ; CHECK-NEXT: zip1 z0.s, z1.s, z0.s
320 ; CHECK-NEXT: fmov w8, s2
321 ; CHECK-NEXT: mov z2.s, z1.s[2]
322 ; CHECK-NEXT: fmov w9, s3
323 ; CHECK-NEXT: stp w9, w8, [sp, #8]
324 ; CHECK-NEXT: fmov w8, s4
325 ; CHECK-NEXT: fmov w9, s2
326 ; CHECK-NEXT: stp w9, w8, [sp]
327 ; CHECK-NEXT: ldr q1, [sp]
328 ; CHECK-NEXT: add z0.s, z0.s, z1.s
329 ; CHECK-NEXT: str q0, [x0]
330 ; CHECK-NEXT: add sp, sp, #16
332 %tmp1 = load <4 x i32>, ptr %a
333 %tmp2 = load <4 x i32>, ptr %b
334 %tmp3 = shufflevector <4 x i32> %tmp1, <4 x i32> %tmp2, <4 x i32> <i32 0, i32 4, i32 1, i32 5>
335 %tmp4 = shufflevector <4 x i32> %tmp1, <4 x i32> %tmp2, <4 x i32> <i32 2, i32 6, i32 3, i32 7>
336 %tmp5 = add <4 x i32> %tmp3, %tmp4
337 store <4 x i32> %tmp5, ptr %a
341 define void @zip1_v8i32_undef(ptr %a) {
342 ; CHECK-LABEL: zip1_v8i32_undef:
344 ; CHECK-NEXT: sub sp, sp, #16
345 ; CHECK-NEXT: .cfi_def_cfa_offset 16
346 ; CHECK-NEXT: ldr q0, [x0, #16]
347 ; CHECK-NEXT: ldr q0, [x0]
348 ; CHECK-NEXT: mov z1.s, z0.s[3]
349 ; CHECK-NEXT: mov z2.s, z0.s[2]
350 ; CHECK-NEXT: zip1 z0.s, z0.s, z0.s
351 ; CHECK-NEXT: fmov w8, s1
352 ; CHECK-NEXT: fmov w9, s2
353 ; CHECK-NEXT: stp w8, w8, [sp, #8]
354 ; CHECK-NEXT: stp w9, w9, [sp]
355 ; CHECK-NEXT: ldr q1, [sp]
356 ; CHECK-NEXT: str q0, [x0]
357 ; CHECK-NEXT: str q1, [x0, #16]
358 ; CHECK-NEXT: add sp, sp, #16
360 %tmp1 = load volatile <8 x i32>, ptr %a
361 %tmp2 = shufflevector <8 x i32> %tmp1, <8 x i32> undef, <8 x i32> <i32 0, i32 0, i32 1, i32 1, i32 2, i32 2, i32 3, i32 3>
362 store volatile <8 x i32> %tmp2, ptr %a
366 define void @trn_v32i8(ptr %a, ptr %b) {
367 ; CHECK-LABEL: trn_v32i8:
369 ; CHECK-NEXT: ldp q0, q2, [x0]
370 ; CHECK-NEXT: ldp q1, q3, [x1]
371 ; CHECK-NEXT: trn1 z4.b, z0.b, z1.b
372 ; CHECK-NEXT: trn2 z0.b, z0.b, z1.b
373 ; CHECK-NEXT: trn1 z1.b, z2.b, z3.b
374 ; CHECK-NEXT: trn2 z2.b, z2.b, z3.b
375 ; CHECK-NEXT: add z0.b, z4.b, z0.b
376 ; CHECK-NEXT: add z1.b, z1.b, z2.b
377 ; CHECK-NEXT: stp q0, q1, [x0]
379 %tmp1 = load <32 x i8>, ptr %a
380 %tmp2 = load <32 x i8>, ptr %b
381 %tmp3 = shufflevector <32 x i8> %tmp1, <32 x i8> %tmp2, <32 x i32> <i32 0, i32 32, i32 2, i32 34, i32 4, i32 36, i32 6, i32 38, i32 8, i32 40, i32 10, i32 42, i32 12, i32 44, i32 14, i32 46, i32 16, i32 48, i32 18, i32 50, i32 20, i32 52, i32 22, i32 54, i32 24, i32 56, i32 26, i32 58, i32 28, i32 60, i32 30, i32 62>
382 %tmp4 = shufflevector <32 x i8> %tmp1, <32 x i8> %tmp2, <32 x i32> <i32 1, i32 33, i32 3, i32 35, i32 undef, i32 37, i32 7, i32 undef, i32 undef, i32 41, i32 11, i32 43, i32 13, i32 45, i32 15, i32 47, i32 17, i32 49, i32 19, i32 51, i32 21, i32 53, i32 23, i32 55, i32 25, i32 57, i32 27, i32 59, i32 29, i32 61, i32 31, i32 63>
383 %tmp5 = add <32 x i8> %tmp3, %tmp4
384 store <32 x i8> %tmp5, ptr %a
388 define void @trn_v8i16(ptr %a, ptr %b) {
389 ; CHECK-LABEL: trn_v8i16:
391 ; CHECK-NEXT: ldr q0, [x0]
392 ; CHECK-NEXT: fmov w8, s0
393 ; CHECK-NEXT: mov z1.h, z0.h[3]
394 ; CHECK-NEXT: mov z2.h, z0.h[1]
395 ; CHECK-NEXT: mov z3.h, z0.h[5]
396 ; CHECK-NEXT: mov z4.h, z0.h[4]
397 ; CHECK-NEXT: strh w8, [sp, #-32]!
398 ; CHECK-NEXT: .cfi_def_cfa_offset 32
399 ; CHECK-NEXT: fmov w8, s1
400 ; CHECK-NEXT: mov z1.h, z0.h[2]
401 ; CHECK-NEXT: fmov w9, s2
402 ; CHECK-NEXT: mov z2.h, z0.h[6]
403 ; CHECK-NEXT: mov z0.h, z0.h[7]
404 ; CHECK-NEXT: fmov w10, s3
405 ; CHECK-NEXT: fmov w11, s4
406 ; CHECK-NEXT: fmov w12, s1
407 ; CHECK-NEXT: strh w8, [sp, #14]
408 ; CHECK-NEXT: fmov w13, s2
409 ; CHECK-NEXT: strh w9, [sp, #12]
410 ; CHECK-NEXT: strh w10, [sp, #10]
411 ; CHECK-NEXT: strh w12, [sp, #4]
412 ; CHECK-NEXT: fmov w12, s0
413 ; CHECK-NEXT: strh w11, [sp, #8]
414 ; CHECK-NEXT: strh w13, [sp, #6]
415 ; CHECK-NEXT: strh w12, [sp, #2]
416 ; CHECK-NEXT: strh w12, [sp, #28]
417 ; CHECK-NEXT: strh w11, [sp, #26]
418 ; CHECK-NEXT: strh w10, [sp, #22]
419 ; CHECK-NEXT: strh w8, [sp, #20]
420 ; CHECK-NEXT: strh w13, [sp, #18]
421 ; CHECK-NEXT: strh w9, [sp, #16]
422 ; CHECK-NEXT: ldp q0, q1, [sp]
423 ; CHECK-NEXT: add z0.h, z0.h, z1.h
424 ; CHECK-NEXT: str q0, [x0]
425 ; CHECK-NEXT: add sp, sp, #32
427 %tmp1 = load <8 x i16>, ptr %a
428 %tmp2 = load <8 x i16>, ptr %b
429 %tmp3 = shufflevector <8 x i16> %tmp1, <8 x i16> %tmp2, <8 x i32> <i32 0, i32 7, i32 2, i32 6, i32 4, i32 5, i32 1, i32 3>
430 %tmp4 = shufflevector <8 x i16> %tmp1, <8 x i16> %tmp2, <8 x i32> <i32 1, i32 6, i32 3, i32 5, i32 undef, i32 4, i32 7, i32 undef>
431 %tmp5 = add <8 x i16> %tmp3, %tmp4
432 store <8 x i16> %tmp5, ptr %a
436 define void @trn_v16i16(ptr %a, ptr %b) {
437 ; CHECK-LABEL: trn_v16i16:
439 ; CHECK-NEXT: ldp q0, q2, [x0]
440 ; CHECK-NEXT: ldp q1, q3, [x1]
441 ; CHECK-NEXT: trn1 z4.h, z0.h, z1.h
442 ; CHECK-NEXT: trn2 z0.h, z0.h, z1.h
443 ; CHECK-NEXT: trn1 z1.h, z2.h, z3.h
444 ; CHECK-NEXT: trn2 z2.h, z2.h, z3.h
445 ; CHECK-NEXT: add z0.h, z4.h, z0.h
446 ; CHECK-NEXT: add z1.h, z1.h, z2.h
447 ; CHECK-NEXT: stp q0, q1, [x0]
449 %tmp1 = load <16 x i16>, ptr %a
450 %tmp2 = load <16 x i16>, ptr %b
451 %tmp3 = shufflevector <16 x i16> %tmp1, <16 x i16> %tmp2, <16 x i32> <i32 0, i32 16, i32 2, i32 18, i32 4, i32 20, i32 6, i32 22, i32 8, i32 24, i32 10, i32 26, i32 12, i32 28, i32 14, i32 30>
452 %tmp4 = shufflevector <16 x i16> %tmp1, <16 x i16> %tmp2, <16 x i32> <i32 1, i32 17, i32 3, i32 19, i32 5, i32 21, i32 7, i32 23, i32 9, i32 25, i32 11, i32 27, i32 13, i32 29, i32 15, i32 31>
453 %tmp5 = add <16 x i16> %tmp3, %tmp4
454 store <16 x i16> %tmp5, ptr %a
458 define void @trn_v8i32(ptr %a, ptr %b) {
459 ; CHECK-LABEL: trn_v8i32:
461 ; CHECK-NEXT: ldp q0, q2, [x0]
462 ; CHECK-NEXT: ldp q1, q3, [x1]
463 ; CHECK-NEXT: zip1 z4.s, z0.s, z1.s
464 ; CHECK-NEXT: trn2 z0.s, z0.s, z1.s
465 ; CHECK-NEXT: trn1 z1.s, z2.s, z3.s
466 ; CHECK-NEXT: trn2 z2.s, z2.s, z3.s
467 ; CHECK-NEXT: add z0.s, z4.s, z0.s
468 ; CHECK-NEXT: add z1.s, z1.s, z2.s
469 ; CHECK-NEXT: stp q0, q1, [x0]
471 %tmp1 = load <8 x i32>, ptr %a
472 %tmp2 = load <8 x i32>, ptr %b
473 %tmp3 = shufflevector <8 x i32> %tmp1, <8 x i32> %tmp2, <8 x i32> <i32 0, i32 8, i32 undef, i32 undef, i32 4, i32 12, i32 6, i32 14>
474 %tmp4 = shufflevector <8 x i32> %tmp1, <8 x i32> %tmp2, <8 x i32> <i32 1, i32 undef, i32 3, i32 11, i32 5, i32 13, i32 undef, i32 undef>
475 %tmp5 = add <8 x i32> %tmp3, %tmp4
476 store <8 x i32> %tmp5, ptr %a
480 define void @trn_v4f64(ptr %a, ptr %b) {
481 ; CHECK-LABEL: trn_v4f64:
483 ; CHECK-NEXT: ldp q0, q2, [x0]
484 ; CHECK-NEXT: ptrue p0.d, vl2
485 ; CHECK-NEXT: ldp q1, q3, [x1]
486 ; CHECK-NEXT: zip1 z4.d, z0.d, z1.d
487 ; CHECK-NEXT: trn2 z0.d, z0.d, z1.d
488 ; CHECK-NEXT: zip1 z1.d, z2.d, z3.d
489 ; CHECK-NEXT: trn2 z2.d, z2.d, z3.d
490 ; CHECK-NEXT: fadd z0.d, p0/m, z0.d, z4.d
491 ; CHECK-NEXT: fadd z1.d, p0/m, z1.d, z2.d
492 ; CHECK-NEXT: stp q0, q1, [x0]
494 %tmp1 = load <4 x double>, ptr %a
495 %tmp2 = load <4 x double>, ptr %b
496 %tmp3 = shufflevector <4 x double> %tmp1, <4 x double> %tmp2, <4 x i32> <i32 0, i32 4, i32 2, i32 6>
497 %tmp4 = shufflevector <4 x double> %tmp1, <4 x double> %tmp2, <4 x i32> <i32 1, i32 5, i32 3, i32 7>
498 %tmp5 = fadd <4 x double> %tmp3, %tmp4
499 store <4 x double> %tmp5, ptr %a
503 define void @trn_v4f32(ptr %a, ptr %b) {
504 ; CHECK-LABEL: trn_v4f32:
506 ; CHECK-NEXT: ptrue p0.s, vl4
507 ; CHECK-NEXT: ldr q0, [x0]
508 ; CHECK-NEXT: ldr q1, [x1]
509 ; CHECK-NEXT: trn1 z2.s, z0.s, z1.s
510 ; CHECK-NEXT: trn2 z0.s, z0.s, z1.s
511 ; CHECK-NEXT: fadd z0.s, p0/m, z0.s, z2.s
512 ; CHECK-NEXT: str q0, [x0]
514 %tmp1 = load <4 x float>, ptr %a
515 %tmp2 = load <4 x float>, ptr %b
516 %tmp3 = shufflevector <4 x float> %tmp1, <4 x float> %tmp2, <4 x i32> <i32 0, i32 4, i32 2, i32 6>
517 %tmp4 = shufflevector <4 x float> %tmp1, <4 x float> %tmp2, <4 x i32> <i32 1, i32 5, i32 3, i32 7>
518 %tmp5 = fadd <4 x float> %tmp3, %tmp4
519 store <4 x float> %tmp5, ptr %a
523 define void @trn_v8i32_undef(ptr %a) {
524 ; CHECK-LABEL: trn_v8i32_undef:
526 ; CHECK-NEXT: ldp q0, q1, [x0]
527 ; CHECK-NEXT: trn1 z2.s, z0.s, z0.s
528 ; CHECK-NEXT: trn2 z0.s, z0.s, z0.s
529 ; CHECK-NEXT: trn1 z3.s, z1.s, z1.s
530 ; CHECK-NEXT: trn2 z1.s, z1.s, z1.s
531 ; CHECK-NEXT: add z0.s, z2.s, z0.s
532 ; CHECK-NEXT: add z1.s, z3.s, z1.s
533 ; CHECK-NEXT: stp q0, q1, [x0]
535 %tmp1 = load <8 x i32>, ptr %a
536 %tmp3 = shufflevector <8 x i32> %tmp1, <8 x i32> undef, <8 x i32> <i32 0, i32 0, i32 2, i32 2, i32 4, i32 4, i32 6, i32 6>
537 %tmp4 = shufflevector <8 x i32> %tmp1, <8 x i32> undef, <8 x i32> <i32 1, i32 1, i32 3, i32 3, i32 5, i32 5, i32 7, i32 7>
538 %tmp5 = add <8 x i32> %tmp3, %tmp4
539 store <8 x i32> %tmp5, ptr %a
543 define void @zip2_v32i8(ptr %a, ptr %b) #0{
544 ; CHECK-LABEL: zip2_v32i8:
546 ; CHECK-NEXT: sub sp, sp, #16
547 ; CHECK-NEXT: .cfi_def_cfa_offset 16
548 ; CHECK-NEXT: ldr q0, [x0]
549 ; CHECK-NEXT: ldr q0, [x0, #16]
550 ; CHECK-NEXT: ldr q1, [x1]
551 ; CHECK-NEXT: ldr q1, [x1, #16]
552 ; CHECK-NEXT: mov z2.b, z0.b[15]
553 ; CHECK-NEXT: mov z3.b, z0.b[14]
554 ; CHECK-NEXT: mov z4.b, z0.b[13]
555 ; CHECK-NEXT: fmov w8, s2
556 ; CHECK-NEXT: mov z2.b, z0.b[12]
557 ; CHECK-NEXT: strb w8, [sp, #14]
558 ; CHECK-NEXT: fmov w8, s3
559 ; CHECK-NEXT: mov z3.b, z0.b[11]
560 ; CHECK-NEXT: strb w8, [sp, #12]
561 ; CHECK-NEXT: fmov w8, s4
562 ; CHECK-NEXT: mov z4.b, z0.b[10]
563 ; CHECK-NEXT: strb w8, [sp, #10]
564 ; CHECK-NEXT: fmov w8, s2
565 ; CHECK-NEXT: mov z2.b, z0.b[9]
566 ; CHECK-NEXT: strb w8, [sp, #8]
567 ; CHECK-NEXT: fmov w8, s3
568 ; CHECK-NEXT: mov z3.b, z0.b[8]
569 ; CHECK-NEXT: zip1 z0.b, z0.b, z1.b
570 ; CHECK-NEXT: strb w8, [sp, #6]
571 ; CHECK-NEXT: fmov w8, s4
572 ; CHECK-NEXT: mov z4.b, z1.b[15]
573 ; CHECK-NEXT: strb w8, [sp, #4]
574 ; CHECK-NEXT: fmov w8, s2
575 ; CHECK-NEXT: mov z2.b, z1.b[14]
576 ; CHECK-NEXT: strb w8, [sp, #2]
577 ; CHECK-NEXT: fmov w8, s3
578 ; CHECK-NEXT: mov z3.b, z1.b[13]
579 ; CHECK-NEXT: strb w8, [sp]
580 ; CHECK-NEXT: fmov w8, s4
581 ; CHECK-NEXT: mov z4.b, z1.b[12]
582 ; CHECK-NEXT: strb w8, [sp, #15]
583 ; CHECK-NEXT: fmov w8, s2
584 ; CHECK-NEXT: mov z2.b, z1.b[11]
585 ; CHECK-NEXT: strb w8, [sp, #13]
586 ; CHECK-NEXT: fmov w8, s3
587 ; CHECK-NEXT: mov z3.b, z1.b[10]
588 ; CHECK-NEXT: strb w8, [sp, #11]
589 ; CHECK-NEXT: fmov w8, s4
590 ; CHECK-NEXT: mov z4.b, z1.b[9]
591 ; CHECK-NEXT: strb w8, [sp, #9]
592 ; CHECK-NEXT: fmov w8, s2
593 ; CHECK-NEXT: mov z2.b, z1.b[8]
594 ; CHECK-NEXT: strb w8, [sp, #7]
595 ; CHECK-NEXT: fmov w8, s3
596 ; CHECK-NEXT: strb w8, [sp, #5]
597 ; CHECK-NEXT: fmov w8, s4
598 ; CHECK-NEXT: strb w8, [sp, #3]
599 ; CHECK-NEXT: fmov w8, s2
600 ; CHECK-NEXT: strb w8, [sp, #1]
601 ; CHECK-NEXT: ldr q1, [sp]
602 ; CHECK-NEXT: str q0, [x0]
603 ; CHECK-NEXT: str q1, [x0, #16]
604 ; CHECK-NEXT: add sp, sp, #16
606 %tmp1 = load volatile <32 x i8>, ptr %a
607 %tmp2 = load volatile <32 x i8>, ptr %b
608 %tmp3 = shufflevector <32 x i8> %tmp1, <32 x i8> %tmp2, <32 x i32> <i32 16, i32 48, i32 17, i32 49, i32 18, i32 50, i32 19, i32 51, i32 20, i32 52, i32 21, i32 53, i32 22, i32 54, i32 23, i32 55, i32 24, i32 56, i32 25, i32 57, i32 26, i32 58, i32 27, i32 59, i32 28, i32 60, i32 29, i32 61, i32 30, i32 62, i32 31, i32 63>
609 store volatile <32 x i8> %tmp3, ptr %a
613 define void @zip2_v16i16(ptr %a, ptr %b) #0{
614 ; CHECK-LABEL: zip2_v16i16:
616 ; CHECK-NEXT: sub sp, sp, #16
617 ; CHECK-NEXT: .cfi_def_cfa_offset 16
618 ; CHECK-NEXT: ldr q0, [x0]
619 ; CHECK-NEXT: ldr q0, [x0, #16]
620 ; CHECK-NEXT: ldr q1, [x1]
621 ; CHECK-NEXT: ldr q1, [x1, #16]
622 ; CHECK-NEXT: mov z2.h, z0.h[7]
623 ; CHECK-NEXT: mov z3.h, z0.h[6]
624 ; CHECK-NEXT: mov z4.h, z0.h[5]
625 ; CHECK-NEXT: fmov w8, s2
626 ; CHECK-NEXT: mov z2.h, z0.h[4]
627 ; CHECK-NEXT: zip1 z0.h, z0.h, z1.h
628 ; CHECK-NEXT: strh w8, [sp, #12]
629 ; CHECK-NEXT: fmov w8, s3
630 ; CHECK-NEXT: mov z3.h, z1.h[7]
631 ; CHECK-NEXT: strh w8, [sp, #8]
632 ; CHECK-NEXT: fmov w8, s4
633 ; CHECK-NEXT: mov z4.h, z1.h[6]
634 ; CHECK-NEXT: strh w8, [sp, #4]
635 ; CHECK-NEXT: fmov w8, s2
636 ; CHECK-NEXT: mov z2.h, z1.h[5]
637 ; CHECK-NEXT: strh w8, [sp]
638 ; CHECK-NEXT: fmov w8, s3
639 ; CHECK-NEXT: mov z3.h, z1.h[4]
640 ; CHECK-NEXT: strh w8, [sp, #14]
641 ; CHECK-NEXT: fmov w8, s4
642 ; CHECK-NEXT: strh w8, [sp, #10]
643 ; CHECK-NEXT: fmov w8, s2
644 ; CHECK-NEXT: strh w8, [sp, #6]
645 ; CHECK-NEXT: fmov w8, s3
646 ; CHECK-NEXT: strh w8, [sp, #2]
647 ; CHECK-NEXT: ldr q1, [sp]
648 ; CHECK-NEXT: str q0, [x0]
649 ; CHECK-NEXT: str q1, [x0, #16]
650 ; CHECK-NEXT: add sp, sp, #16
652 %tmp1 = load volatile <16 x i16>, ptr %a
653 %tmp2 = load volatile <16 x i16>, ptr %b
654 %tmp3 = shufflevector <16 x i16> %tmp1, <16 x i16> %tmp2, <16 x i32> <i32 8, i32 24, i32 9, i32 25, i32 10, i32 26, i32 11, i32 27, i32 12, i32 28, i32 13, i32 29, i32 14, i32 30, i32 15, i32 31>
655 store volatile <16 x i16> %tmp3, ptr %a
659 define void @zip2_v8i32(ptr %a, ptr %b) #0{
660 ; CHECK-LABEL: zip2_v8i32:
662 ; CHECK-NEXT: sub sp, sp, #16
663 ; CHECK-NEXT: .cfi_def_cfa_offset 16
664 ; CHECK-NEXT: ldr q0, [x0]
665 ; CHECK-NEXT: ldr q0, [x0, #16]
666 ; CHECK-NEXT: ldr q1, [x1]
667 ; CHECK-NEXT: ldr q1, [x1, #16]
668 ; CHECK-NEXT: mov z2.s, z0.s[3]
669 ; CHECK-NEXT: mov z4.s, z0.s[2]
670 ; CHECK-NEXT: mov z3.s, z1.s[3]
671 ; CHECK-NEXT: zip1 z0.s, z0.s, z1.s
672 ; CHECK-NEXT: fmov w8, s2
673 ; CHECK-NEXT: mov z2.s, z1.s[2]
674 ; CHECK-NEXT: fmov w9, s3
675 ; CHECK-NEXT: stp w8, w9, [sp, #8]
676 ; CHECK-NEXT: fmov w8, s4
677 ; CHECK-NEXT: fmov w9, s2
678 ; CHECK-NEXT: stp w8, w9, [sp]
679 ; CHECK-NEXT: ldr q1, [sp]
680 ; CHECK-NEXT: str q0, [x0]
681 ; CHECK-NEXT: str q1, [x0, #16]
682 ; CHECK-NEXT: add sp, sp, #16
684 %tmp1 = load volatile <8 x i32>, ptr %a
685 %tmp2 = load volatile <8 x i32>, ptr %b
686 %tmp3 = shufflevector <8 x i32> %tmp1, <8 x i32> %tmp2, <8 x i32> <i32 4, i32 12, i32 5, i32 13, i32 6, i32 14, i32 7, i32 15>
687 store volatile <8 x i32> %tmp3, ptr %a
691 define void @zip2_v8i32_undef(ptr %a) #0{
692 ; CHECK-LABEL: zip2_v8i32_undef:
694 ; CHECK-NEXT: sub sp, sp, #16
695 ; CHECK-NEXT: .cfi_def_cfa_offset 16
696 ; CHECK-NEXT: ldr q0, [x0]
697 ; CHECK-NEXT: ldr q0, [x0, #16]
698 ; CHECK-NEXT: mov z1.s, z0.s[3]
699 ; CHECK-NEXT: mov z2.s, z0.s[2]
700 ; CHECK-NEXT: zip1 z0.s, z0.s, z0.s
701 ; CHECK-NEXT: fmov w8, s1
702 ; CHECK-NEXT: fmov w9, s2
703 ; CHECK-NEXT: stp w8, w8, [sp, #8]
704 ; CHECK-NEXT: stp w9, w9, [sp]
705 ; CHECK-NEXT: ldr q1, [sp]
706 ; CHECK-NEXT: str q0, [x0]
707 ; CHECK-NEXT: str q1, [x0, #16]
708 ; CHECK-NEXT: add sp, sp, #16
710 %tmp1 = load volatile <8 x i32>, ptr %a
711 %tmp2 = shufflevector <8 x i32> %tmp1, <8 x i32> undef, <8 x i32> <i32 4, i32 4, i32 5, i32 5, i32 6, i32 6, i32 7, i32 7>
712 store volatile <8 x i32> %tmp2, ptr %a
716 define void @uzp_v32i8(ptr %a, ptr %b) #0{
717 ; CHECK-LABEL: uzp_v32i8:
719 ; CHECK-NEXT: sub sp, sp, #64
720 ; CHECK-NEXT: .cfi_def_cfa_offset 64
721 ; CHECK-NEXT: ldp q2, q3, [x0]
722 ; CHECK-NEXT: ldp q0, q1, [x1]
723 ; CHECK-NEXT: fmov w8, s3
724 ; CHECK-NEXT: mov z4.b, z3.b[14]
725 ; CHECK-NEXT: mov z5.b, z3.b[12]
726 ; CHECK-NEXT: mov z6.b, z3.b[10]
727 ; CHECK-NEXT: mov z7.b, z3.b[8]
728 ; CHECK-NEXT: mov z16.b, z3.b[11]
729 ; CHECK-NEXT: mov z17.b, z3.b[9]
730 ; CHECK-NEXT: mov z18.b, z3.b[7]
731 ; CHECK-NEXT: strb w8, [sp, #40]
732 ; CHECK-NEXT: fmov w8, s2
733 ; CHECK-NEXT: strb w8, [sp, #32]
734 ; CHECK-NEXT: fmov w8, s4
735 ; CHECK-NEXT: mov z4.b, z3.b[6]
736 ; CHECK-NEXT: strb w8, [sp, #47]
737 ; CHECK-NEXT: fmov w8, s5
738 ; CHECK-NEXT: mov z5.b, z3.b[4]
739 ; CHECK-NEXT: strb w8, [sp, #46]
740 ; CHECK-NEXT: fmov w8, s6
741 ; CHECK-NEXT: mov z6.b, z3.b[2]
742 ; CHECK-NEXT: strb w8, [sp, #45]
743 ; CHECK-NEXT: fmov w8, s7
744 ; CHECK-NEXT: mov z7.b, z2.b[14]
745 ; CHECK-NEXT: strb w8, [sp, #44]
746 ; CHECK-NEXT: fmov w8, s4
747 ; CHECK-NEXT: mov z4.b, z2.b[12]
748 ; CHECK-NEXT: strb w8, [sp, #43]
749 ; CHECK-NEXT: fmov w8, s5
750 ; CHECK-NEXT: mov z5.b, z2.b[10]
751 ; CHECK-NEXT: strb w8, [sp, #42]
752 ; CHECK-NEXT: fmov w8, s6
753 ; CHECK-NEXT: mov z6.b, z2.b[8]
754 ; CHECK-NEXT: strb w8, [sp, #41]
755 ; CHECK-NEXT: fmov w8, s7
756 ; CHECK-NEXT: mov z7.b, z2.b[6]
757 ; CHECK-NEXT: strb w8, [sp, #39]
758 ; CHECK-NEXT: fmov w8, s4
759 ; CHECK-NEXT: mov z4.b, z2.b[4]
760 ; CHECK-NEXT: strb w8, [sp, #38]
761 ; CHECK-NEXT: fmov w8, s5
762 ; CHECK-NEXT: mov z5.b, z2.b[2]
763 ; CHECK-NEXT: strb w8, [sp, #37]
764 ; CHECK-NEXT: fmov w8, s6
765 ; CHECK-NEXT: mov z6.b, z1.b[10]
766 ; CHECK-NEXT: strb w8, [sp, #36]
767 ; CHECK-NEXT: fmov w8, s7
768 ; CHECK-NEXT: mov z7.b, z1.b[8]
769 ; CHECK-NEXT: strb w8, [sp, #35]
770 ; CHECK-NEXT: fmov w8, s4
771 ; CHECK-NEXT: mov z4.b, z1.b[14]
772 ; CHECK-NEXT: strb w8, [sp, #34]
773 ; CHECK-NEXT: fmov w8, s5
774 ; CHECK-NEXT: mov z5.b, z1.b[12]
775 ; CHECK-NEXT: strb w8, [sp, #33]
776 ; CHECK-NEXT: fmov w8, s1
777 ; CHECK-NEXT: strb w8, [sp, #8]
778 ; CHECK-NEXT: fmov w8, s0
779 ; CHECK-NEXT: strb w8, [sp]
780 ; CHECK-NEXT: fmov w8, s4
781 ; CHECK-NEXT: mov z4.b, z1.b[6]
782 ; CHECK-NEXT: strb w8, [sp, #15]
783 ; CHECK-NEXT: fmov w8, s5
784 ; CHECK-NEXT: mov z5.b, z1.b[4]
785 ; CHECK-NEXT: strb w8, [sp, #14]
786 ; CHECK-NEXT: fmov w8, s6
787 ; CHECK-NEXT: mov z6.b, z1.b[2]
788 ; CHECK-NEXT: strb w8, [sp, #13]
789 ; CHECK-NEXT: fmov w8, s7
790 ; CHECK-NEXT: mov z7.b, z0.b[14]
791 ; CHECK-NEXT: strb w8, [sp, #12]
792 ; CHECK-NEXT: fmov w8, s4
793 ; CHECK-NEXT: mov z4.b, z0.b[12]
794 ; CHECK-NEXT: strb w8, [sp, #11]
795 ; CHECK-NEXT: fmov w8, s5
796 ; CHECK-NEXT: mov z5.b, z0.b[10]
797 ; CHECK-NEXT: strb w8, [sp, #10]
798 ; CHECK-NEXT: fmov w8, s6
799 ; CHECK-NEXT: mov z6.b, z0.b[8]
800 ; CHECK-NEXT: strb w8, [sp, #9]
801 ; CHECK-NEXT: fmov w8, s7
802 ; CHECK-NEXT: mov z7.b, z0.b[6]
803 ; CHECK-NEXT: strb w8, [sp, #7]
804 ; CHECK-NEXT: fmov w8, s4
805 ; CHECK-NEXT: mov z4.b, z0.b[4]
806 ; CHECK-NEXT: strb w8, [sp, #6]
807 ; CHECK-NEXT: fmov w8, s5
808 ; CHECK-NEXT: mov z5.b, z0.b[2]
809 ; CHECK-NEXT: strb w8, [sp, #5]
810 ; CHECK-NEXT: fmov w8, s6
811 ; CHECK-NEXT: mov z6.b, z3.b[15]
812 ; CHECK-NEXT: strb w8, [sp, #4]
813 ; CHECK-NEXT: fmov w8, s7
814 ; CHECK-NEXT: mov z7.b, z3.b[13]
815 ; CHECK-NEXT: strb w8, [sp, #3]
816 ; CHECK-NEXT: fmov w8, s4
817 ; CHECK-NEXT: ldr q4, [sp, #32]
818 ; CHECK-NEXT: strb w8, [sp, #2]
819 ; CHECK-NEXT: fmov w8, s5
820 ; CHECK-NEXT: strb w8, [sp, #1]
821 ; CHECK-NEXT: fmov w8, s6
822 ; CHECK-NEXT: mov z6.b, z3.b[5]
823 ; CHECK-NEXT: mov z3.b, z3.b[3]
824 ; CHECK-NEXT: ldr q5, [sp]
825 ; CHECK-NEXT: strb w8, [sp, #63]
826 ; CHECK-NEXT: fmov w8, s7
827 ; CHECK-NEXT: mov z7.b, z2.b[13]
828 ; CHECK-NEXT: strb w8, [sp, #62]
829 ; CHECK-NEXT: fmov w8, s16
830 ; CHECK-NEXT: mov z16.b, z2.b[11]
831 ; CHECK-NEXT: strb w8, [sp, #61]
832 ; CHECK-NEXT: fmov w8, s17
833 ; CHECK-NEXT: strb w8, [sp, #60]
834 ; CHECK-NEXT: fmov w8, s18
835 ; CHECK-NEXT: strb w8, [sp, #59]
836 ; CHECK-NEXT: fmov w8, s6
837 ; CHECK-NEXT: mov z6.b, z2.b[9]
838 ; CHECK-NEXT: strb w8, [sp, #58]
839 ; CHECK-NEXT: fmov w8, s3
840 ; CHECK-NEXT: mov z3.b, z2.b[5]
841 ; CHECK-NEXT: strb w8, [sp, #57]
842 ; CHECK-NEXT: fmov w8, s7
843 ; CHECK-NEXT: mov z7.b, z2.b[3]
844 ; CHECK-NEXT: mov z2.b, z2.b[1]
845 ; CHECK-NEXT: strb w8, [sp, #54]
846 ; CHECK-NEXT: fmov w8, s16
847 ; CHECK-NEXT: strb w8, [sp, #53]
848 ; CHECK-NEXT: fmov w8, s6
849 ; CHECK-NEXT: mov z6.b, z1.b[15]
850 ; CHECK-NEXT: strb w8, [sp, #52]
851 ; CHECK-NEXT: fmov w8, s3
852 ; CHECK-NEXT: mov z3.b, z1.b[13]
853 ; CHECK-NEXT: strb w8, [sp, #50]
854 ; CHECK-NEXT: fmov w8, s7
855 ; CHECK-NEXT: mov z7.b, z1.b[11]
856 ; CHECK-NEXT: strb w8, [sp, #49]
857 ; CHECK-NEXT: fmov w8, s2
858 ; CHECK-NEXT: mov z2.b, z1.b[9]
859 ; CHECK-NEXT: strb w8, [sp, #48]
860 ; CHECK-NEXT: fmov w8, s6
861 ; CHECK-NEXT: mov z6.b, z1.b[7]
862 ; CHECK-NEXT: strb w8, [sp, #31]
863 ; CHECK-NEXT: fmov w8, s3
864 ; CHECK-NEXT: mov z3.b, z1.b[5]
865 ; CHECK-NEXT: strb w8, [sp, #30]
866 ; CHECK-NEXT: fmov w8, s7
867 ; CHECK-NEXT: mov z7.b, z1.b[3]
868 ; CHECK-NEXT: mov z1.b, z1.b[1]
869 ; CHECK-NEXT: strb w8, [sp, #29]
870 ; CHECK-NEXT: fmov w8, s2
871 ; CHECK-NEXT: mov z2.b, z0.b[15]
872 ; CHECK-NEXT: strb w8, [sp, #28]
873 ; CHECK-NEXT: fmov w8, s6
874 ; CHECK-NEXT: mov z6.b, z0.b[11]
875 ; CHECK-NEXT: strb w8, [sp, #27]
876 ; CHECK-NEXT: fmov w8, s3
877 ; CHECK-NEXT: mov z3.b, z0.b[13]
878 ; CHECK-NEXT: strb w8, [sp, #26]
879 ; CHECK-NEXT: fmov w8, s7
880 ; CHECK-NEXT: strb w8, [sp, #25]
881 ; CHECK-NEXT: fmov w8, s1
882 ; CHECK-NEXT: mov z1.b, z0.b[9]
883 ; CHECK-NEXT: strb w8, [sp, #24]
884 ; CHECK-NEXT: fmov w8, s2
885 ; CHECK-NEXT: mov z2.b, z0.b[7]
886 ; CHECK-NEXT: strb w8, [sp, #23]
887 ; CHECK-NEXT: fmov w8, s3
888 ; CHECK-NEXT: mov z3.b, z0.b[5]
889 ; CHECK-NEXT: strb w8, [sp, #22]
890 ; CHECK-NEXT: fmov w8, s6
891 ; CHECK-NEXT: mov z6.b, z0.b[3]
892 ; CHECK-NEXT: mov z0.b, z0.b[1]
893 ; CHECK-NEXT: strb w8, [sp, #21]
894 ; CHECK-NEXT: fmov w8, s1
895 ; CHECK-NEXT: strb w8, [sp, #20]
896 ; CHECK-NEXT: fmov w8, s2
897 ; CHECK-NEXT: strb w8, [sp, #19]
898 ; CHECK-NEXT: fmov w8, s3
899 ; CHECK-NEXT: strb w8, [sp, #18]
900 ; CHECK-NEXT: fmov w8, s6
901 ; CHECK-NEXT: strb w8, [sp, #17]
902 ; CHECK-NEXT: fmov w8, s0
903 ; CHECK-NEXT: ldr q0, [sp, #48]
904 ; CHECK-NEXT: add z0.b, z4.b, z0.b
905 ; CHECK-NEXT: strb w8, [sp, #16]
906 ; CHECK-NEXT: ldr q1, [sp, #16]
907 ; CHECK-NEXT: add z1.b, z5.b, z1.b
908 ; CHECK-NEXT: stp q0, q1, [x0]
909 ; CHECK-NEXT: add sp, sp, #64
911 %tmp1 = load <32 x i8>, ptr %a
912 %tmp2 = load <32 x i8>, ptr %b
913 %tmp3 = shufflevector <32 x i8> %tmp1, <32 x i8> %tmp2, <32 x i32> <i32 0, i32 2, i32 4, i32 6, i32 8, i32 10, i32 12, i32 14, i32 16, i32 18, i32 20, i32 22, i32 24, i32 26, i32 28, i32 30, i32 32, i32 34, i32 36, i32 38, i32 40, i32 42, i32 44, i32 46, i32 48, i32 50, i32 52, i32 54, i32 56, i32 58, i32 60, i32 62>
914 %tmp4 = shufflevector <32 x i8> %tmp1, <32 x i8> %tmp2, <32 x i32> <i32 1, i32 3, i32 5, i32 undef, i32 9, i32 11, i32 13, i32 undef, i32 undef, i32 19, i32 21, i32 23, i32 25, i32 27, i32 29, i32 31, i32 33, i32 35, i32 37, i32 39, i32 41, i32 43, i32 45, i32 47, i32 49, i32 51, i32 53, i32 55, i32 57, i32 59, i32 61, i32 63>
915 %tmp5 = add <32 x i8> %tmp3, %tmp4
916 store <32 x i8> %tmp5, ptr %a
920 define void @uzp_v4i16(ptr %a, ptr %b) #0{
921 ; CHECK-LABEL: uzp_v4i16:
923 ; CHECK-NEXT: ldr d0, [x0]
924 ; CHECK-NEXT: mov z1.h, z0.h[1]
925 ; CHECK-NEXT: fmov w8, s0
926 ; CHECK-NEXT: mov z2.h, z0.h[2]
927 ; CHECK-NEXT: mov z3.h, z0.h[3]
928 ; CHECK-NEXT: fmov w9, s1
929 ; CHECK-NEXT: strh w8, [sp, #-16]!
930 ; CHECK-NEXT: .cfi_def_cfa_offset 16
931 ; CHECK-NEXT: fmov w10, s2
932 ; CHECK-NEXT: fmov w11, s3
933 ; CHECK-NEXT: strh w9, [sp, #6]
934 ; CHECK-NEXT: strh w8, [sp, #10]
935 ; CHECK-NEXT: strh w9, [sp, #8]
936 ; CHECK-NEXT: strh w10, [sp, #4]
937 ; CHECK-NEXT: strh w11, [sp, #2]
938 ; CHECK-NEXT: strh w10, [sp, #12]
939 ; CHECK-NEXT: ldp d0, d1, [sp]
940 ; CHECK-NEXT: add z0.h, z0.h, z1.h
941 ; CHECK-NEXT: str d0, [x0]
942 ; CHECK-NEXT: add sp, sp, #16
944 %tmp1 = load <4 x i16>, ptr %a
945 %tmp2 = load <4 x i16>, ptr %b
946 %tmp3 = shufflevector <4 x i16> %tmp1, <4 x i16> %tmp2, <4 x i32> <i32 0, i32 3, i32 2, i32 1>
947 %tmp4 = shufflevector <4 x i16> %tmp1, <4 x i16> %tmp2, <4 x i32> <i32 1, i32 0, i32 2, i32 undef>
948 %tmp5 = add <4 x i16> %tmp3, %tmp4
949 store <4 x i16> %tmp5, ptr %a
953 define void @uzp_v16i16(ptr %a, ptr %b) #0{
954 ; CHECK-LABEL: uzp_v16i16:
956 ; CHECK-NEXT: sub sp, sp, #64
957 ; CHECK-NEXT: .cfi_def_cfa_offset 64
958 ; CHECK-NEXT: ldp q1, q3, [x0]
959 ; CHECK-NEXT: ldp q0, q2, [x1]
960 ; CHECK-NEXT: fmov w8, s3
961 ; CHECK-NEXT: mov z4.h, z3.h[6]
962 ; CHECK-NEXT: mov z5.h, z3.h[4]
963 ; CHECK-NEXT: mov z6.h, z3.h[2]
964 ; CHECK-NEXT: mov z7.h, z1.h[6]
965 ; CHECK-NEXT: strh w8, [sp, #40]
966 ; CHECK-NEXT: fmov w8, s1
967 ; CHECK-NEXT: strh w8, [sp, #32]
968 ; CHECK-NEXT: fmov w8, s4
969 ; CHECK-NEXT: mov z4.h, z1.h[4]
970 ; CHECK-NEXT: strh w8, [sp, #46]
971 ; CHECK-NEXT: fmov w8, s5
972 ; CHECK-NEXT: mov z5.h, z1.h[2]
973 ; CHECK-NEXT: strh w8, [sp, #44]
974 ; CHECK-NEXT: fmov w8, s6
975 ; CHECK-NEXT: mov z6.h, z2.h[2]
976 ; CHECK-NEXT: strh w8, [sp, #42]
977 ; CHECK-NEXT: fmov w8, s7
978 ; CHECK-NEXT: mov z7.h, z0.h[6]
979 ; CHECK-NEXT: strh w8, [sp, #38]
980 ; CHECK-NEXT: fmov w8, s4
981 ; CHECK-NEXT: mov z4.h, z2.h[6]
982 ; CHECK-NEXT: strh w8, [sp, #36]
983 ; CHECK-NEXT: fmov w8, s5
984 ; CHECK-NEXT: mov z5.h, z2.h[4]
985 ; CHECK-NEXT: strh w8, [sp, #34]
986 ; CHECK-NEXT: fmov w8, s2
987 ; CHECK-NEXT: ldr q16, [sp, #32]
988 ; CHECK-NEXT: strh w8, [sp, #8]
989 ; CHECK-NEXT: fmov w8, s0
990 ; CHECK-NEXT: strh w8, [sp]
991 ; CHECK-NEXT: fmov w8, s4
992 ; CHECK-NEXT: mov z4.h, z0.h[4]
993 ; CHECK-NEXT: strh w8, [sp, #14]
994 ; CHECK-NEXT: fmov w8, s5
995 ; CHECK-NEXT: mov z5.h, z0.h[2]
996 ; CHECK-NEXT: strh w8, [sp, #12]
997 ; CHECK-NEXT: fmov w8, s6
998 ; CHECK-NEXT: mov z6.h, z3.h[7]
999 ; CHECK-NEXT: strh w8, [sp, #10]
1000 ; CHECK-NEXT: fmov w8, s7
1001 ; CHECK-NEXT: mov z7.h, z1.h[7]
1002 ; CHECK-NEXT: strh w8, [sp, #6]
1003 ; CHECK-NEXT: fmov w8, s4
1004 ; CHECK-NEXT: mov z4.h, z3.h[5]
1005 ; CHECK-NEXT: strh w8, [sp, #4]
1006 ; CHECK-NEXT: fmov w8, s5
1007 ; CHECK-NEXT: mov z5.h, z3.h[3]
1008 ; CHECK-NEXT: mov z3.h, z3.h[1]
1009 ; CHECK-NEXT: strh w8, [sp, #2]
1010 ; CHECK-NEXT: fmov w8, s6
1011 ; CHECK-NEXT: ldr q6, [sp]
1012 ; CHECK-NEXT: strh w8, [sp, #62]
1013 ; CHECK-NEXT: fmov w8, s4
1014 ; CHECK-NEXT: mov z4.h, z1.h[5]
1015 ; CHECK-NEXT: strh w8, [sp, #60]
1016 ; CHECK-NEXT: fmov w8, s5
1017 ; CHECK-NEXT: mov z5.h, z1.h[3]
1018 ; CHECK-NEXT: mov z1.h, z1.h[1]
1019 ; CHECK-NEXT: strh w8, [sp, #58]
1020 ; CHECK-NEXT: fmov w8, s3
1021 ; CHECK-NEXT: mov z3.h, z2.h[7]
1022 ; CHECK-NEXT: strh w8, [sp, #56]
1023 ; CHECK-NEXT: fmov w8, s7
1024 ; CHECK-NEXT: strh w8, [sp, #54]
1025 ; CHECK-NEXT: fmov w8, s4
1026 ; CHECK-NEXT: mov z4.h, z2.h[5]
1027 ; CHECK-NEXT: strh w8, [sp, #52]
1028 ; CHECK-NEXT: fmov w8, s5
1029 ; CHECK-NEXT: mov z5.h, z2.h[3]
1030 ; CHECK-NEXT: strh w8, [sp, #50]
1031 ; CHECK-NEXT: fmov w8, s1
1032 ; CHECK-NEXT: mov z1.h, z2.h[1]
1033 ; CHECK-NEXT: mov z2.h, z0.h[7]
1034 ; CHECK-NEXT: strh w8, [sp, #48]
1035 ; CHECK-NEXT: fmov w8, s3
1036 ; CHECK-NEXT: mov z3.h, z0.h[5]
1037 ; CHECK-NEXT: strh w8, [sp, #30]
1038 ; CHECK-NEXT: fmov w8, s4
1039 ; CHECK-NEXT: mov z4.h, z0.h[3]
1040 ; CHECK-NEXT: mov z0.h, z0.h[1]
1041 ; CHECK-NEXT: strh w8, [sp, #28]
1042 ; CHECK-NEXT: fmov w8, s5
1043 ; CHECK-NEXT: strh w8, [sp, #26]
1044 ; CHECK-NEXT: fmov w8, s1
1045 ; CHECK-NEXT: strh w8, [sp, #24]
1046 ; CHECK-NEXT: fmov w8, s2
1047 ; CHECK-NEXT: strh w8, [sp, #22]
1048 ; CHECK-NEXT: fmov w8, s3
1049 ; CHECK-NEXT: strh w8, [sp, #20]
1050 ; CHECK-NEXT: fmov w8, s4
1051 ; CHECK-NEXT: strh w8, [sp, #18]
1052 ; CHECK-NEXT: fmov w8, s0
1053 ; CHECK-NEXT: ldr q0, [sp, #48]
1054 ; CHECK-NEXT: add z0.h, z16.h, z0.h
1055 ; CHECK-NEXT: strh w8, [sp, #16]
1056 ; CHECK-NEXT: ldr q1, [sp, #16]
1057 ; CHECK-NEXT: add z1.h, z6.h, z1.h
1058 ; CHECK-NEXT: stp q0, q1, [x0]
1059 ; CHECK-NEXT: add sp, sp, #64
1061 %tmp1 = load <16 x i16>, ptr %a
1062 %tmp2 = load <16 x i16>, ptr %b
1063 %tmp3 = shufflevector <16 x i16> %tmp1, <16 x i16> %tmp2, <16 x i32> <i32 0, i32 2, i32 4, i32 6, i32 8, i32 10, i32 12, i32 14, i32 16, i32 18, i32 20, i32 22, i32 24, i32 26, i32 28, i32 30>
1064 %tmp4 = shufflevector <16 x i16> %tmp1, <16 x i16> %tmp2, <16 x i32> <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15, i32 17, i32 19, i32 21, i32 23, i32 25, i32 27, i32 29, i32 31>
1065 %tmp5 = add <16 x i16> %tmp3, %tmp4
1066 store <16 x i16> %tmp5, ptr %a
1070 define void @uzp_v8f32(ptr %a, ptr %b) #0{
1071 ; CHECK-LABEL: uzp_v8f32:
1073 ; CHECK-NEXT: sub sp, sp, #64
1074 ; CHECK-NEXT: .cfi_def_cfa_offset 64
1075 ; CHECK-NEXT: ldp q2, q0, [x0]
1076 ; CHECK-NEXT: ptrue p0.s, vl4
1077 ; CHECK-NEXT: ldp q4, q1, [x1]
1078 ; CHECK-NEXT: mov z3.s, z0.s[2]
1079 ; CHECK-NEXT: mov z5.s, z1.s[2]
1080 ; CHECK-NEXT: stp s0, s3, [sp, #24]
1081 ; CHECK-NEXT: mov z3.s, z4.s[2]
1082 ; CHECK-NEXT: stp s5, s2, [sp, #12]
1083 ; CHECK-NEXT: mov z5.s, z0.s[3]
1084 ; CHECK-NEXT: mov z0.s, z0.s[1]
1085 ; CHECK-NEXT: stp s3, s1, [sp, #4]
1086 ; CHECK-NEXT: mov z1.s, z2.s[1]
1087 ; CHECK-NEXT: stp s0, s5, [sp, #40]
1088 ; CHECK-NEXT: mov z5.s, z4.s[3]
1089 ; CHECK-NEXT: mov z4.s, z4.s[1]
1090 ; CHECK-NEXT: ldp q3, q2, [sp]
1091 ; CHECK-NEXT: str s1, [sp, #32]
1092 ; CHECK-NEXT: stp s4, s5, [sp, #48]
1093 ; CHECK-NEXT: ldp q0, q1, [sp, #32]
1094 ; CHECK-NEXT: fadd z0.s, p0/m, z0.s, z2.s
1095 ; CHECK-NEXT: fadd z1.s, p0/m, z1.s, z3.s
1096 ; CHECK-NEXT: stp q0, q1, [x0]
1097 ; CHECK-NEXT: add sp, sp, #64
1099 %tmp1 = load <8 x float>, ptr %a
1100 %tmp2 = load <8 x float>, ptr %b
1101 %tmp3 = shufflevector <8 x float> %tmp1, <8 x float> %tmp2, <8 x i32> <i32 0, i32 undef, i32 4, i32 6, i32 undef, i32 10, i32 12, i32 14>
1102 %tmp4 = shufflevector <8 x float> %tmp1, <8 x float> %tmp2, <8 x i32> <i32 1, i32 undef, i32 5, i32 7, i32 9, i32 11, i32 undef, i32 undef>
1103 %tmp5 = fadd <8 x float> %tmp3, %tmp4
1104 store <8 x float> %tmp5, ptr %a
1108 define void @uzp_v4i64(ptr %a, ptr %b) #0{
1109 ; CHECK-LABEL: uzp_v4i64:
1111 ; CHECK-NEXT: ldp q1, q0, [x0]
1112 ; CHECK-NEXT: ldp q3, q2, [x1]
1113 ; CHECK-NEXT: zip1 z4.d, z1.d, z0.d
1114 ; CHECK-NEXT: trn2 z0.d, z1.d, z0.d
1115 ; CHECK-NEXT: zip1 z1.d, z3.d, z2.d
1116 ; CHECK-NEXT: trn2 z2.d, z3.d, z2.d
1117 ; CHECK-NEXT: add z0.d, z4.d, z0.d
1118 ; CHECK-NEXT: add z1.d, z1.d, z2.d
1119 ; CHECK-NEXT: stp q0, q1, [x0]
1121 %tmp1 = load <4 x i64>, ptr %a
1122 %tmp2 = load <4 x i64>, ptr %b
1123 %tmp3 = shufflevector <4 x i64> %tmp1, <4 x i64> %tmp2, <4 x i32> <i32 0, i32 2, i32 4, i32 6>
1124 %tmp4 = shufflevector <4 x i64> %tmp1, <4 x i64> %tmp2, <4 x i32> <i32 1, i32 3, i32 5, i32 7>
1125 %tmp5 = add <4 x i64> %tmp3, %tmp4
1126 store <4 x i64> %tmp5, ptr %a
1130 define void @uzp_v8i16(ptr %a, ptr %b) #0{
1131 ; CHECK-LABEL: uzp_v8i16:
1133 ; CHECK-NEXT: sub sp, sp, #32
1134 ; CHECK-NEXT: .cfi_def_cfa_offset 32
1135 ; CHECK-NEXT: ldr q0, [x1]
1136 ; CHECK-NEXT: ldr q1, [x0]
1137 ; CHECK-NEXT: fmov w8, s0
1138 ; CHECK-NEXT: mov z2.h, z0.h[6]
1139 ; CHECK-NEXT: mov z3.h, z0.h[4]
1140 ; CHECK-NEXT: mov z4.h, z0.h[2]
1141 ; CHECK-NEXT: mov z5.h, z1.h[6]
1142 ; CHECK-NEXT: mov z6.h, z1.h[4]
1143 ; CHECK-NEXT: strh w8, [sp, #8]
1144 ; CHECK-NEXT: fmov w8, s1
1145 ; CHECK-NEXT: strh w8, [sp]
1146 ; CHECK-NEXT: fmov w8, s2
1147 ; CHECK-NEXT: mov z2.h, z1.h[2]
1148 ; CHECK-NEXT: strh w8, [sp, #14]
1149 ; CHECK-NEXT: fmov w8, s3
1150 ; CHECK-NEXT: mov z3.h, z0.h[7]
1151 ; CHECK-NEXT: strh w8, [sp, #12]
1152 ; CHECK-NEXT: fmov w8, s4
1153 ; CHECK-NEXT: mov z4.h, z0.h[5]
1154 ; CHECK-NEXT: strh w8, [sp, #10]
1155 ; CHECK-NEXT: fmov w8, s5
1156 ; CHECK-NEXT: mov z5.h, z0.h[3]
1157 ; CHECK-NEXT: mov z0.h, z0.h[1]
1158 ; CHECK-NEXT: strh w8, [sp, #6]
1159 ; CHECK-NEXT: fmov w8, s6
1160 ; CHECK-NEXT: strh w8, [sp, #4]
1161 ; CHECK-NEXT: fmov w8, s2
1162 ; CHECK-NEXT: mov z2.h, z1.h[7]
1163 ; CHECK-NEXT: strh w8, [sp, #2]
1164 ; CHECK-NEXT: fmov w8, s3
1165 ; CHECK-NEXT: strh w8, [sp, #30]
1166 ; CHECK-NEXT: fmov w8, s4
1167 ; CHECK-NEXT: mov z4.h, z1.h[5]
1168 ; CHECK-NEXT: strh w8, [sp, #28]
1169 ; CHECK-NEXT: fmov w8, s5
1170 ; CHECK-NEXT: mov z5.h, z1.h[3]
1171 ; CHECK-NEXT: strh w8, [sp, #26]
1172 ; CHECK-NEXT: fmov w8, s0
1173 ; CHECK-NEXT: mov z0.h, z1.h[1]
1174 ; CHECK-NEXT: strh w8, [sp, #24]
1175 ; CHECK-NEXT: fmov w8, s2
1176 ; CHECK-NEXT: strh w8, [sp, #22]
1177 ; CHECK-NEXT: fmov w8, s4
1178 ; CHECK-NEXT: strh w8, [sp, #20]
1179 ; CHECK-NEXT: fmov w8, s5
1180 ; CHECK-NEXT: strh w8, [sp, #18]
1181 ; CHECK-NEXT: fmov w8, s0
1182 ; CHECK-NEXT: strh w8, [sp, #16]
1183 ; CHECK-NEXT: ldp q3, q0, [sp]
1184 ; CHECK-NEXT: add z0.h, z3.h, z0.h
1185 ; CHECK-NEXT: str q0, [x0]
1186 ; CHECK-NEXT: add sp, sp, #32
1188 %tmp1 = load <8 x i16>, ptr %a
1189 %tmp2 = load <8 x i16>, ptr %b
1190 %tmp3 = shufflevector <8 x i16> %tmp1, <8 x i16> %tmp2, <8 x i32> <i32 0, i32 2, i32 4, i32 6, i32 8, i32 10, i32 12, i32 14>
1191 %tmp4 = shufflevector <8 x i16> %tmp1, <8 x i16> %tmp2, <8 x i32> <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15>
1192 %tmp5 = add <8 x i16> %tmp3, %tmp4
1193 store <8 x i16> %tmp5, ptr %a
1197 define void @uzp_v8i32_undef(ptr %a) #0{
1198 ; CHECK-LABEL: uzp_v8i32_undef:
1200 ; CHECK-NEXT: sub sp, sp, #32
1201 ; CHECK-NEXT: .cfi_def_cfa_offset 32
1202 ; CHECK-NEXT: ldp q1, q0, [x0]
1203 ; CHECK-NEXT: mov z2.s, z0.s[2]
1204 ; CHECK-NEXT: fmov w8, s0
1205 ; CHECK-NEXT: mov z3.s, z1.s[2]
1206 ; CHECK-NEXT: mov z4.s, z0.s[3]
1207 ; CHECK-NEXT: mov z0.s, z0.s[1]
1208 ; CHECK-NEXT: fmov w9, s2
1209 ; CHECK-NEXT: mov z2.s, z1.s[3]
1210 ; CHECK-NEXT: stp w8, w9, [sp, #8]
1211 ; CHECK-NEXT: fmov w8, s1
1212 ; CHECK-NEXT: fmov w9, s3
1213 ; CHECK-NEXT: mov z1.s, z1.s[1]
1214 ; CHECK-NEXT: stp w8, w9, [sp]
1215 ; CHECK-NEXT: fmov w8, s4
1216 ; CHECK-NEXT: fmov w9, s0
1217 ; CHECK-NEXT: stp w9, w8, [sp, #24]
1218 ; CHECK-NEXT: fmov w8, s2
1219 ; CHECK-NEXT: fmov w9, s1
1220 ; CHECK-NEXT: stp w9, w8, [sp, #16]
1221 ; CHECK-NEXT: ldp q0, q1, [sp]
1222 ; CHECK-NEXT: add z0.s, z0.s, z1.s
1223 ; CHECK-NEXT: stp q0, q0, [x0]
1224 ; CHECK-NEXT: add sp, sp, #32
1226 %tmp1 = load <8 x i32>, ptr %a
1227 %tmp3 = shufflevector <8 x i32> %tmp1, <8 x i32> undef, <8 x i32> <i32 0, i32 2, i32 4, i32 6, i32 0, i32 2, i32 4, i32 6>
1228 %tmp4 = shufflevector <8 x i32> %tmp1, <8 x i32> undef, <8 x i32> <i32 1, i32 3, i32 5, i32 7, i32 1, i32 3, i32 5, i32 7>
1229 %tmp5 = add <8 x i32> %tmp3, %tmp4
1230 store <8 x i32> %tmp5, ptr %a
1234 define void @zip_vscale2_4(ptr %a, ptr %b) {
1235 ; CHECK-LABEL: zip_vscale2_4:
1237 ; CHECK-NEXT: ldp q1, q0, [x0]
1238 ; CHECK-NEXT: ptrue p0.d, vl2
1239 ; CHECK-NEXT: ldp q3, q2, [x1]
1240 ; CHECK-NEXT: zip1 z4.d, z1.d, z3.d
1241 ; CHECK-NEXT: zip1 z5.d, z0.d, z2.d
1242 ; CHECK-NEXT: trn2 z1.d, z1.d, z3.d
1243 ; CHECK-NEXT: trn2 z0.d, z0.d, z2.d
1244 ; CHECK-NEXT: movprfx z2, z4
1245 ; CHECK-NEXT: fadd z2.d, p0/m, z2.d, z5.d
1246 ; CHECK-NEXT: fadd z0.d, p0/m, z0.d, z1.d
1247 ; CHECK-NEXT: stp q2, q0, [x0]
1249 %tmp1 = load <4 x double>, ptr %a
1250 %tmp2 = load <4 x double>, ptr %b
1251 %tmp3 = shufflevector <4 x double> %tmp1, <4 x double> %tmp2, <4 x i32> <i32 0, i32 4, i32 1, i32 5>
1252 %tmp4 = shufflevector <4 x double> %tmp1, <4 x double> %tmp2, <4 x i32> <i32 2, i32 6, i32 3, i32 7>
1253 %tmp5 = fadd <4 x double> %tmp3, %tmp4
1254 store <4 x double> %tmp5, ptr %a