1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mattr=+sve -force-streaming-compatible < %s | FileCheck %s
3 ; RUN: llc -force-streaming-compatible < %s | FileCheck %s --check-prefix=NONEON-NOSVE
5 target triple = "aarch64-unknown-linux-gnu"
12 define <4 x i8> @insertelement_v4i8(<4 x i8> %op1) {
13 ; CHECK-LABEL: insertelement_v4i8:
15 ; CHECK-NEXT: mov w8, #3 // =0x3
16 ; CHECK-NEXT: index z1.h, #0, #1
17 ; CHECK-NEXT: ptrue p0.h
18 ; CHECK-NEXT: mov z2.h, w8
19 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
20 ; CHECK-NEXT: mov w8, #5 // =0x5
21 ; CHECK-NEXT: cmpeq p0.h, p0/z, z1.h, z2.h
22 ; CHECK-NEXT: mov z0.h, p0/m, w8
23 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
26 ; NONEON-NOSVE-LABEL: insertelement_v4i8:
27 ; NONEON-NOSVE: // %bb.0:
28 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
29 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
30 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
31 ; NONEON-NOSVE-NEXT: str d0, [sp]
32 ; NONEON-NOSVE-NEXT: strh w8, [sp, #24]
33 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #4]
34 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
35 ; NONEON-NOSVE-NEXT: strh w8, [sp, #20]
36 ; NONEON-NOSVE-NEXT: ldr w8, [sp]
37 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
38 ; NONEON-NOSVE-NEXT: str w8, [sp, #16]
39 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #8]
40 ; NONEON-NOSVE-NEXT: strh w8, [sp, #22]
41 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
42 ; NONEON-NOSVE-NEXT: add sp, sp, #32
43 ; NONEON-NOSVE-NEXT: ret
44 %r = insertelement <4 x i8> %op1, i8 5, i64 3
48 define <8 x i8> @insertelement_v8i8(<8 x i8> %op1) {
49 ; CHECK-LABEL: insertelement_v8i8:
51 ; CHECK-NEXT: mov w8, #7 // =0x7
52 ; CHECK-NEXT: index z1.b, #0, #1
53 ; CHECK-NEXT: ptrue p0.b
54 ; CHECK-NEXT: mov z2.b, w8
55 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
56 ; CHECK-NEXT: mov w8, #5 // =0x5
57 ; CHECK-NEXT: cmpeq p0.b, p0/z, z1.b, z2.b
58 ; CHECK-NEXT: mov z0.b, p0/m, w8
59 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
62 ; NONEON-NOSVE-LABEL: insertelement_v8i8:
63 ; NONEON-NOSVE: // %bb.0:
64 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
65 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
66 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
67 ; NONEON-NOSVE-NEXT: str d0, [sp]
68 ; NONEON-NOSVE-NEXT: strb w8, [sp, #24]
69 ; NONEON-NOSVE-NEXT: ldrb w8, [sp, #6]
70 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
71 ; NONEON-NOSVE-NEXT: strb w8, [sp, #22]
72 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #4]
73 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
74 ; NONEON-NOSVE-NEXT: strh w8, [sp, #20]
75 ; NONEON-NOSVE-NEXT: ldr w8, [sp]
76 ; NONEON-NOSVE-NEXT: str w8, [sp, #16]
77 ; NONEON-NOSVE-NEXT: ldrb w8, [sp, #8]
78 ; NONEON-NOSVE-NEXT: strb w8, [sp, #23]
79 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
80 ; NONEON-NOSVE-NEXT: add sp, sp, #32
81 ; NONEON-NOSVE-NEXT: ret
82 %r = insertelement <8 x i8> %op1, i8 5, i64 7
86 define <16 x i8> @insertelement_v16i8(<16 x i8> %op1) {
87 ; CHECK-LABEL: insertelement_v16i8:
89 ; CHECK-NEXT: mov w8, #15 // =0xf
90 ; CHECK-NEXT: index z1.b, #0, #1
91 ; CHECK-NEXT: ptrue p0.b
92 ; CHECK-NEXT: mov z2.b, w8
93 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
94 ; CHECK-NEXT: mov w8, #5 // =0x5
95 ; CHECK-NEXT: cmpeq p0.b, p0/z, z1.b, z2.b
96 ; CHECK-NEXT: mov z0.b, p0/m, w8
97 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
100 ; NONEON-NOSVE-LABEL: insertelement_v16i8:
101 ; NONEON-NOSVE: // %bb.0:
102 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
103 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
104 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
105 ; NONEON-NOSVE-NEXT: str q0, [sp]
106 ; NONEON-NOSVE-NEXT: strb w8, [sp, #48]
107 ; NONEON-NOSVE-NEXT: ldrb w8, [sp, #14]
108 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
109 ; NONEON-NOSVE-NEXT: strb w8, [sp, #46]
110 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #12]
111 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
112 ; NONEON-NOSVE-NEXT: strh w8, [sp, #44]
113 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
114 ; NONEON-NOSVE-NEXT: str w8, [sp, #40]
115 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
116 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
117 ; NONEON-NOSVE-NEXT: ldrb w8, [sp, #16]
118 ; NONEON-NOSVE-NEXT: strb w8, [sp, #47]
119 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
120 ; NONEON-NOSVE-NEXT: add sp, sp, #64
121 ; NONEON-NOSVE-NEXT: ret
122 %r = insertelement <16 x i8> %op1, i8 5, i64 15
126 define <32 x i8> @insertelement_v32i8(<32 x i8> %op1) {
127 ; CHECK-LABEL: insertelement_v32i8:
129 ; CHECK-NEXT: mov w8, #15 // =0xf
130 ; CHECK-NEXT: index z2.b, #0, #1
131 ; CHECK-NEXT: ptrue p0.b
132 ; CHECK-NEXT: mov z3.b, w8
133 ; CHECK-NEXT: // kill: def $q1 killed $q1 def $z1
134 ; CHECK-NEXT: mov w8, #5 // =0x5
135 ; CHECK-NEXT: cmpeq p0.b, p0/z, z2.b, z3.b
136 ; CHECK-NEXT: mov z1.b, p0/m, w8
137 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
140 ; NONEON-NOSVE-LABEL: insertelement_v32i8:
141 ; NONEON-NOSVE: // %bb.0:
142 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
143 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
144 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
145 ; NONEON-NOSVE-NEXT: str q1, [sp]
146 ; NONEON-NOSVE-NEXT: strb w8, [sp, #48]
147 ; NONEON-NOSVE-NEXT: ldrb w8, [sp, #14]
148 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #48]
149 ; NONEON-NOSVE-NEXT: strb w8, [sp, #46]
150 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #12]
151 ; NONEON-NOSVE-NEXT: str q1, [sp, #16]
152 ; NONEON-NOSVE-NEXT: strh w8, [sp, #44]
153 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
154 ; NONEON-NOSVE-NEXT: str w8, [sp, #40]
155 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
156 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
157 ; NONEON-NOSVE-NEXT: ldrb w8, [sp, #16]
158 ; NONEON-NOSVE-NEXT: strb w8, [sp, #47]
159 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
160 ; NONEON-NOSVE-NEXT: add sp, sp, #64
161 ; NONEON-NOSVE-NEXT: ret
162 %r = insertelement <32 x i8> %op1, i8 5, i64 31
167 define <2 x i16> @insertelement_v2i16(<2 x i16> %op1) {
168 ; CHECK-LABEL: insertelement_v2i16:
170 ; CHECK-NEXT: mov w8, #1 // =0x1
171 ; CHECK-NEXT: index z1.s, #0, #1
172 ; CHECK-NEXT: ptrue p0.s
173 ; CHECK-NEXT: mov z2.s, w8
174 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
175 ; CHECK-NEXT: mov w8, #5 // =0x5
176 ; CHECK-NEXT: cmpeq p0.s, p0/z, z1.s, z2.s
177 ; CHECK-NEXT: mov z0.s, p0/m, w8
178 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
181 ; NONEON-NOSVE-LABEL: insertelement_v2i16:
182 ; NONEON-NOSVE: // %bb.0:
183 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
184 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
185 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
186 ; NONEON-NOSVE-NEXT: str d0, [sp]
187 ; NONEON-NOSVE-NEXT: str w8, [sp, #24]
188 ; NONEON-NOSVE-NEXT: ldr w9, [sp]
189 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
190 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
191 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
192 ; NONEON-NOSVE-NEXT: stp w9, w8, [sp, #16]
193 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
194 ; NONEON-NOSVE-NEXT: add sp, sp, #32
195 ; NONEON-NOSVE-NEXT: ret
196 %r = insertelement <2 x i16> %op1, i16 5, i64 1
200 define <4 x i16> @insertelement_v4i16(<4 x i16> %op1) {
201 ; CHECK-LABEL: insertelement_v4i16:
203 ; CHECK-NEXT: mov w8, #3 // =0x3
204 ; CHECK-NEXT: index z1.h, #0, #1
205 ; CHECK-NEXT: ptrue p0.h
206 ; CHECK-NEXT: mov z2.h, w8
207 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
208 ; CHECK-NEXT: mov w8, #5 // =0x5
209 ; CHECK-NEXT: cmpeq p0.h, p0/z, z1.h, z2.h
210 ; CHECK-NEXT: mov z0.h, p0/m, w8
211 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
214 ; NONEON-NOSVE-LABEL: insertelement_v4i16:
215 ; NONEON-NOSVE: // %bb.0:
216 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
217 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
218 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
219 ; NONEON-NOSVE-NEXT: str d0, [sp]
220 ; NONEON-NOSVE-NEXT: strh w8, [sp, #24]
221 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #4]
222 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
223 ; NONEON-NOSVE-NEXT: strh w8, [sp, #20]
224 ; NONEON-NOSVE-NEXT: ldr w8, [sp]
225 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
226 ; NONEON-NOSVE-NEXT: str w8, [sp, #16]
227 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #8]
228 ; NONEON-NOSVE-NEXT: strh w8, [sp, #22]
229 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
230 ; NONEON-NOSVE-NEXT: add sp, sp, #32
231 ; NONEON-NOSVE-NEXT: ret
232 %r = insertelement <4 x i16> %op1, i16 5, i64 3
236 define <8 x i16> @insertelement_v8i16(<8 x i16> %op1) {
237 ; CHECK-LABEL: insertelement_v8i16:
239 ; CHECK-NEXT: mov w8, #7 // =0x7
240 ; CHECK-NEXT: index z1.h, #0, #1
241 ; CHECK-NEXT: ptrue p0.h
242 ; CHECK-NEXT: mov z2.h, w8
243 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
244 ; CHECK-NEXT: mov w8, #5 // =0x5
245 ; CHECK-NEXT: cmpeq p0.h, p0/z, z1.h, z2.h
246 ; CHECK-NEXT: mov z0.h, p0/m, w8
247 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
250 ; NONEON-NOSVE-LABEL: insertelement_v8i16:
251 ; NONEON-NOSVE: // %bb.0:
252 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
253 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
254 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
255 ; NONEON-NOSVE-NEXT: str q0, [sp]
256 ; NONEON-NOSVE-NEXT: strh w8, [sp, #48]
257 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #12]
258 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
259 ; NONEON-NOSVE-NEXT: strh w8, [sp, #44]
260 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
261 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
262 ; NONEON-NOSVE-NEXT: str w8, [sp, #40]
263 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
264 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
265 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #16]
266 ; NONEON-NOSVE-NEXT: strh w8, [sp, #46]
267 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
268 ; NONEON-NOSVE-NEXT: add sp, sp, #64
269 ; NONEON-NOSVE-NEXT: ret
270 %r = insertelement <8 x i16> %op1, i16 5, i64 7
274 define <16 x i16> @insertelement_v16i16(<16 x i16> %op1) {
275 ; CHECK-LABEL: insertelement_v16i16:
277 ; CHECK-NEXT: mov w8, #7 // =0x7
278 ; CHECK-NEXT: index z2.h, #0, #1
279 ; CHECK-NEXT: ptrue p0.h
280 ; CHECK-NEXT: mov z3.h, w8
281 ; CHECK-NEXT: // kill: def $q1 killed $q1 def $z1
282 ; CHECK-NEXT: mov w8, #5 // =0x5
283 ; CHECK-NEXT: cmpeq p0.h, p0/z, z2.h, z3.h
284 ; CHECK-NEXT: mov z1.h, p0/m, w8
285 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
288 ; NONEON-NOSVE-LABEL: insertelement_v16i16:
289 ; NONEON-NOSVE: // %bb.0:
290 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
291 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
292 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
293 ; NONEON-NOSVE-NEXT: str q1, [sp]
294 ; NONEON-NOSVE-NEXT: strh w8, [sp, #48]
295 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #12]
296 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #48]
297 ; NONEON-NOSVE-NEXT: strh w8, [sp, #44]
298 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
299 ; NONEON-NOSVE-NEXT: str q1, [sp, #16]
300 ; NONEON-NOSVE-NEXT: str w8, [sp, #40]
301 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
302 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
303 ; NONEON-NOSVE-NEXT: ldrh w8, [sp, #16]
304 ; NONEON-NOSVE-NEXT: strh w8, [sp, #46]
305 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
306 ; NONEON-NOSVE-NEXT: add sp, sp, #64
307 ; NONEON-NOSVE-NEXT: ret
308 %r = insertelement <16 x i16> %op1, i16 5, i64 15
313 define <2 x i32> @insertelement_v2i32(<2 x i32> %op1) {
314 ; CHECK-LABEL: insertelement_v2i32:
316 ; CHECK-NEXT: mov w8, #1 // =0x1
317 ; CHECK-NEXT: index z1.s, #0, #1
318 ; CHECK-NEXT: ptrue p0.s
319 ; CHECK-NEXT: mov z2.s, w8
320 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
321 ; CHECK-NEXT: mov w8, #5 // =0x5
322 ; CHECK-NEXT: cmpeq p0.s, p0/z, z1.s, z2.s
323 ; CHECK-NEXT: mov z0.s, p0/m, w8
324 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
327 ; NONEON-NOSVE-LABEL: insertelement_v2i32:
328 ; NONEON-NOSVE: // %bb.0:
329 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
330 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
331 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
332 ; NONEON-NOSVE-NEXT: str d0, [sp]
333 ; NONEON-NOSVE-NEXT: str w8, [sp, #24]
334 ; NONEON-NOSVE-NEXT: ldr w9, [sp]
335 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
336 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
337 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
338 ; NONEON-NOSVE-NEXT: stp w9, w8, [sp, #16]
339 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
340 ; NONEON-NOSVE-NEXT: add sp, sp, #32
341 ; NONEON-NOSVE-NEXT: ret
342 %r = insertelement <2 x i32> %op1, i32 5, i64 1
346 define <4 x i32> @insertelement_v4i32(<4 x i32> %op1) {
347 ; CHECK-LABEL: insertelement_v4i32:
349 ; CHECK-NEXT: mov w8, #3 // =0x3
350 ; CHECK-NEXT: index z1.s, #0, #1
351 ; CHECK-NEXT: ptrue p0.s
352 ; CHECK-NEXT: mov z2.s, w8
353 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
354 ; CHECK-NEXT: mov w8, #5 // =0x5
355 ; CHECK-NEXT: cmpeq p0.s, p0/z, z1.s, z2.s
356 ; CHECK-NEXT: mov z0.s, p0/m, w8
357 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
360 ; NONEON-NOSVE-LABEL: insertelement_v4i32:
361 ; NONEON-NOSVE: // %bb.0:
362 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
363 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
364 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
365 ; NONEON-NOSVE-NEXT: str q0, [sp]
366 ; NONEON-NOSVE-NEXT: str w8, [sp, #48]
367 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
368 ; NONEON-NOSVE-NEXT: ldr w9, [sp, #8]
369 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
370 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
371 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
372 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #16]
373 ; NONEON-NOSVE-NEXT: stp w9, w8, [sp, #40]
374 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
375 ; NONEON-NOSVE-NEXT: add sp, sp, #64
376 ; NONEON-NOSVE-NEXT: ret
377 %r = insertelement <4 x i32> %op1, i32 5, i64 3
381 define <8 x i32> @insertelement_v8i32(ptr %a) {
382 ; CHECK-LABEL: insertelement_v8i32:
384 ; CHECK-NEXT: mov w8, #3 // =0x3
385 ; CHECK-NEXT: index z0.s, #0, #1
386 ; CHECK-NEXT: ptrue p0.s
387 ; CHECK-NEXT: mov z1.s, w8
388 ; CHECK-NEXT: mov w8, #5 // =0x5
389 ; CHECK-NEXT: cmpeq p0.s, p0/z, z0.s, z1.s
390 ; CHECK-NEXT: ldp q0, q1, [x0]
391 ; CHECK-NEXT: mov z1.s, p0/m, w8
392 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
395 ; NONEON-NOSVE-LABEL: insertelement_v8i32:
396 ; NONEON-NOSVE: // %bb.0:
397 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
398 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
399 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
400 ; NONEON-NOSVE-NEXT: ldp q0, q2, [x0]
401 ; NONEON-NOSVE-NEXT: str w8, [sp, #48]
402 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #48]
403 ; NONEON-NOSVE-NEXT: stp q2, q1, [sp]
404 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
405 ; NONEON-NOSVE-NEXT: ldr w9, [sp, #8]
406 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
407 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #16]
408 ; NONEON-NOSVE-NEXT: stp w9, w8, [sp, #40]
409 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
410 ; NONEON-NOSVE-NEXT: add sp, sp, #64
411 ; NONEON-NOSVE-NEXT: ret
412 %op1 = load <8 x i32>, ptr %a
413 %r = insertelement <8 x i32> %op1, i32 5, i64 7
418 define <1 x i64> @insertelement_v1i64(<1 x i64> %op1) {
419 ; CHECK-LABEL: insertelement_v1i64:
421 ; CHECK-NEXT: mov z0.d, #5 // =0x5
422 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
425 ; NONEON-NOSVE-LABEL: insertelement_v1i64:
426 ; NONEON-NOSVE: // %bb.0:
427 ; NONEON-NOSVE-NEXT: sub sp, sp, #16
428 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 16
429 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
430 ; NONEON-NOSVE-NEXT: str x8, [sp, #8]
431 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #8]
432 ; NONEON-NOSVE-NEXT: add sp, sp, #16
433 ; NONEON-NOSVE-NEXT: ret
434 %r = insertelement <1 x i64> %op1, i64 5, i64 0
438 define <2 x i64> @insertelement_v2i64(<2 x i64> %op1) {
439 ; CHECK-LABEL: insertelement_v2i64:
441 ; CHECK-NEXT: mov w8, #1 // =0x1
442 ; CHECK-NEXT: index z1.d, #0, #1
443 ; CHECK-NEXT: ptrue p0.d
444 ; CHECK-NEXT: mov z2.d, x8
445 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
446 ; CHECK-NEXT: mov w8, #5 // =0x5
447 ; CHECK-NEXT: cmpeq p0.d, p0/z, z1.d, z2.d
448 ; CHECK-NEXT: mov z0.d, p0/m, x8
449 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
452 ; NONEON-NOSVE-LABEL: insertelement_v2i64:
453 ; NONEON-NOSVE: // %bb.0:
454 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
455 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
456 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
457 ; NONEON-NOSVE-NEXT: str q0, [sp]
458 ; NONEON-NOSVE-NEXT: str x8, [sp, #48]
459 ; NONEON-NOSVE-NEXT: ldr x9, [sp]
460 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
461 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
462 ; NONEON-NOSVE-NEXT: ldr x8, [sp, #16]
463 ; NONEON-NOSVE-NEXT: stp x9, x8, [sp, #32]
464 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
465 ; NONEON-NOSVE-NEXT: add sp, sp, #64
466 ; NONEON-NOSVE-NEXT: ret
467 %r = insertelement <2 x i64> %op1, i64 5, i64 1
471 define <4 x i64> @insertelement_v4i64(ptr %a) {
472 ; CHECK-LABEL: insertelement_v4i64:
474 ; CHECK-NEXT: mov w8, #1 // =0x1
475 ; CHECK-NEXT: index z0.d, #0, #1
476 ; CHECK-NEXT: ptrue p0.d
477 ; CHECK-NEXT: mov z1.d, x8
478 ; CHECK-NEXT: mov w8, #5 // =0x5
479 ; CHECK-NEXT: cmpeq p0.d, p0/z, z0.d, z1.d
480 ; CHECK-NEXT: ldp q0, q1, [x0]
481 ; CHECK-NEXT: mov z1.d, p0/m, x8
482 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
485 ; NONEON-NOSVE-LABEL: insertelement_v4i64:
486 ; NONEON-NOSVE: // %bb.0:
487 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
488 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
489 ; NONEON-NOSVE-NEXT: mov w8, #5 // =0x5
490 ; NONEON-NOSVE-NEXT: ldp q0, q2, [x0]
491 ; NONEON-NOSVE-NEXT: str x8, [sp, #48]
492 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #48]
493 ; NONEON-NOSVE-NEXT: stp q2, q1, [sp]
494 ; NONEON-NOSVE-NEXT: ldr x9, [sp]
495 ; NONEON-NOSVE-NEXT: ldr x8, [sp, #16]
496 ; NONEON-NOSVE-NEXT: stp x9, x8, [sp, #32]
497 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
498 ; NONEON-NOSVE-NEXT: add sp, sp, #64
499 ; NONEON-NOSVE-NEXT: ret
500 %op1 = load <4 x i64>, ptr %a
501 %r = insertelement <4 x i64> %op1, i64 5, i64 3
506 define <2 x half> @insertelement_v2f16(<2 x half> %op1) {
507 ; CHECK-LABEL: insertelement_v2f16:
509 ; CHECK-NEXT: sub sp, sp, #16
510 ; CHECK-NEXT: .cfi_def_cfa_offset 16
511 ; CHECK-NEXT: fmov h1, #5.00000000
512 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
513 ; CHECK-NEXT: str h0, [sp, #8]
514 ; CHECK-NEXT: str h1, [sp, #10]
515 ; CHECK-NEXT: ldr d0, [sp, #8]
516 ; CHECK-NEXT: add sp, sp, #16
519 ; NONEON-NOSVE-LABEL: insertelement_v2f16:
520 ; NONEON-NOSVE: // %bb.0:
521 ; NONEON-NOSVE-NEXT: adrp x8, .LCPI14_0
522 ; NONEON-NOSVE-NEXT: str d0, [sp, #-16]!
523 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 16
524 ; NONEON-NOSVE-NEXT: ldr h0, [x8, :lo12:.LCPI14_0]
525 ; NONEON-NOSVE-NEXT: ldr h1, [sp]
526 ; NONEON-NOSVE-NEXT: str h0, [sp, #10]
527 ; NONEON-NOSVE-NEXT: str h1, [sp, #8]
528 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #8]
529 ; NONEON-NOSVE-NEXT: add sp, sp, #16
530 ; NONEON-NOSVE-NEXT: ret
531 %r = insertelement <2 x half> %op1, half 5.0, i64 1
535 define <4 x half> @insertelement_v4f16(<4 x half> %op1) {
536 ; CHECK-LABEL: insertelement_v4f16:
538 ; CHECK-NEXT: mov w8, #3 // =0x3
539 ; CHECK-NEXT: index z1.h, #0, #1
540 ; CHECK-NEXT: ptrue p0.h
541 ; CHECK-NEXT: mov z2.h, w8
542 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
543 ; CHECK-NEXT: cmpeq p0.h, p0/z, z1.h, z2.h
544 ; CHECK-NEXT: fmov h1, #5.00000000
545 ; CHECK-NEXT: mov z0.h, p0/m, h1
546 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
549 ; NONEON-NOSVE-LABEL: insertelement_v4f16:
550 ; NONEON-NOSVE: // %bb.0:
551 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
552 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
553 ; NONEON-NOSVE-NEXT: adrp x8, .LCPI15_0
554 ; NONEON-NOSVE-NEXT: str d0, [sp]
555 ; NONEON-NOSVE-NEXT: ldr h1, [x8, :lo12:.LCPI15_0]
556 ; NONEON-NOSVE-NEXT: ldr w8, [sp]
557 ; NONEON-NOSVE-NEXT: str h1, [sp, #24]
558 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
559 ; NONEON-NOSVE-NEXT: str w8, [sp, #16]
560 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
561 ; NONEON-NOSVE-NEXT: ldr h0, [sp, #4]
562 ; NONEON-NOSVE-NEXT: str h0, [sp, #20]
563 ; NONEON-NOSVE-NEXT: ldr h0, [sp, #8]
564 ; NONEON-NOSVE-NEXT: str h0, [sp, #22]
565 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
566 ; NONEON-NOSVE-NEXT: add sp, sp, #32
567 ; NONEON-NOSVE-NEXT: ret
568 %r = insertelement <4 x half> %op1, half 5.0, i64 3
572 define <8 x half> @insertelement_v8f16(<8 x half> %op1) {
573 ; CHECK-LABEL: insertelement_v8f16:
575 ; CHECK-NEXT: mov w8, #7 // =0x7
576 ; CHECK-NEXT: index z1.h, #0, #1
577 ; CHECK-NEXT: ptrue p0.h
578 ; CHECK-NEXT: mov z2.h, w8
579 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
580 ; CHECK-NEXT: cmpeq p0.h, p0/z, z1.h, z2.h
581 ; CHECK-NEXT: fmov h1, #5.00000000
582 ; CHECK-NEXT: mov z0.h, p0/m, h1
583 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
586 ; NONEON-NOSVE-LABEL: insertelement_v8f16:
587 ; NONEON-NOSVE: // %bb.0:
588 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
589 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
590 ; NONEON-NOSVE-NEXT: adrp x8, .LCPI16_0
591 ; NONEON-NOSVE-NEXT: str q0, [sp]
592 ; NONEON-NOSVE-NEXT: ldr h1, [x8, :lo12:.LCPI16_0]
593 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
594 ; NONEON-NOSVE-NEXT: str h1, [sp, #48]
595 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
596 ; NONEON-NOSVE-NEXT: str w8, [sp, #40]
597 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
598 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
599 ; NONEON-NOSVE-NEXT: ldr h0, [sp, #12]
600 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
601 ; NONEON-NOSVE-NEXT: str h0, [sp, #44]
602 ; NONEON-NOSVE-NEXT: ldr h0, [sp, #16]
603 ; NONEON-NOSVE-NEXT: str h0, [sp, #46]
604 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
605 ; NONEON-NOSVE-NEXT: add sp, sp, #64
606 ; NONEON-NOSVE-NEXT: ret
607 %r = insertelement <8 x half> %op1, half 5.0, i64 7
611 define <16 x half> @insertelement_v16f16(ptr %a) {
612 ; CHECK-LABEL: insertelement_v16f16:
614 ; CHECK-NEXT: mov w8, #7 // =0x7
615 ; CHECK-NEXT: index z0.h, #0, #1
616 ; CHECK-NEXT: ptrue p0.h
617 ; CHECK-NEXT: mov z1.h, w8
618 ; CHECK-NEXT: fmov h2, #5.00000000
619 ; CHECK-NEXT: cmpeq p0.h, p0/z, z0.h, z1.h
620 ; CHECK-NEXT: ldp q0, q1, [x0]
621 ; CHECK-NEXT: mov z1.h, p0/m, h2
622 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
625 ; NONEON-NOSVE-LABEL: insertelement_v16f16:
626 ; NONEON-NOSVE: // %bb.0:
627 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
628 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
629 ; NONEON-NOSVE-NEXT: adrp x8, .LCPI17_0
630 ; NONEON-NOSVE-NEXT: ldp q0, q2, [x0]
631 ; NONEON-NOSVE-NEXT: ldr h1, [x8, :lo12:.LCPI17_0]
632 ; NONEON-NOSVE-NEXT: str h1, [sp, #48]
633 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #48]
634 ; NONEON-NOSVE-NEXT: stp q2, q1, [sp]
635 ; NONEON-NOSVE-NEXT: ldr h1, [sp, #12]
636 ; NONEON-NOSVE-NEXT: ldr w8, [sp, #8]
637 ; NONEON-NOSVE-NEXT: str h1, [sp, #44]
638 ; NONEON-NOSVE-NEXT: ldr h1, [sp, #16]
639 ; NONEON-NOSVE-NEXT: str w8, [sp, #40]
640 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
641 ; NONEON-NOSVE-NEXT: str h1, [sp, #46]
642 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
643 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
644 ; NONEON-NOSVE-NEXT: add sp, sp, #64
645 ; NONEON-NOSVE-NEXT: ret
646 %op1 = load <16 x half>, ptr %a
647 %r = insertelement <16 x half> %op1, half 5.0, i64 15
652 define <2 x float> @insertelement_v2f32(<2 x float> %op1) {
653 ; CHECK-LABEL: insertelement_v2f32:
655 ; CHECK-NEXT: mov w8, #1 // =0x1
656 ; CHECK-NEXT: index z1.s, #0, #1
657 ; CHECK-NEXT: ptrue p0.s
658 ; CHECK-NEXT: mov z2.s, w8
659 ; CHECK-NEXT: // kill: def $d0 killed $d0 def $z0
660 ; CHECK-NEXT: cmpeq p0.s, p0/z, z1.s, z2.s
661 ; CHECK-NEXT: fmov s1, #5.00000000
662 ; CHECK-NEXT: mov z0.s, p0/m, s1
663 ; CHECK-NEXT: // kill: def $d0 killed $d0 killed $z0
666 ; NONEON-NOSVE-LABEL: insertelement_v2f32:
667 ; NONEON-NOSVE: // %bb.0:
668 ; NONEON-NOSVE-NEXT: sub sp, sp, #32
669 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 32
670 ; NONEON-NOSVE-NEXT: mov w8, #1084227584 // =0x40a00000
671 ; NONEON-NOSVE-NEXT: str d0, [sp]
672 ; NONEON-NOSVE-NEXT: str w8, [sp, #24]
673 ; NONEON-NOSVE-NEXT: ldr s1, [sp]
674 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #24]
675 ; NONEON-NOSVE-NEXT: str d0, [sp, #8]
676 ; NONEON-NOSVE-NEXT: ldr s0, [sp, #8]
677 ; NONEON-NOSVE-NEXT: stp s1, s0, [sp, #16]
678 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
679 ; NONEON-NOSVE-NEXT: add sp, sp, #32
680 ; NONEON-NOSVE-NEXT: ret
681 %r = insertelement <2 x float> %op1, float 5.0, i64 1
685 define <4 x float> @insertelement_v4f32(<4 x float> %op1) {
686 ; CHECK-LABEL: insertelement_v4f32:
688 ; CHECK-NEXT: mov w8, #3 // =0x3
689 ; CHECK-NEXT: index z1.s, #0, #1
690 ; CHECK-NEXT: ptrue p0.s
691 ; CHECK-NEXT: mov z2.s, w8
692 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
693 ; CHECK-NEXT: cmpeq p0.s, p0/z, z1.s, z2.s
694 ; CHECK-NEXT: fmov s1, #5.00000000
695 ; CHECK-NEXT: mov z0.s, p0/m, s1
696 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
699 ; NONEON-NOSVE-LABEL: insertelement_v4f32:
700 ; NONEON-NOSVE: // %bb.0:
701 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
702 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
703 ; NONEON-NOSVE-NEXT: mov w8, #1084227584 // =0x40a00000
704 ; NONEON-NOSVE-NEXT: str q0, [sp]
705 ; NONEON-NOSVE-NEXT: str w8, [sp, #48]
706 ; NONEON-NOSVE-NEXT: ldr s1, [sp, #8]
707 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
708 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
709 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
710 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
711 ; NONEON-NOSVE-NEXT: ldr s0, [sp, #16]
712 ; NONEON-NOSVE-NEXT: stp s1, s0, [sp, #40]
713 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
714 ; NONEON-NOSVE-NEXT: add sp, sp, #64
715 ; NONEON-NOSVE-NEXT: ret
716 %r = insertelement <4 x float> %op1, float 5.0, i64 3
720 define <8 x float> @insertelement_v8f32(ptr %a) {
721 ; CHECK-LABEL: insertelement_v8f32:
723 ; CHECK-NEXT: mov w8, #3 // =0x3
724 ; CHECK-NEXT: index z0.s, #0, #1
725 ; CHECK-NEXT: ptrue p0.s
726 ; CHECK-NEXT: mov z1.s, w8
727 ; CHECK-NEXT: fmov s2, #5.00000000
728 ; CHECK-NEXT: cmpeq p0.s, p0/z, z0.s, z1.s
729 ; CHECK-NEXT: ldp q0, q1, [x0]
730 ; CHECK-NEXT: mov z1.s, p0/m, s2
731 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
734 ; NONEON-NOSVE-LABEL: insertelement_v8f32:
735 ; NONEON-NOSVE: // %bb.0:
736 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
737 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
738 ; NONEON-NOSVE-NEXT: mov w8, #1084227584 // =0x40a00000
739 ; NONEON-NOSVE-NEXT: ldr q1, [x0, #16]
740 ; NONEON-NOSVE-NEXT: str w8, [sp, #48]
741 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
742 ; NONEON-NOSVE-NEXT: stp q1, q0, [sp]
743 ; NONEON-NOSVE-NEXT: ldr s1, [sp, #8]
744 ; NONEON-NOSVE-NEXT: ldr x8, [sp]
745 ; NONEON-NOSVE-NEXT: ldr s0, [sp, #16]
746 ; NONEON-NOSVE-NEXT: str x8, [sp, #32]
747 ; NONEON-NOSVE-NEXT: stp s1, s0, [sp, #40]
748 ; NONEON-NOSVE-NEXT: ldr q0, [x0]
749 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
750 ; NONEON-NOSVE-NEXT: add sp, sp, #64
751 ; NONEON-NOSVE-NEXT: ret
752 %op1 = load <8 x float>, ptr %a
753 %r = insertelement <8 x float> %op1, float 5.0, i64 7
758 define <1 x double> @insertelement_v1f64(<1 x double> %op1) {
759 ; CHECK-LABEL: insertelement_v1f64:
761 ; CHECK-NEXT: fmov d0, #5.00000000
764 ; NONEON-NOSVE-LABEL: insertelement_v1f64:
765 ; NONEON-NOSVE: // %bb.0:
766 ; NONEON-NOSVE-NEXT: sub sp, sp, #16
767 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 16
768 ; NONEON-NOSVE-NEXT: mov x8, #4617315517961601024 // =0x4014000000000000
769 ; NONEON-NOSVE-NEXT: str x8, [sp, #8]
770 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #8]
771 ; NONEON-NOSVE-NEXT: add sp, sp, #16
772 ; NONEON-NOSVE-NEXT: ret
773 %r = insertelement <1 x double> %op1, double 5.0, i64 0
777 define <2 x double> @insertelement_v2f64(<2 x double> %op1) {
778 ; CHECK-LABEL: insertelement_v2f64:
780 ; CHECK-NEXT: mov w8, #1 // =0x1
781 ; CHECK-NEXT: index z1.d, #0, #1
782 ; CHECK-NEXT: ptrue p0.d
783 ; CHECK-NEXT: mov z2.d, x8
784 ; CHECK-NEXT: // kill: def $q0 killed $q0 def $z0
785 ; CHECK-NEXT: cmpeq p0.d, p0/z, z1.d, z2.d
786 ; CHECK-NEXT: fmov d1, #5.00000000
787 ; CHECK-NEXT: mov z0.d, p0/m, d1
788 ; CHECK-NEXT: // kill: def $q0 killed $q0 killed $z0
791 ; NONEON-NOSVE-LABEL: insertelement_v2f64:
792 ; NONEON-NOSVE: // %bb.0:
793 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
794 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
795 ; NONEON-NOSVE-NEXT: mov x8, #4617315517961601024 // =0x4014000000000000
796 ; NONEON-NOSVE-NEXT: str q0, [sp]
797 ; NONEON-NOSVE-NEXT: str x8, [sp, #48]
798 ; NONEON-NOSVE-NEXT: ldr d1, [sp]
799 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
800 ; NONEON-NOSVE-NEXT: str q0, [sp, #16]
801 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
802 ; NONEON-NOSVE-NEXT: stp d1, d0, [sp, #32]
803 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #32]
804 ; NONEON-NOSVE-NEXT: add sp, sp, #64
805 ; NONEON-NOSVE-NEXT: ret
806 %r = insertelement <2 x double> %op1, double 5.0, i64 1
810 define <4 x double> @insertelement_v4f64(ptr %a) {
811 ; CHECK-LABEL: insertelement_v4f64:
813 ; CHECK-NEXT: mov w8, #1 // =0x1
814 ; CHECK-NEXT: index z0.d, #0, #1
815 ; CHECK-NEXT: ptrue p0.d
816 ; CHECK-NEXT: mov z1.d, x8
817 ; CHECK-NEXT: fmov d2, #5.00000000
818 ; CHECK-NEXT: cmpeq p0.d, p0/z, z0.d, z1.d
819 ; CHECK-NEXT: ldp q0, q1, [x0]
820 ; CHECK-NEXT: mov z1.d, p0/m, d2
821 ; CHECK-NEXT: // kill: def $q1 killed $q1 killed $z1
824 ; NONEON-NOSVE-LABEL: insertelement_v4f64:
825 ; NONEON-NOSVE: // %bb.0:
826 ; NONEON-NOSVE-NEXT: sub sp, sp, #64
827 ; NONEON-NOSVE-NEXT: .cfi_def_cfa_offset 64
828 ; NONEON-NOSVE-NEXT: mov x8, #4617315517961601024 // =0x4014000000000000
829 ; NONEON-NOSVE-NEXT: ldr q1, [x0, #16]
830 ; NONEON-NOSVE-NEXT: str x8, [sp, #48]
831 ; NONEON-NOSVE-NEXT: ldr q0, [sp, #48]
832 ; NONEON-NOSVE-NEXT: stp q1, q0, [sp]
833 ; NONEON-NOSVE-NEXT: ldr d1, [sp]
834 ; NONEON-NOSVE-NEXT: ldr d0, [sp, #16]
835 ; NONEON-NOSVE-NEXT: stp d1, d0, [sp, #32]
836 ; NONEON-NOSVE-NEXT: ldr q0, [x0]
837 ; NONEON-NOSVE-NEXT: ldr q1, [sp, #32]
838 ; NONEON-NOSVE-NEXT: add sp, sp, #64
839 ; NONEON-NOSVE-NEXT: ret
840 %op1 = load <4 x double>, ptr %a
841 %r = insertelement <4 x double> %op1, double 5.0, i64 3