1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=thumbv8.1m.main-arm-none-eabi -mattr=+mve,+fullfp16 -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-LE
3 ; RUN: llc -mtriple=thumbebv8.1m.main-arm-none-eabi -mattr=+mve,+fullfp16 -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-BE
5 define arm_aapcs_vfpcc <4 x i32> @masked_v4i32_align4_zero(<4 x i32> *%dest, <4 x i32> %a) {
6 ; CHECK-LE-LABEL: masked_v4i32_align4_zero:
7 ; CHECK-LE: @ %bb.0: @ %entry
8 ; CHECK-LE-NEXT: .pad #4
9 ; CHECK-LE-NEXT: sub sp, #4
10 ; CHECK-LE-NEXT: mov r1, sp
11 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
12 ; CHECK-LE-NEXT: vstr p0, [r1]
13 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
14 ; CHECK-LE-NEXT: lsls r2, r1, #31
15 ; CHECK-LE-NEXT: beq .LBB0_2
16 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
17 ; CHECK-LE-NEXT: movs r2, #0
18 ; CHECK-LE-NEXT: ldr r3, [r0]
19 ; CHECK-LE-NEXT: vdup.32 q0, r2
20 ; CHECK-LE-NEXT: vmov.32 q0[0], r3
21 ; CHECK-LE-NEXT: b .LBB0_3
22 ; CHECK-LE-NEXT: .LBB0_2:
23 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
24 ; CHECK-LE-NEXT: .LBB0_3: @ %else
25 ; CHECK-LE-NEXT: lsls r2, r1, #30
26 ; CHECK-LE-NEXT: itt mi
27 ; CHECK-LE-NEXT: ldrmi r2, [r0, #4]
28 ; CHECK-LE-NEXT: vmovmi.32 q0[1], r2
29 ; CHECK-LE-NEXT: lsls r2, r1, #29
30 ; CHECK-LE-NEXT: itt mi
31 ; CHECK-LE-NEXT: ldrmi r2, [r0, #8]
32 ; CHECK-LE-NEXT: vmovmi.32 q0[2], r2
33 ; CHECK-LE-NEXT: lsls r1, r1, #28
34 ; CHECK-LE-NEXT: itt mi
35 ; CHECK-LE-NEXT: ldrmi r0, [r0, #12]
36 ; CHECK-LE-NEXT: vmovmi.32 q0[3], r0
37 ; CHECK-LE-NEXT: add sp, #4
38 ; CHECK-LE-NEXT: bx lr
40 ; CHECK-BE-LABEL: masked_v4i32_align4_zero:
41 ; CHECK-BE: @ %bb.0: @ %entry
42 ; CHECK-BE-NEXT: .pad #4
43 ; CHECK-BE-NEXT: sub sp, #4
44 ; CHECK-BE-NEXT: vrev64.32 q1, q0
45 ; CHECK-BE-NEXT: mov r1, sp
46 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
47 ; CHECK-BE-NEXT: vstr p0, [r1]
48 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
49 ; CHECK-BE-NEXT: lsls r2, r1, #31
50 ; CHECK-BE-NEXT: beq .LBB0_2
51 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
52 ; CHECK-BE-NEXT: movs r2, #0
53 ; CHECK-BE-NEXT: ldr r3, [r0]
54 ; CHECK-BE-NEXT: vdup.32 q1, r2
55 ; CHECK-BE-NEXT: vmov.32 q1[0], r3
56 ; CHECK-BE-NEXT: b .LBB0_3
57 ; CHECK-BE-NEXT: .LBB0_2:
58 ; CHECK-BE-NEXT: vmov.i32 q1, #0x0
59 ; CHECK-BE-NEXT: .LBB0_3: @ %else
60 ; CHECK-BE-NEXT: lsls r2, r1, #30
61 ; CHECK-BE-NEXT: itt mi
62 ; CHECK-BE-NEXT: ldrmi r2, [r0, #4]
63 ; CHECK-BE-NEXT: vmovmi.32 q1[1], r2
64 ; CHECK-BE-NEXT: lsls r2, r1, #29
65 ; CHECK-BE-NEXT: itt mi
66 ; CHECK-BE-NEXT: ldrmi r2, [r0, #8]
67 ; CHECK-BE-NEXT: vmovmi.32 q1[2], r2
68 ; CHECK-BE-NEXT: lsls r1, r1, #28
69 ; CHECK-BE-NEXT: itt mi
70 ; CHECK-BE-NEXT: ldrmi r0, [r0, #12]
71 ; CHECK-BE-NEXT: vmovmi.32 q1[3], r0
72 ; CHECK-BE-NEXT: vrev64.32 q0, q1
73 ; CHECK-BE-NEXT: add sp, #4
74 ; CHECK-BE-NEXT: bx lr
76 %c = icmp sgt <4 x i32> %a, zeroinitializer
77 %l = call <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>* %dest, i32 4, <4 x i1> %c, <4 x i32> zeroinitializer)
81 define arm_aapcs_vfpcc <4 x i32> @masked_v4i32_align4_undef(<4 x i32> *%dest, <4 x i32> %a) {
82 ; CHECK-LE-LABEL: masked_v4i32_align4_undef:
83 ; CHECK-LE: @ %bb.0: @ %entry
84 ; CHECK-LE-NEXT: .pad #4
85 ; CHECK-LE-NEXT: sub sp, #4
86 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
87 ; CHECK-LE-NEXT: mov r1, sp
88 ; CHECK-LE-NEXT: vstr p0, [r1]
89 ; CHECK-LE-NEXT: @ implicit-def: $q0
90 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
91 ; CHECK-LE-NEXT: lsls r2, r1, #31
92 ; CHECK-LE-NEXT: itt ne
93 ; CHECK-LE-NEXT: ldrne r2, [r0]
94 ; CHECK-LE-NEXT: vmovne.32 q0[0], r2
95 ; CHECK-LE-NEXT: lsls r2, r1, #30
96 ; CHECK-LE-NEXT: itt mi
97 ; CHECK-LE-NEXT: ldrmi r2, [r0, #4]
98 ; CHECK-LE-NEXT: vmovmi.32 q0[1], r2
99 ; CHECK-LE-NEXT: lsls r2, r1, #29
100 ; CHECK-LE-NEXT: itt mi
101 ; CHECK-LE-NEXT: ldrmi r2, [r0, #8]
102 ; CHECK-LE-NEXT: vmovmi.32 q0[2], r2
103 ; CHECK-LE-NEXT: lsls r1, r1, #28
104 ; CHECK-LE-NEXT: itt mi
105 ; CHECK-LE-NEXT: ldrmi r0, [r0, #12]
106 ; CHECK-LE-NEXT: vmovmi.32 q0[3], r0
107 ; CHECK-LE-NEXT: add sp, #4
108 ; CHECK-LE-NEXT: bx lr
110 ; CHECK-BE-LABEL: masked_v4i32_align4_undef:
111 ; CHECK-BE: @ %bb.0: @ %entry
112 ; CHECK-BE-NEXT: .pad #4
113 ; CHECK-BE-NEXT: sub sp, #4
114 ; CHECK-BE-NEXT: vrev64.32 q1, q0
115 ; CHECK-BE-NEXT: mov r1, sp
116 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
117 ; CHECK-BE-NEXT: @ implicit-def: $q1
118 ; CHECK-BE-NEXT: vstr p0, [r1]
119 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
120 ; CHECK-BE-NEXT: lsls r2, r1, #31
121 ; CHECK-BE-NEXT: itt ne
122 ; CHECK-BE-NEXT: ldrne r2, [r0]
123 ; CHECK-BE-NEXT: vmovne.32 q1[0], r2
124 ; CHECK-BE-NEXT: lsls r2, r1, #30
125 ; CHECK-BE-NEXT: itt mi
126 ; CHECK-BE-NEXT: ldrmi r2, [r0, #4]
127 ; CHECK-BE-NEXT: vmovmi.32 q1[1], r2
128 ; CHECK-BE-NEXT: lsls r2, r1, #29
129 ; CHECK-BE-NEXT: itt mi
130 ; CHECK-BE-NEXT: ldrmi r2, [r0, #8]
131 ; CHECK-BE-NEXT: vmovmi.32 q1[2], r2
132 ; CHECK-BE-NEXT: lsls r1, r1, #28
133 ; CHECK-BE-NEXT: itt mi
134 ; CHECK-BE-NEXT: ldrmi r0, [r0, #12]
135 ; CHECK-BE-NEXT: vmovmi.32 q1[3], r0
136 ; CHECK-BE-NEXT: vrev64.32 q0, q1
137 ; CHECK-BE-NEXT: add sp, #4
138 ; CHECK-BE-NEXT: bx lr
140 %c = icmp sgt <4 x i32> %a, zeroinitializer
141 %l = call <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>* %dest, i32 4, <4 x i1> %c, <4 x i32> undef)
145 define arm_aapcs_vfpcc <4 x i32> @masked_v4i32_align1_undef(<4 x i32> *%dest, <4 x i32> %a) {
146 ; CHECK-LE-LABEL: masked_v4i32_align1_undef:
147 ; CHECK-LE: @ %bb.0: @ %entry
148 ; CHECK-LE-NEXT: .pad #4
149 ; CHECK-LE-NEXT: sub sp, #4
150 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
151 ; CHECK-LE-NEXT: mov r1, sp
152 ; CHECK-LE-NEXT: vstr p0, [r1]
153 ; CHECK-LE-NEXT: @ implicit-def: $q0
154 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
155 ; CHECK-LE-NEXT: lsls r2, r1, #31
156 ; CHECK-LE-NEXT: itt ne
157 ; CHECK-LE-NEXT: ldrne r2, [r0]
158 ; CHECK-LE-NEXT: vmovne.32 q0[0], r2
159 ; CHECK-LE-NEXT: lsls r2, r1, #30
160 ; CHECK-LE-NEXT: itt mi
161 ; CHECK-LE-NEXT: ldrmi r2, [r0, #4]
162 ; CHECK-LE-NEXT: vmovmi.32 q0[1], r2
163 ; CHECK-LE-NEXT: lsls r2, r1, #29
164 ; CHECK-LE-NEXT: itt mi
165 ; CHECK-LE-NEXT: ldrmi r2, [r0, #8]
166 ; CHECK-LE-NEXT: vmovmi.32 q0[2], r2
167 ; CHECK-LE-NEXT: lsls r1, r1, #28
168 ; CHECK-LE-NEXT: itt mi
169 ; CHECK-LE-NEXT: ldrmi r0, [r0, #12]
170 ; CHECK-LE-NEXT: vmovmi.32 q0[3], r0
171 ; CHECK-LE-NEXT: add sp, #4
172 ; CHECK-LE-NEXT: bx lr
174 ; CHECK-BE-LABEL: masked_v4i32_align1_undef:
175 ; CHECK-BE: @ %bb.0: @ %entry
176 ; CHECK-BE-NEXT: .pad #4
177 ; CHECK-BE-NEXT: sub sp, #4
178 ; CHECK-BE-NEXT: vrev64.32 q1, q0
179 ; CHECK-BE-NEXT: mov r1, sp
180 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
181 ; CHECK-BE-NEXT: @ implicit-def: $q1
182 ; CHECK-BE-NEXT: vstr p0, [r1]
183 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
184 ; CHECK-BE-NEXT: lsls r2, r1, #31
185 ; CHECK-BE-NEXT: itt ne
186 ; CHECK-BE-NEXT: ldrne r2, [r0]
187 ; CHECK-BE-NEXT: vmovne.32 q1[0], r2
188 ; CHECK-BE-NEXT: lsls r2, r1, #30
189 ; CHECK-BE-NEXT: itt mi
190 ; CHECK-BE-NEXT: ldrmi r2, [r0, #4]
191 ; CHECK-BE-NEXT: vmovmi.32 q1[1], r2
192 ; CHECK-BE-NEXT: lsls r2, r1, #29
193 ; CHECK-BE-NEXT: itt mi
194 ; CHECK-BE-NEXT: ldrmi r2, [r0, #8]
195 ; CHECK-BE-NEXT: vmovmi.32 q1[2], r2
196 ; CHECK-BE-NEXT: lsls r1, r1, #28
197 ; CHECK-BE-NEXT: itt mi
198 ; CHECK-BE-NEXT: ldrmi r0, [r0, #12]
199 ; CHECK-BE-NEXT: vmovmi.32 q1[3], r0
200 ; CHECK-BE-NEXT: vrev64.32 q0, q1
201 ; CHECK-BE-NEXT: add sp, #4
202 ; CHECK-BE-NEXT: bx lr
204 %c = icmp sgt <4 x i32> %a, zeroinitializer
205 %l = call <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>* %dest, i32 1, <4 x i1> %c, <4 x i32> undef)
209 define arm_aapcs_vfpcc <4 x i32> @masked_v4i32_align4_other(<4 x i32> *%dest, <4 x i32> %a) {
210 ; CHECK-LE-LABEL: masked_v4i32_align4_other:
211 ; CHECK-LE: @ %bb.0: @ %entry
212 ; CHECK-LE-NEXT: .pad #4
213 ; CHECK-LE-NEXT: sub sp, #4
214 ; CHECK-LE-NEXT: mov r1, sp
215 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
216 ; CHECK-LE-NEXT: vstr p0, [r1]
217 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
218 ; CHECK-LE-NEXT: lsls r2, r1, #31
219 ; CHECK-LE-NEXT: itt ne
220 ; CHECK-LE-NEXT: ldrne r2, [r0]
221 ; CHECK-LE-NEXT: vmovne.32 q0[0], r2
222 ; CHECK-LE-NEXT: lsls r2, r1, #30
223 ; CHECK-LE-NEXT: itt mi
224 ; CHECK-LE-NEXT: ldrmi r2, [r0, #4]
225 ; CHECK-LE-NEXT: vmovmi.32 q0[1], r2
226 ; CHECK-LE-NEXT: lsls r2, r1, #29
227 ; CHECK-LE-NEXT: itt mi
228 ; CHECK-LE-NEXT: ldrmi r2, [r0, #8]
229 ; CHECK-LE-NEXT: vmovmi.32 q0[2], r2
230 ; CHECK-LE-NEXT: lsls r1, r1, #28
231 ; CHECK-LE-NEXT: itt mi
232 ; CHECK-LE-NEXT: ldrmi r0, [r0, #12]
233 ; CHECK-LE-NEXT: vmovmi.32 q0[3], r0
234 ; CHECK-LE-NEXT: add sp, #4
235 ; CHECK-LE-NEXT: bx lr
237 ; CHECK-BE-LABEL: masked_v4i32_align4_other:
238 ; CHECK-BE: @ %bb.0: @ %entry
239 ; CHECK-BE-NEXT: .pad #4
240 ; CHECK-BE-NEXT: sub sp, #4
241 ; CHECK-BE-NEXT: vrev64.32 q1, q0
242 ; CHECK-BE-NEXT: mov r1, sp
243 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
244 ; CHECK-BE-NEXT: vstr p0, [r1]
245 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
246 ; CHECK-BE-NEXT: lsls r2, r1, #31
247 ; CHECK-BE-NEXT: itt ne
248 ; CHECK-BE-NEXT: ldrne r2, [r0]
249 ; CHECK-BE-NEXT: vmovne.32 q1[0], r2
250 ; CHECK-BE-NEXT: lsls r2, r1, #30
251 ; CHECK-BE-NEXT: itt mi
252 ; CHECK-BE-NEXT: ldrmi r2, [r0, #4]
253 ; CHECK-BE-NEXT: vmovmi.32 q1[1], r2
254 ; CHECK-BE-NEXT: lsls r2, r1, #29
255 ; CHECK-BE-NEXT: itt mi
256 ; CHECK-BE-NEXT: ldrmi r2, [r0, #8]
257 ; CHECK-BE-NEXT: vmovmi.32 q1[2], r2
258 ; CHECK-BE-NEXT: lsls r1, r1, #28
259 ; CHECK-BE-NEXT: itt mi
260 ; CHECK-BE-NEXT: ldrmi r0, [r0, #12]
261 ; CHECK-BE-NEXT: vmovmi.32 q1[3], r0
262 ; CHECK-BE-NEXT: vrev64.32 q0, q1
263 ; CHECK-BE-NEXT: add sp, #4
264 ; CHECK-BE-NEXT: bx lr
266 %c = icmp sgt <4 x i32> %a, zeroinitializer
267 %l = call <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>* %dest, i32 4, <4 x i1> %c, <4 x i32> %a)
271 define arm_aapcs_vfpcc i8* @masked_v4i32_preinc(i8* %x, i8* %y, <4 x i32> %a) {
272 ; CHECK-LE-LABEL: masked_v4i32_preinc:
273 ; CHECK-LE: @ %bb.0: @ %entry
274 ; CHECK-LE-NEXT: .pad #4
275 ; CHECK-LE-NEXT: sub sp, #4
276 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
277 ; CHECK-LE-NEXT: mov r2, sp
278 ; CHECK-LE-NEXT: vstr p0, [r2]
279 ; CHECK-LE-NEXT: @ implicit-def: $q0
280 ; CHECK-LE-NEXT: adds r0, #4
281 ; CHECK-LE-NEXT: ldrb.w r2, [sp]
282 ; CHECK-LE-NEXT: lsls r3, r2, #31
283 ; CHECK-LE-NEXT: itt ne
284 ; CHECK-LE-NEXT: ldrne r3, [r0]
285 ; CHECK-LE-NEXT: vmovne.32 q0[0], r3
286 ; CHECK-LE-NEXT: lsls r3, r2, #30
287 ; CHECK-LE-NEXT: itt mi
288 ; CHECK-LE-NEXT: ldrmi r3, [r0, #4]
289 ; CHECK-LE-NEXT: vmovmi.32 q0[1], r3
290 ; CHECK-LE-NEXT: lsls r3, r2, #29
291 ; CHECK-LE-NEXT: itt mi
292 ; CHECK-LE-NEXT: ldrmi r3, [r0, #8]
293 ; CHECK-LE-NEXT: vmovmi.32 q0[2], r3
294 ; CHECK-LE-NEXT: lsls r2, r2, #28
295 ; CHECK-LE-NEXT: itt mi
296 ; CHECK-LE-NEXT: ldrmi r2, [r0, #12]
297 ; CHECK-LE-NEXT: vmovmi.32 q0[3], r2
298 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
299 ; CHECK-LE-NEXT: add sp, #4
300 ; CHECK-LE-NEXT: bx lr
302 ; CHECK-BE-LABEL: masked_v4i32_preinc:
303 ; CHECK-BE: @ %bb.0: @ %entry
304 ; CHECK-BE-NEXT: .pad #4
305 ; CHECK-BE-NEXT: sub sp, #4
306 ; CHECK-BE-NEXT: vrev64.32 q1, q0
307 ; CHECK-BE-NEXT: mov r2, sp
308 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
309 ; CHECK-BE-NEXT: @ implicit-def: $q0
310 ; CHECK-BE-NEXT: adds r0, #4
311 ; CHECK-BE-NEXT: vstr p0, [r2]
312 ; CHECK-BE-NEXT: ldrb.w r2, [sp]
313 ; CHECK-BE-NEXT: lsls r3, r2, #31
314 ; CHECK-BE-NEXT: itt ne
315 ; CHECK-BE-NEXT: ldrne r3, [r0]
316 ; CHECK-BE-NEXT: vmovne.32 q0[0], r3
317 ; CHECK-BE-NEXT: lsls r3, r2, #30
318 ; CHECK-BE-NEXT: itt mi
319 ; CHECK-BE-NEXT: ldrmi r3, [r0, #4]
320 ; CHECK-BE-NEXT: vmovmi.32 q0[1], r3
321 ; CHECK-BE-NEXT: lsls r3, r2, #29
322 ; CHECK-BE-NEXT: itt mi
323 ; CHECK-BE-NEXT: ldrmi r3, [r0, #8]
324 ; CHECK-BE-NEXT: vmovmi.32 q0[2], r3
325 ; CHECK-BE-NEXT: lsls r2, r2, #28
326 ; CHECK-BE-NEXT: itt mi
327 ; CHECK-BE-NEXT: ldrmi r2, [r0, #12]
328 ; CHECK-BE-NEXT: vmovmi.32 q0[3], r2
329 ; CHECK-BE-NEXT: vstrw.32 q0, [r1]
330 ; CHECK-BE-NEXT: add sp, #4
331 ; CHECK-BE-NEXT: bx lr
333 %z = getelementptr inbounds i8, i8* %x, i32 4
334 %0 = bitcast i8* %z to <4 x i32>*
335 %c = icmp sgt <4 x i32> %a, zeroinitializer
336 %1 = call <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>* %0, i32 4, <4 x i1> %c, <4 x i32> undef)
337 %2 = bitcast i8* %y to <4 x i32>*
338 store <4 x i32> %1, <4 x i32>* %2, align 4
342 define arm_aapcs_vfpcc i8* @masked_v4i32_postinc(i8* %x, i8* %y, <4 x i32> %a) {
343 ; CHECK-LE-LABEL: masked_v4i32_postinc:
344 ; CHECK-LE: @ %bb.0: @ %entry
345 ; CHECK-LE-NEXT: .pad #4
346 ; CHECK-LE-NEXT: sub sp, #4
347 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
348 ; CHECK-LE-NEXT: mov r2, sp
349 ; CHECK-LE-NEXT: vstr p0, [r2]
350 ; CHECK-LE-NEXT: @ implicit-def: $q0
351 ; CHECK-LE-NEXT: add.w r12, r0, #4
352 ; CHECK-LE-NEXT: ldrb.w r3, [sp]
353 ; CHECK-LE-NEXT: lsls r2, r3, #31
354 ; CHECK-LE-NEXT: itt ne
355 ; CHECK-LE-NEXT: ldrne r2, [r0]
356 ; CHECK-LE-NEXT: vmovne.32 q0[0], r2
357 ; CHECK-LE-NEXT: lsls r2, r3, #30
358 ; CHECK-LE-NEXT: itt mi
359 ; CHECK-LE-NEXT: ldrmi r2, [r0, #4]
360 ; CHECK-LE-NEXT: vmovmi.32 q0[1], r2
361 ; CHECK-LE-NEXT: lsls r2, r3, #29
362 ; CHECK-LE-NEXT: itt mi
363 ; CHECK-LE-NEXT: ldrmi r2, [r0, #8]
364 ; CHECK-LE-NEXT: vmovmi.32 q0[2], r2
365 ; CHECK-LE-NEXT: lsls r2, r3, #28
366 ; CHECK-LE-NEXT: itt mi
367 ; CHECK-LE-NEXT: ldrmi r0, [r0, #12]
368 ; CHECK-LE-NEXT: vmovmi.32 q0[3], r0
369 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
370 ; CHECK-LE-NEXT: mov r0, r12
371 ; CHECK-LE-NEXT: add sp, #4
372 ; CHECK-LE-NEXT: bx lr
374 ; CHECK-BE-LABEL: masked_v4i32_postinc:
375 ; CHECK-BE: @ %bb.0: @ %entry
376 ; CHECK-BE-NEXT: .pad #4
377 ; CHECK-BE-NEXT: sub sp, #4
378 ; CHECK-BE-NEXT: vrev64.32 q1, q0
379 ; CHECK-BE-NEXT: mov r2, sp
380 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
381 ; CHECK-BE-NEXT: @ implicit-def: $q0
382 ; CHECK-BE-NEXT: add.w r12, r0, #4
383 ; CHECK-BE-NEXT: vstr p0, [r2]
384 ; CHECK-BE-NEXT: ldrb.w r3, [sp]
385 ; CHECK-BE-NEXT: lsls r2, r3, #31
386 ; CHECK-BE-NEXT: itt ne
387 ; CHECK-BE-NEXT: ldrne r2, [r0]
388 ; CHECK-BE-NEXT: vmovne.32 q0[0], r2
389 ; CHECK-BE-NEXT: lsls r2, r3, #30
390 ; CHECK-BE-NEXT: itt mi
391 ; CHECK-BE-NEXT: ldrmi r2, [r0, #4]
392 ; CHECK-BE-NEXT: vmovmi.32 q0[1], r2
393 ; CHECK-BE-NEXT: lsls r2, r3, #29
394 ; CHECK-BE-NEXT: itt mi
395 ; CHECK-BE-NEXT: ldrmi r2, [r0, #8]
396 ; CHECK-BE-NEXT: vmovmi.32 q0[2], r2
397 ; CHECK-BE-NEXT: lsls r2, r3, #28
398 ; CHECK-BE-NEXT: itt mi
399 ; CHECK-BE-NEXT: ldrmi r0, [r0, #12]
400 ; CHECK-BE-NEXT: vmovmi.32 q0[3], r0
401 ; CHECK-BE-NEXT: vstrw.32 q0, [r1]
402 ; CHECK-BE-NEXT: mov r0, r12
403 ; CHECK-BE-NEXT: add sp, #4
404 ; CHECK-BE-NEXT: bx lr
406 %z = getelementptr inbounds i8, i8* %x, i32 4
407 %0 = bitcast i8* %x to <4 x i32>*
408 %c = icmp sgt <4 x i32> %a, zeroinitializer
409 %1 = call <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>* %0, i32 4, <4 x i1> %c, <4 x i32> undef)
410 %2 = bitcast i8* %y to <4 x i32>*
411 store <4 x i32> %1, <4 x i32>* %2, align 4
417 define arm_aapcs_vfpcc <8 x i16> @masked_v8i16_align4_zero(<8 x i16> *%dest, <8 x i16> %a) {
418 ; CHECK-LE-LABEL: masked_v8i16_align4_zero:
419 ; CHECK-LE: @ %bb.0: @ %entry
420 ; CHECK-LE-NEXT: .pad #8
421 ; CHECK-LE-NEXT: sub sp, #8
422 ; CHECK-LE-NEXT: mov r1, sp
423 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
424 ; CHECK-LE-NEXT: vstr p0, [r1]
425 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
426 ; CHECK-LE-NEXT: lsls r2, r1, #31
427 ; CHECK-LE-NEXT: beq .LBB6_2
428 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
429 ; CHECK-LE-NEXT: movs r2, #0
430 ; CHECK-LE-NEXT: ldrh r3, [r0]
431 ; CHECK-LE-NEXT: vdup.16 q0, r2
432 ; CHECK-LE-NEXT: vmov.16 q0[0], r3
433 ; CHECK-LE-NEXT: b .LBB6_3
434 ; CHECK-LE-NEXT: .LBB6_2:
435 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
436 ; CHECK-LE-NEXT: .LBB6_3: @ %else
437 ; CHECK-LE-NEXT: lsls r2, r1, #30
438 ; CHECK-LE-NEXT: itt mi
439 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #2]
440 ; CHECK-LE-NEXT: vmovmi.16 q0[1], r2
441 ; CHECK-LE-NEXT: lsls r2, r1, #29
442 ; CHECK-LE-NEXT: itt mi
443 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #4]
444 ; CHECK-LE-NEXT: vmovmi.16 q0[2], r2
445 ; CHECK-LE-NEXT: lsls r2, r1, #28
446 ; CHECK-LE-NEXT: itt mi
447 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #6]
448 ; CHECK-LE-NEXT: vmovmi.16 q0[3], r2
449 ; CHECK-LE-NEXT: lsls r2, r1, #27
450 ; CHECK-LE-NEXT: itt mi
451 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #8]
452 ; CHECK-LE-NEXT: vmovmi.16 q0[4], r2
453 ; CHECK-LE-NEXT: lsls r2, r1, #26
454 ; CHECK-LE-NEXT: itt mi
455 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #10]
456 ; CHECK-LE-NEXT: vmovmi.16 q0[5], r2
457 ; CHECK-LE-NEXT: lsls r2, r1, #25
458 ; CHECK-LE-NEXT: itt mi
459 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #12]
460 ; CHECK-LE-NEXT: vmovmi.16 q0[6], r2
461 ; CHECK-LE-NEXT: lsls r1, r1, #24
462 ; CHECK-LE-NEXT: itt mi
463 ; CHECK-LE-NEXT: ldrhmi r0, [r0, #14]
464 ; CHECK-LE-NEXT: vmovmi.16 q0[7], r0
465 ; CHECK-LE-NEXT: add sp, #8
466 ; CHECK-LE-NEXT: bx lr
468 ; CHECK-BE-LABEL: masked_v8i16_align4_zero:
469 ; CHECK-BE: @ %bb.0: @ %entry
470 ; CHECK-BE-NEXT: .pad #8
471 ; CHECK-BE-NEXT: sub sp, #8
472 ; CHECK-BE-NEXT: vrev64.16 q1, q0
473 ; CHECK-BE-NEXT: mov r1, sp
474 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
475 ; CHECK-BE-NEXT: vstr p0, [r1]
476 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
477 ; CHECK-BE-NEXT: lsls r2, r1, #31
478 ; CHECK-BE-NEXT: beq .LBB6_2
479 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
480 ; CHECK-BE-NEXT: movs r2, #0
481 ; CHECK-BE-NEXT: ldrh r3, [r0]
482 ; CHECK-BE-NEXT: vdup.16 q1, r2
483 ; CHECK-BE-NEXT: vmov.16 q1[0], r3
484 ; CHECK-BE-NEXT: b .LBB6_3
485 ; CHECK-BE-NEXT: .LBB6_2:
486 ; CHECK-BE-NEXT: vmov.i32 q0, #0x0
487 ; CHECK-BE-NEXT: vrev32.16 q1, q0
488 ; CHECK-BE-NEXT: .LBB6_3: @ %else
489 ; CHECK-BE-NEXT: lsls r2, r1, #30
490 ; CHECK-BE-NEXT: itt mi
491 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #2]
492 ; CHECK-BE-NEXT: vmovmi.16 q1[1], r2
493 ; CHECK-BE-NEXT: lsls r2, r1, #29
494 ; CHECK-BE-NEXT: itt mi
495 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #4]
496 ; CHECK-BE-NEXT: vmovmi.16 q1[2], r2
497 ; CHECK-BE-NEXT: lsls r2, r1, #28
498 ; CHECK-BE-NEXT: itt mi
499 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #6]
500 ; CHECK-BE-NEXT: vmovmi.16 q1[3], r2
501 ; CHECK-BE-NEXT: lsls r2, r1, #27
502 ; CHECK-BE-NEXT: itt mi
503 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #8]
504 ; CHECK-BE-NEXT: vmovmi.16 q1[4], r2
505 ; CHECK-BE-NEXT: lsls r2, r1, #26
506 ; CHECK-BE-NEXT: itt mi
507 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #10]
508 ; CHECK-BE-NEXT: vmovmi.16 q1[5], r2
509 ; CHECK-BE-NEXT: lsls r2, r1, #25
510 ; CHECK-BE-NEXT: itt mi
511 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #12]
512 ; CHECK-BE-NEXT: vmovmi.16 q1[6], r2
513 ; CHECK-BE-NEXT: lsls r1, r1, #24
514 ; CHECK-BE-NEXT: itt mi
515 ; CHECK-BE-NEXT: ldrhmi r0, [r0, #14]
516 ; CHECK-BE-NEXT: vmovmi.16 q1[7], r0
517 ; CHECK-BE-NEXT: vrev64.16 q0, q1
518 ; CHECK-BE-NEXT: add sp, #8
519 ; CHECK-BE-NEXT: bx lr
521 %c = icmp sgt <8 x i16> %a, zeroinitializer
522 %l = call <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>* %dest, i32 2, <8 x i1> %c, <8 x i16> zeroinitializer)
526 define arm_aapcs_vfpcc <8 x i16> @masked_v8i16_align4_undef(<8 x i16> *%dest, <8 x i16> %a) {
527 ; CHECK-LE-LABEL: masked_v8i16_align4_undef:
528 ; CHECK-LE: @ %bb.0: @ %entry
529 ; CHECK-LE-NEXT: .pad #8
530 ; CHECK-LE-NEXT: sub sp, #8
531 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
532 ; CHECK-LE-NEXT: mov r1, sp
533 ; CHECK-LE-NEXT: vstr p0, [r1]
534 ; CHECK-LE-NEXT: @ implicit-def: $q0
535 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
536 ; CHECK-LE-NEXT: lsls r2, r1, #31
537 ; CHECK-LE-NEXT: itt ne
538 ; CHECK-LE-NEXT: ldrhne r2, [r0]
539 ; CHECK-LE-NEXT: vmovne.16 q0[0], r2
540 ; CHECK-LE-NEXT: lsls r2, r1, #30
541 ; CHECK-LE-NEXT: itt mi
542 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #2]
543 ; CHECK-LE-NEXT: vmovmi.16 q0[1], r2
544 ; CHECK-LE-NEXT: lsls r2, r1, #29
545 ; CHECK-LE-NEXT: itt mi
546 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #4]
547 ; CHECK-LE-NEXT: vmovmi.16 q0[2], r2
548 ; CHECK-LE-NEXT: lsls r2, r1, #28
549 ; CHECK-LE-NEXT: itt mi
550 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #6]
551 ; CHECK-LE-NEXT: vmovmi.16 q0[3], r2
552 ; CHECK-LE-NEXT: lsls r2, r1, #27
553 ; CHECK-LE-NEXT: itt mi
554 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #8]
555 ; CHECK-LE-NEXT: vmovmi.16 q0[4], r2
556 ; CHECK-LE-NEXT: lsls r2, r1, #26
557 ; CHECK-LE-NEXT: itt mi
558 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #10]
559 ; CHECK-LE-NEXT: vmovmi.16 q0[5], r2
560 ; CHECK-LE-NEXT: lsls r2, r1, #25
561 ; CHECK-LE-NEXT: itt mi
562 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #12]
563 ; CHECK-LE-NEXT: vmovmi.16 q0[6], r2
564 ; CHECK-LE-NEXT: lsls r1, r1, #24
565 ; CHECK-LE-NEXT: itt mi
566 ; CHECK-LE-NEXT: ldrhmi r0, [r0, #14]
567 ; CHECK-LE-NEXT: vmovmi.16 q0[7], r0
568 ; CHECK-LE-NEXT: add sp, #8
569 ; CHECK-LE-NEXT: bx lr
571 ; CHECK-BE-LABEL: masked_v8i16_align4_undef:
572 ; CHECK-BE: @ %bb.0: @ %entry
573 ; CHECK-BE-NEXT: .pad #8
574 ; CHECK-BE-NEXT: sub sp, #8
575 ; CHECK-BE-NEXT: vrev64.16 q1, q0
576 ; CHECK-BE-NEXT: mov r1, sp
577 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
578 ; CHECK-BE-NEXT: @ implicit-def: $q1
579 ; CHECK-BE-NEXT: vstr p0, [r1]
580 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
581 ; CHECK-BE-NEXT: lsls r2, r1, #31
582 ; CHECK-BE-NEXT: itt ne
583 ; CHECK-BE-NEXT: ldrhne r2, [r0]
584 ; CHECK-BE-NEXT: vmovne.16 q1[0], r2
585 ; CHECK-BE-NEXT: lsls r2, r1, #30
586 ; CHECK-BE-NEXT: itt mi
587 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #2]
588 ; CHECK-BE-NEXT: vmovmi.16 q1[1], r2
589 ; CHECK-BE-NEXT: lsls r2, r1, #29
590 ; CHECK-BE-NEXT: itt mi
591 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #4]
592 ; CHECK-BE-NEXT: vmovmi.16 q1[2], r2
593 ; CHECK-BE-NEXT: lsls r2, r1, #28
594 ; CHECK-BE-NEXT: itt mi
595 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #6]
596 ; CHECK-BE-NEXT: vmovmi.16 q1[3], r2
597 ; CHECK-BE-NEXT: lsls r2, r1, #27
598 ; CHECK-BE-NEXT: itt mi
599 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #8]
600 ; CHECK-BE-NEXT: vmovmi.16 q1[4], r2
601 ; CHECK-BE-NEXT: lsls r2, r1, #26
602 ; CHECK-BE-NEXT: itt mi
603 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #10]
604 ; CHECK-BE-NEXT: vmovmi.16 q1[5], r2
605 ; CHECK-BE-NEXT: lsls r2, r1, #25
606 ; CHECK-BE-NEXT: itt mi
607 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #12]
608 ; CHECK-BE-NEXT: vmovmi.16 q1[6], r2
609 ; CHECK-BE-NEXT: lsls r1, r1, #24
610 ; CHECK-BE-NEXT: itt mi
611 ; CHECK-BE-NEXT: ldrhmi r0, [r0, #14]
612 ; CHECK-BE-NEXT: vmovmi.16 q1[7], r0
613 ; CHECK-BE-NEXT: vrev64.16 q0, q1
614 ; CHECK-BE-NEXT: add sp, #8
615 ; CHECK-BE-NEXT: bx lr
617 %c = icmp sgt <8 x i16> %a, zeroinitializer
618 %l = call <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>* %dest, i32 2, <8 x i1> %c, <8 x i16> undef)
622 define arm_aapcs_vfpcc <8 x i16> @masked_v8i16_align1_undef(<8 x i16> *%dest, <8 x i16> %a) {
623 ; CHECK-LE-LABEL: masked_v8i16_align1_undef:
624 ; CHECK-LE: @ %bb.0: @ %entry
625 ; CHECK-LE-NEXT: .pad #8
626 ; CHECK-LE-NEXT: sub sp, #8
627 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
628 ; CHECK-LE-NEXT: mov r1, sp
629 ; CHECK-LE-NEXT: vstr p0, [r1]
630 ; CHECK-LE-NEXT: @ implicit-def: $q0
631 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
632 ; CHECK-LE-NEXT: lsls r2, r1, #31
633 ; CHECK-LE-NEXT: itt ne
634 ; CHECK-LE-NEXT: ldrhne r2, [r0]
635 ; CHECK-LE-NEXT: vmovne.16 q0[0], r2
636 ; CHECK-LE-NEXT: lsls r2, r1, #30
637 ; CHECK-LE-NEXT: itt mi
638 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #2]
639 ; CHECK-LE-NEXT: vmovmi.16 q0[1], r2
640 ; CHECK-LE-NEXT: lsls r2, r1, #29
641 ; CHECK-LE-NEXT: itt mi
642 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #4]
643 ; CHECK-LE-NEXT: vmovmi.16 q0[2], r2
644 ; CHECK-LE-NEXT: lsls r2, r1, #28
645 ; CHECK-LE-NEXT: itt mi
646 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #6]
647 ; CHECK-LE-NEXT: vmovmi.16 q0[3], r2
648 ; CHECK-LE-NEXT: lsls r2, r1, #27
649 ; CHECK-LE-NEXT: itt mi
650 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #8]
651 ; CHECK-LE-NEXT: vmovmi.16 q0[4], r2
652 ; CHECK-LE-NEXT: lsls r2, r1, #26
653 ; CHECK-LE-NEXT: itt mi
654 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #10]
655 ; CHECK-LE-NEXT: vmovmi.16 q0[5], r2
656 ; CHECK-LE-NEXT: lsls r2, r1, #25
657 ; CHECK-LE-NEXT: itt mi
658 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #12]
659 ; CHECK-LE-NEXT: vmovmi.16 q0[6], r2
660 ; CHECK-LE-NEXT: lsls r1, r1, #24
661 ; CHECK-LE-NEXT: itt mi
662 ; CHECK-LE-NEXT: ldrhmi r0, [r0, #14]
663 ; CHECK-LE-NEXT: vmovmi.16 q0[7], r0
664 ; CHECK-LE-NEXT: add sp, #8
665 ; CHECK-LE-NEXT: bx lr
667 ; CHECK-BE-LABEL: masked_v8i16_align1_undef:
668 ; CHECK-BE: @ %bb.0: @ %entry
669 ; CHECK-BE-NEXT: .pad #8
670 ; CHECK-BE-NEXT: sub sp, #8
671 ; CHECK-BE-NEXT: vrev64.16 q1, q0
672 ; CHECK-BE-NEXT: mov r1, sp
673 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
674 ; CHECK-BE-NEXT: @ implicit-def: $q1
675 ; CHECK-BE-NEXT: vstr p0, [r1]
676 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
677 ; CHECK-BE-NEXT: lsls r2, r1, #31
678 ; CHECK-BE-NEXT: itt ne
679 ; CHECK-BE-NEXT: ldrhne r2, [r0]
680 ; CHECK-BE-NEXT: vmovne.16 q1[0], r2
681 ; CHECK-BE-NEXT: lsls r2, r1, #30
682 ; CHECK-BE-NEXT: itt mi
683 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #2]
684 ; CHECK-BE-NEXT: vmovmi.16 q1[1], r2
685 ; CHECK-BE-NEXT: lsls r2, r1, #29
686 ; CHECK-BE-NEXT: itt mi
687 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #4]
688 ; CHECK-BE-NEXT: vmovmi.16 q1[2], r2
689 ; CHECK-BE-NEXT: lsls r2, r1, #28
690 ; CHECK-BE-NEXT: itt mi
691 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #6]
692 ; CHECK-BE-NEXT: vmovmi.16 q1[3], r2
693 ; CHECK-BE-NEXT: lsls r2, r1, #27
694 ; CHECK-BE-NEXT: itt mi
695 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #8]
696 ; CHECK-BE-NEXT: vmovmi.16 q1[4], r2
697 ; CHECK-BE-NEXT: lsls r2, r1, #26
698 ; CHECK-BE-NEXT: itt mi
699 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #10]
700 ; CHECK-BE-NEXT: vmovmi.16 q1[5], r2
701 ; CHECK-BE-NEXT: lsls r2, r1, #25
702 ; CHECK-BE-NEXT: itt mi
703 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #12]
704 ; CHECK-BE-NEXT: vmovmi.16 q1[6], r2
705 ; CHECK-BE-NEXT: lsls r1, r1, #24
706 ; CHECK-BE-NEXT: itt mi
707 ; CHECK-BE-NEXT: ldrhmi r0, [r0, #14]
708 ; CHECK-BE-NEXT: vmovmi.16 q1[7], r0
709 ; CHECK-BE-NEXT: vrev64.16 q0, q1
710 ; CHECK-BE-NEXT: add sp, #8
711 ; CHECK-BE-NEXT: bx lr
713 %c = icmp sgt <8 x i16> %a, zeroinitializer
714 %l = call <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>* %dest, i32 1, <8 x i1> %c, <8 x i16> undef)
718 define arm_aapcs_vfpcc <8 x i16> @masked_v8i16_align4_other(<8 x i16> *%dest, <8 x i16> %a) {
719 ; CHECK-LE-LABEL: masked_v8i16_align4_other:
720 ; CHECK-LE: @ %bb.0: @ %entry
721 ; CHECK-LE-NEXT: .pad #8
722 ; CHECK-LE-NEXT: sub sp, #8
723 ; CHECK-LE-NEXT: mov r1, sp
724 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
725 ; CHECK-LE-NEXT: vstr p0, [r1]
726 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
727 ; CHECK-LE-NEXT: lsls r2, r1, #31
728 ; CHECK-LE-NEXT: itt ne
729 ; CHECK-LE-NEXT: ldrhne r2, [r0]
730 ; CHECK-LE-NEXT: vmovne.16 q0[0], r2
731 ; CHECK-LE-NEXT: lsls r2, r1, #30
732 ; CHECK-LE-NEXT: itt mi
733 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #2]
734 ; CHECK-LE-NEXT: vmovmi.16 q0[1], r2
735 ; CHECK-LE-NEXT: lsls r2, r1, #29
736 ; CHECK-LE-NEXT: itt mi
737 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #4]
738 ; CHECK-LE-NEXT: vmovmi.16 q0[2], r2
739 ; CHECK-LE-NEXT: lsls r2, r1, #28
740 ; CHECK-LE-NEXT: itt mi
741 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #6]
742 ; CHECK-LE-NEXT: vmovmi.16 q0[3], r2
743 ; CHECK-LE-NEXT: lsls r2, r1, #27
744 ; CHECK-LE-NEXT: itt mi
745 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #8]
746 ; CHECK-LE-NEXT: vmovmi.16 q0[4], r2
747 ; CHECK-LE-NEXT: lsls r2, r1, #26
748 ; CHECK-LE-NEXT: itt mi
749 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #10]
750 ; CHECK-LE-NEXT: vmovmi.16 q0[5], r2
751 ; CHECK-LE-NEXT: lsls r2, r1, #25
752 ; CHECK-LE-NEXT: itt mi
753 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #12]
754 ; CHECK-LE-NEXT: vmovmi.16 q0[6], r2
755 ; CHECK-LE-NEXT: lsls r1, r1, #24
756 ; CHECK-LE-NEXT: itt mi
757 ; CHECK-LE-NEXT: ldrhmi r0, [r0, #14]
758 ; CHECK-LE-NEXT: vmovmi.16 q0[7], r0
759 ; CHECK-LE-NEXT: add sp, #8
760 ; CHECK-LE-NEXT: bx lr
762 ; CHECK-BE-LABEL: masked_v8i16_align4_other:
763 ; CHECK-BE: @ %bb.0: @ %entry
764 ; CHECK-BE-NEXT: .pad #8
765 ; CHECK-BE-NEXT: sub sp, #8
766 ; CHECK-BE-NEXT: vrev64.16 q1, q0
767 ; CHECK-BE-NEXT: mov r1, sp
768 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
769 ; CHECK-BE-NEXT: vstr p0, [r1]
770 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
771 ; CHECK-BE-NEXT: lsls r2, r1, #31
772 ; CHECK-BE-NEXT: itt ne
773 ; CHECK-BE-NEXT: ldrhne r2, [r0]
774 ; CHECK-BE-NEXT: vmovne.16 q1[0], r2
775 ; CHECK-BE-NEXT: lsls r2, r1, #30
776 ; CHECK-BE-NEXT: itt mi
777 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #2]
778 ; CHECK-BE-NEXT: vmovmi.16 q1[1], r2
779 ; CHECK-BE-NEXT: lsls r2, r1, #29
780 ; CHECK-BE-NEXT: itt mi
781 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #4]
782 ; CHECK-BE-NEXT: vmovmi.16 q1[2], r2
783 ; CHECK-BE-NEXT: lsls r2, r1, #28
784 ; CHECK-BE-NEXT: itt mi
785 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #6]
786 ; CHECK-BE-NEXT: vmovmi.16 q1[3], r2
787 ; CHECK-BE-NEXT: lsls r2, r1, #27
788 ; CHECK-BE-NEXT: itt mi
789 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #8]
790 ; CHECK-BE-NEXT: vmovmi.16 q1[4], r2
791 ; CHECK-BE-NEXT: lsls r2, r1, #26
792 ; CHECK-BE-NEXT: itt mi
793 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #10]
794 ; CHECK-BE-NEXT: vmovmi.16 q1[5], r2
795 ; CHECK-BE-NEXT: lsls r2, r1, #25
796 ; CHECK-BE-NEXT: itt mi
797 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #12]
798 ; CHECK-BE-NEXT: vmovmi.16 q1[6], r2
799 ; CHECK-BE-NEXT: lsls r1, r1, #24
800 ; CHECK-BE-NEXT: itt mi
801 ; CHECK-BE-NEXT: ldrhmi r0, [r0, #14]
802 ; CHECK-BE-NEXT: vmovmi.16 q1[7], r0
803 ; CHECK-BE-NEXT: vrev64.16 q0, q1
804 ; CHECK-BE-NEXT: add sp, #8
805 ; CHECK-BE-NEXT: bx lr
807 %c = icmp sgt <8 x i16> %a, zeroinitializer
808 %l = call <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>* %dest, i32 2, <8 x i1> %c, <8 x i16> %a)
812 define i8* @masked_v8i16_preinc(i8* %x, i8* %y, <8 x i16> %a) {
813 ; CHECK-LE-LABEL: masked_v8i16_preinc:
814 ; CHECK-LE: @ %bb.0: @ %entry
815 ; CHECK-LE-NEXT: .pad #8
816 ; CHECK-LE-NEXT: sub sp, #8
817 ; CHECK-LE-NEXT: vldr d1, [sp, #8]
818 ; CHECK-LE-NEXT: adds r0, #4
819 ; CHECK-LE-NEXT: vmov d0, r2, r3
820 ; CHECK-LE-NEXT: mov r2, sp
821 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
822 ; CHECK-LE-NEXT: @ implicit-def: $q0
823 ; CHECK-LE-NEXT: vstr p0, [r2]
824 ; CHECK-LE-NEXT: ldrb.w r2, [sp]
825 ; CHECK-LE-NEXT: lsls r3, r2, #31
826 ; CHECK-LE-NEXT: itt ne
827 ; CHECK-LE-NEXT: ldrhne r3, [r0]
828 ; CHECK-LE-NEXT: vmovne.16 q0[0], r3
829 ; CHECK-LE-NEXT: lsls r3, r2, #30
830 ; CHECK-LE-NEXT: itt mi
831 ; CHECK-LE-NEXT: ldrhmi r3, [r0, #2]
832 ; CHECK-LE-NEXT: vmovmi.16 q0[1], r3
833 ; CHECK-LE-NEXT: lsls r3, r2, #29
834 ; CHECK-LE-NEXT: itt mi
835 ; CHECK-LE-NEXT: ldrhmi r3, [r0, #4]
836 ; CHECK-LE-NEXT: vmovmi.16 q0[2], r3
837 ; CHECK-LE-NEXT: lsls r3, r2, #28
838 ; CHECK-LE-NEXT: itt mi
839 ; CHECK-LE-NEXT: ldrhmi r3, [r0, #6]
840 ; CHECK-LE-NEXT: vmovmi.16 q0[3], r3
841 ; CHECK-LE-NEXT: lsls r3, r2, #27
842 ; CHECK-LE-NEXT: itt mi
843 ; CHECK-LE-NEXT: ldrhmi r3, [r0, #8]
844 ; CHECK-LE-NEXT: vmovmi.16 q0[4], r3
845 ; CHECK-LE-NEXT: lsls r3, r2, #26
846 ; CHECK-LE-NEXT: itt mi
847 ; CHECK-LE-NEXT: ldrhmi r3, [r0, #10]
848 ; CHECK-LE-NEXT: vmovmi.16 q0[5], r3
849 ; CHECK-LE-NEXT: lsls r3, r2, #25
850 ; CHECK-LE-NEXT: itt mi
851 ; CHECK-LE-NEXT: ldrhmi r3, [r0, #12]
852 ; CHECK-LE-NEXT: vmovmi.16 q0[6], r3
853 ; CHECK-LE-NEXT: lsls r2, r2, #24
854 ; CHECK-LE-NEXT: itt mi
855 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #14]
856 ; CHECK-LE-NEXT: vmovmi.16 q0[7], r2
857 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
858 ; CHECK-LE-NEXT: add sp, #8
859 ; CHECK-LE-NEXT: bx lr
861 ; CHECK-BE-LABEL: masked_v8i16_preinc:
862 ; CHECK-BE: @ %bb.0: @ %entry
863 ; CHECK-BE-NEXT: .pad #8
864 ; CHECK-BE-NEXT: sub sp, #8
865 ; CHECK-BE-NEXT: vldr d1, [sp, #8]
866 ; CHECK-BE-NEXT: adds r0, #4
867 ; CHECK-BE-NEXT: vmov d0, r3, r2
868 ; CHECK-BE-NEXT: mov r2, sp
869 ; CHECK-BE-NEXT: vrev64.16 q1, q0
870 ; CHECK-BE-NEXT: @ implicit-def: $q0
871 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
872 ; CHECK-BE-NEXT: vstr p0, [r2]
873 ; CHECK-BE-NEXT: ldrb.w r2, [sp]
874 ; CHECK-BE-NEXT: lsls r3, r2, #31
875 ; CHECK-BE-NEXT: itt ne
876 ; CHECK-BE-NEXT: ldrhne r3, [r0]
877 ; CHECK-BE-NEXT: vmovne.16 q0[0], r3
878 ; CHECK-BE-NEXT: lsls r3, r2, #30
879 ; CHECK-BE-NEXT: itt mi
880 ; CHECK-BE-NEXT: ldrhmi r3, [r0, #2]
881 ; CHECK-BE-NEXT: vmovmi.16 q0[1], r3
882 ; CHECK-BE-NEXT: lsls r3, r2, #29
883 ; CHECK-BE-NEXT: itt mi
884 ; CHECK-BE-NEXT: ldrhmi r3, [r0, #4]
885 ; CHECK-BE-NEXT: vmovmi.16 q0[2], r3
886 ; CHECK-BE-NEXT: lsls r3, r2, #28
887 ; CHECK-BE-NEXT: itt mi
888 ; CHECK-BE-NEXT: ldrhmi r3, [r0, #6]
889 ; CHECK-BE-NEXT: vmovmi.16 q0[3], r3
890 ; CHECK-BE-NEXT: lsls r3, r2, #27
891 ; CHECK-BE-NEXT: itt mi
892 ; CHECK-BE-NEXT: ldrhmi r3, [r0, #8]
893 ; CHECK-BE-NEXT: vmovmi.16 q0[4], r3
894 ; CHECK-BE-NEXT: lsls r3, r2, #26
895 ; CHECK-BE-NEXT: itt mi
896 ; CHECK-BE-NEXT: ldrhmi r3, [r0, #10]
897 ; CHECK-BE-NEXT: vmovmi.16 q0[5], r3
898 ; CHECK-BE-NEXT: lsls r3, r2, #25
899 ; CHECK-BE-NEXT: itt mi
900 ; CHECK-BE-NEXT: ldrhmi r3, [r0, #12]
901 ; CHECK-BE-NEXT: vmovmi.16 q0[6], r3
902 ; CHECK-BE-NEXT: lsls r2, r2, #24
903 ; CHECK-BE-NEXT: itt mi
904 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #14]
905 ; CHECK-BE-NEXT: vmovmi.16 q0[7], r2
906 ; CHECK-BE-NEXT: vstrh.16 q0, [r1]
907 ; CHECK-BE-NEXT: add sp, #8
908 ; CHECK-BE-NEXT: bx lr
910 %z = getelementptr inbounds i8, i8* %x, i32 4
911 %0 = bitcast i8* %z to <8 x i16>*
912 %c = icmp sgt <8 x i16> %a, zeroinitializer
913 %1 = call <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>* %0, i32 4, <8 x i1> %c, <8 x i16> undef)
914 %2 = bitcast i8* %y to <8 x i16>*
915 store <8 x i16> %1, <8 x i16>* %2, align 4
919 define arm_aapcs_vfpcc i8* @masked_v8i16_postinc(i8* %x, i8* %y, <8 x i16> %a) {
920 ; CHECK-LE-LABEL: masked_v8i16_postinc:
921 ; CHECK-LE: @ %bb.0: @ %entry
922 ; CHECK-LE-NEXT: .pad #8
923 ; CHECK-LE-NEXT: sub sp, #8
924 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
925 ; CHECK-LE-NEXT: mov r2, sp
926 ; CHECK-LE-NEXT: vstr p0, [r2]
927 ; CHECK-LE-NEXT: @ implicit-def: $q0
928 ; CHECK-LE-NEXT: add.w r12, r0, #4
929 ; CHECK-LE-NEXT: ldrb.w r3, [sp]
930 ; CHECK-LE-NEXT: lsls r2, r3, #31
931 ; CHECK-LE-NEXT: itt ne
932 ; CHECK-LE-NEXT: ldrhne r2, [r0]
933 ; CHECK-LE-NEXT: vmovne.16 q0[0], r2
934 ; CHECK-LE-NEXT: lsls r2, r3, #30
935 ; CHECK-LE-NEXT: itt mi
936 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #2]
937 ; CHECK-LE-NEXT: vmovmi.16 q0[1], r2
938 ; CHECK-LE-NEXT: lsls r2, r3, #29
939 ; CHECK-LE-NEXT: itt mi
940 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #4]
941 ; CHECK-LE-NEXT: vmovmi.16 q0[2], r2
942 ; CHECK-LE-NEXT: lsls r2, r3, #28
943 ; CHECK-LE-NEXT: itt mi
944 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #6]
945 ; CHECK-LE-NEXT: vmovmi.16 q0[3], r2
946 ; CHECK-LE-NEXT: lsls r2, r3, #27
947 ; CHECK-LE-NEXT: itt mi
948 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #8]
949 ; CHECK-LE-NEXT: vmovmi.16 q0[4], r2
950 ; CHECK-LE-NEXT: lsls r2, r3, #26
951 ; CHECK-LE-NEXT: itt mi
952 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #10]
953 ; CHECK-LE-NEXT: vmovmi.16 q0[5], r2
954 ; CHECK-LE-NEXT: lsls r2, r3, #25
955 ; CHECK-LE-NEXT: itt mi
956 ; CHECK-LE-NEXT: ldrhmi r2, [r0, #12]
957 ; CHECK-LE-NEXT: vmovmi.16 q0[6], r2
958 ; CHECK-LE-NEXT: lsls r2, r3, #24
959 ; CHECK-LE-NEXT: itt mi
960 ; CHECK-LE-NEXT: ldrhmi r0, [r0, #14]
961 ; CHECK-LE-NEXT: vmovmi.16 q0[7], r0
962 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
963 ; CHECK-LE-NEXT: mov r0, r12
964 ; CHECK-LE-NEXT: add sp, #8
965 ; CHECK-LE-NEXT: bx lr
967 ; CHECK-BE-LABEL: masked_v8i16_postinc:
968 ; CHECK-BE: @ %bb.0: @ %entry
969 ; CHECK-BE-NEXT: .pad #8
970 ; CHECK-BE-NEXT: sub sp, #8
971 ; CHECK-BE-NEXT: vrev64.16 q1, q0
972 ; CHECK-BE-NEXT: mov r2, sp
973 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
974 ; CHECK-BE-NEXT: @ implicit-def: $q0
975 ; CHECK-BE-NEXT: add.w r12, r0, #4
976 ; CHECK-BE-NEXT: vstr p0, [r2]
977 ; CHECK-BE-NEXT: ldrb.w r3, [sp]
978 ; CHECK-BE-NEXT: lsls r2, r3, #31
979 ; CHECK-BE-NEXT: itt ne
980 ; CHECK-BE-NEXT: ldrhne r2, [r0]
981 ; CHECK-BE-NEXT: vmovne.16 q0[0], r2
982 ; CHECK-BE-NEXT: lsls r2, r3, #30
983 ; CHECK-BE-NEXT: itt mi
984 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #2]
985 ; CHECK-BE-NEXT: vmovmi.16 q0[1], r2
986 ; CHECK-BE-NEXT: lsls r2, r3, #29
987 ; CHECK-BE-NEXT: itt mi
988 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #4]
989 ; CHECK-BE-NEXT: vmovmi.16 q0[2], r2
990 ; CHECK-BE-NEXT: lsls r2, r3, #28
991 ; CHECK-BE-NEXT: itt mi
992 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #6]
993 ; CHECK-BE-NEXT: vmovmi.16 q0[3], r2
994 ; CHECK-BE-NEXT: lsls r2, r3, #27
995 ; CHECK-BE-NEXT: itt mi
996 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #8]
997 ; CHECK-BE-NEXT: vmovmi.16 q0[4], r2
998 ; CHECK-BE-NEXT: lsls r2, r3, #26
999 ; CHECK-BE-NEXT: itt mi
1000 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #10]
1001 ; CHECK-BE-NEXT: vmovmi.16 q0[5], r2
1002 ; CHECK-BE-NEXT: lsls r2, r3, #25
1003 ; CHECK-BE-NEXT: itt mi
1004 ; CHECK-BE-NEXT: ldrhmi r2, [r0, #12]
1005 ; CHECK-BE-NEXT: vmovmi.16 q0[6], r2
1006 ; CHECK-BE-NEXT: lsls r2, r3, #24
1007 ; CHECK-BE-NEXT: itt mi
1008 ; CHECK-BE-NEXT: ldrhmi r0, [r0, #14]
1009 ; CHECK-BE-NEXT: vmovmi.16 q0[7], r0
1010 ; CHECK-BE-NEXT: vstrh.16 q0, [r1]
1011 ; CHECK-BE-NEXT: mov r0, r12
1012 ; CHECK-BE-NEXT: add sp, #8
1013 ; CHECK-BE-NEXT: bx lr
1015 %z = getelementptr inbounds i8, i8* %x, i32 4
1016 %0 = bitcast i8* %x to <8 x i16>*
1017 %c = icmp sgt <8 x i16> %a, zeroinitializer
1018 %1 = call <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>* %0, i32 4, <8 x i1> %c, <8 x i16> undef)
1019 %2 = bitcast i8* %y to <8 x i16>*
1020 store <8 x i16> %1, <8 x i16>* %2, align 4
1025 define arm_aapcs_vfpcc <16 x i8> @masked_v16i8_align4_zero(<16 x i8> *%dest, <16 x i8> %a) {
1026 ; CHECK-LE-LABEL: masked_v16i8_align4_zero:
1027 ; CHECK-LE: @ %bb.0: @ %entry
1028 ; CHECK-LE-NEXT: .save {r4, r6, r7, lr}
1029 ; CHECK-LE-NEXT: push {r4, r6, r7, lr}
1030 ; CHECK-LE-NEXT: .setfp r7, sp, #8
1031 ; CHECK-LE-NEXT: add r7, sp, #8
1032 ; CHECK-LE-NEXT: .pad #16
1033 ; CHECK-LE-NEXT: sub sp, #16
1034 ; CHECK-LE-NEXT: mov r4, sp
1035 ; CHECK-LE-NEXT: bfc r4, #0, #4
1036 ; CHECK-LE-NEXT: mov sp, r4
1037 ; CHECK-LE-NEXT: mov r1, sp
1038 ; CHECK-LE-NEXT: vcmp.s8 gt, q0, zr
1039 ; CHECK-LE-NEXT: vstr p0, [r1]
1040 ; CHECK-LE-NEXT: ldrh.w r1, [sp]
1041 ; CHECK-LE-NEXT: lsls r2, r1, #31
1042 ; CHECK-LE-NEXT: beq .LBB12_2
1043 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
1044 ; CHECK-LE-NEXT: movs r2, #0
1045 ; CHECK-LE-NEXT: ldrb r3, [r0]
1046 ; CHECK-LE-NEXT: vdup.8 q0, r2
1047 ; CHECK-LE-NEXT: vmov.8 q0[0], r3
1048 ; CHECK-LE-NEXT: b .LBB12_3
1049 ; CHECK-LE-NEXT: .LBB12_2:
1050 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
1051 ; CHECK-LE-NEXT: .LBB12_3: @ %else
1052 ; CHECK-LE-NEXT: lsls r2, r1, #30
1053 ; CHECK-LE-NEXT: itt mi
1054 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #1]
1055 ; CHECK-LE-NEXT: vmovmi.8 q0[1], r2
1056 ; CHECK-LE-NEXT: lsls r2, r1, #29
1057 ; CHECK-LE-NEXT: itt mi
1058 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #2]
1059 ; CHECK-LE-NEXT: vmovmi.8 q0[2], r2
1060 ; CHECK-LE-NEXT: lsls r2, r1, #28
1061 ; CHECK-LE-NEXT: itt mi
1062 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #3]
1063 ; CHECK-LE-NEXT: vmovmi.8 q0[3], r2
1064 ; CHECK-LE-NEXT: lsls r2, r1, #27
1065 ; CHECK-LE-NEXT: itt mi
1066 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #4]
1067 ; CHECK-LE-NEXT: vmovmi.8 q0[4], r2
1068 ; CHECK-LE-NEXT: lsls r2, r1, #26
1069 ; CHECK-LE-NEXT: itt mi
1070 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #5]
1071 ; CHECK-LE-NEXT: vmovmi.8 q0[5], r2
1072 ; CHECK-LE-NEXT: lsls r2, r1, #25
1073 ; CHECK-LE-NEXT: itt mi
1074 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #6]
1075 ; CHECK-LE-NEXT: vmovmi.8 q0[6], r2
1076 ; CHECK-LE-NEXT: lsls r2, r1, #24
1077 ; CHECK-LE-NEXT: itt mi
1078 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #7]
1079 ; CHECK-LE-NEXT: vmovmi.8 q0[7], r2
1080 ; CHECK-LE-NEXT: lsls r2, r1, #23
1081 ; CHECK-LE-NEXT: itt mi
1082 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #8]
1083 ; CHECK-LE-NEXT: vmovmi.8 q0[8], r2
1084 ; CHECK-LE-NEXT: lsls r2, r1, #22
1085 ; CHECK-LE-NEXT: itt mi
1086 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #9]
1087 ; CHECK-LE-NEXT: vmovmi.8 q0[9], r2
1088 ; CHECK-LE-NEXT: lsls r2, r1, #21
1089 ; CHECK-LE-NEXT: itt mi
1090 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #10]
1091 ; CHECK-LE-NEXT: vmovmi.8 q0[10], r2
1092 ; CHECK-LE-NEXT: lsls r2, r1, #20
1093 ; CHECK-LE-NEXT: itt mi
1094 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #11]
1095 ; CHECK-LE-NEXT: vmovmi.8 q0[11], r2
1096 ; CHECK-LE-NEXT: lsls r2, r1, #19
1097 ; CHECK-LE-NEXT: itt mi
1098 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #12]
1099 ; CHECK-LE-NEXT: vmovmi.8 q0[12], r2
1100 ; CHECK-LE-NEXT: lsls r2, r1, #18
1101 ; CHECK-LE-NEXT: itt mi
1102 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #13]
1103 ; CHECK-LE-NEXT: vmovmi.8 q0[13], r2
1104 ; CHECK-LE-NEXT: sub.w r4, r7, #8
1105 ; CHECK-LE-NEXT: lsls r2, r1, #17
1106 ; CHECK-LE-NEXT: itt mi
1107 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #14]
1108 ; CHECK-LE-NEXT: vmovmi.8 q0[14], r2
1109 ; CHECK-LE-NEXT: lsls r1, r1, #16
1110 ; CHECK-LE-NEXT: itt mi
1111 ; CHECK-LE-NEXT: ldrbmi r0, [r0, #15]
1112 ; CHECK-LE-NEXT: vmovmi.8 q0[15], r0
1113 ; CHECK-LE-NEXT: mov sp, r4
1114 ; CHECK-LE-NEXT: pop {r4, r6, r7, pc}
1116 ; CHECK-BE-LABEL: masked_v16i8_align4_zero:
1117 ; CHECK-BE: @ %bb.0: @ %entry
1118 ; CHECK-BE-NEXT: .save {r4, r6, r7, lr}
1119 ; CHECK-BE-NEXT: push {r4, r6, r7, lr}
1120 ; CHECK-BE-NEXT: .setfp r7, sp, #8
1121 ; CHECK-BE-NEXT: add r7, sp, #8
1122 ; CHECK-BE-NEXT: .pad #16
1123 ; CHECK-BE-NEXT: sub sp, #16
1124 ; CHECK-BE-NEXT: mov r4, sp
1125 ; CHECK-BE-NEXT: bfc r4, #0, #4
1126 ; CHECK-BE-NEXT: mov sp, r4
1127 ; CHECK-BE-NEXT: vrev64.8 q1, q0
1128 ; CHECK-BE-NEXT: mov r1, sp
1129 ; CHECK-BE-NEXT: vcmp.s8 gt, q1, zr
1130 ; CHECK-BE-NEXT: vstr p0, [r1]
1131 ; CHECK-BE-NEXT: ldrh.w r1, [sp]
1132 ; CHECK-BE-NEXT: lsls r2, r1, #31
1133 ; CHECK-BE-NEXT: beq .LBB12_2
1134 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
1135 ; CHECK-BE-NEXT: movs r2, #0
1136 ; CHECK-BE-NEXT: ldrb r3, [r0]
1137 ; CHECK-BE-NEXT: vdup.8 q1, r2
1138 ; CHECK-BE-NEXT: vmov.8 q1[0], r3
1139 ; CHECK-BE-NEXT: b .LBB12_3
1140 ; CHECK-BE-NEXT: .LBB12_2:
1141 ; CHECK-BE-NEXT: vmov.i32 q0, #0x0
1142 ; CHECK-BE-NEXT: vrev32.8 q1, q0
1143 ; CHECK-BE-NEXT: .LBB12_3: @ %else
1144 ; CHECK-BE-NEXT: lsls r2, r1, #30
1145 ; CHECK-BE-NEXT: itt mi
1146 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #1]
1147 ; CHECK-BE-NEXT: vmovmi.8 q1[1], r2
1148 ; CHECK-BE-NEXT: lsls r2, r1, #29
1149 ; CHECK-BE-NEXT: itt mi
1150 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #2]
1151 ; CHECK-BE-NEXT: vmovmi.8 q1[2], r2
1152 ; CHECK-BE-NEXT: lsls r2, r1, #28
1153 ; CHECK-BE-NEXT: itt mi
1154 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #3]
1155 ; CHECK-BE-NEXT: vmovmi.8 q1[3], r2
1156 ; CHECK-BE-NEXT: lsls r2, r1, #27
1157 ; CHECK-BE-NEXT: itt mi
1158 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #4]
1159 ; CHECK-BE-NEXT: vmovmi.8 q1[4], r2
1160 ; CHECK-BE-NEXT: lsls r2, r1, #26
1161 ; CHECK-BE-NEXT: itt mi
1162 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #5]
1163 ; CHECK-BE-NEXT: vmovmi.8 q1[5], r2
1164 ; CHECK-BE-NEXT: lsls r2, r1, #25
1165 ; CHECK-BE-NEXT: itt mi
1166 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #6]
1167 ; CHECK-BE-NEXT: vmovmi.8 q1[6], r2
1168 ; CHECK-BE-NEXT: lsls r2, r1, #24
1169 ; CHECK-BE-NEXT: itt mi
1170 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #7]
1171 ; CHECK-BE-NEXT: vmovmi.8 q1[7], r2
1172 ; CHECK-BE-NEXT: lsls r2, r1, #23
1173 ; CHECK-BE-NEXT: itt mi
1174 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #8]
1175 ; CHECK-BE-NEXT: vmovmi.8 q1[8], r2
1176 ; CHECK-BE-NEXT: lsls r2, r1, #22
1177 ; CHECK-BE-NEXT: itt mi
1178 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #9]
1179 ; CHECK-BE-NEXT: vmovmi.8 q1[9], r2
1180 ; CHECK-BE-NEXT: lsls r2, r1, #21
1181 ; CHECK-BE-NEXT: itt mi
1182 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #10]
1183 ; CHECK-BE-NEXT: vmovmi.8 q1[10], r2
1184 ; CHECK-BE-NEXT: lsls r2, r1, #20
1185 ; CHECK-BE-NEXT: itt mi
1186 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #11]
1187 ; CHECK-BE-NEXT: vmovmi.8 q1[11], r2
1188 ; CHECK-BE-NEXT: lsls r2, r1, #19
1189 ; CHECK-BE-NEXT: itt mi
1190 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #12]
1191 ; CHECK-BE-NEXT: vmovmi.8 q1[12], r2
1192 ; CHECK-BE-NEXT: lsls r2, r1, #18
1193 ; CHECK-BE-NEXT: itt mi
1194 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #13]
1195 ; CHECK-BE-NEXT: vmovmi.8 q1[13], r2
1196 ; CHECK-BE-NEXT: sub.w r4, r7, #8
1197 ; CHECK-BE-NEXT: lsls r2, r1, #17
1198 ; CHECK-BE-NEXT: itt mi
1199 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #14]
1200 ; CHECK-BE-NEXT: vmovmi.8 q1[14], r2
1201 ; CHECK-BE-NEXT: lsls r1, r1, #16
1202 ; CHECK-BE-NEXT: itt mi
1203 ; CHECK-BE-NEXT: ldrbmi r0, [r0, #15]
1204 ; CHECK-BE-NEXT: vmovmi.8 q1[15], r0
1205 ; CHECK-BE-NEXT: vrev64.8 q0, q1
1206 ; CHECK-BE-NEXT: mov sp, r4
1207 ; CHECK-BE-NEXT: pop {r4, r6, r7, pc}
1209 %c = icmp sgt <16 x i8> %a, zeroinitializer
1210 %l = call <16 x i8> @llvm.masked.load.v16i8.p0v16i8(<16 x i8>* %dest, i32 1, <16 x i1> %c, <16 x i8> zeroinitializer)
1214 define arm_aapcs_vfpcc <16 x i8> @masked_v16i8_align4_undef(<16 x i8> *%dest, <16 x i8> %a) {
1215 ; CHECK-LE-LABEL: masked_v16i8_align4_undef:
1216 ; CHECK-LE: @ %bb.0: @ %entry
1217 ; CHECK-LE-NEXT: .save {r4, r6, r7, lr}
1218 ; CHECK-LE-NEXT: push {r4, r6, r7, lr}
1219 ; CHECK-LE-NEXT: .setfp r7, sp, #8
1220 ; CHECK-LE-NEXT: add r7, sp, #8
1221 ; CHECK-LE-NEXT: .pad #16
1222 ; CHECK-LE-NEXT: sub sp, #16
1223 ; CHECK-LE-NEXT: mov r4, sp
1224 ; CHECK-LE-NEXT: bfc r4, #0, #4
1225 ; CHECK-LE-NEXT: mov sp, r4
1226 ; CHECK-LE-NEXT: vcmp.s8 gt, q0, zr
1227 ; CHECK-LE-NEXT: mov r1, sp
1228 ; CHECK-LE-NEXT: vstr p0, [r1]
1229 ; CHECK-LE-NEXT: @ implicit-def: $q0
1230 ; CHECK-LE-NEXT: sub.w r4, r7, #8
1231 ; CHECK-LE-NEXT: ldrh.w r1, [sp]
1232 ; CHECK-LE-NEXT: lsls r2, r1, #31
1233 ; CHECK-LE-NEXT: itt ne
1234 ; CHECK-LE-NEXT: ldrbne r2, [r0]
1235 ; CHECK-LE-NEXT: vmovne.8 q0[0], r2
1236 ; CHECK-LE-NEXT: lsls r2, r1, #30
1237 ; CHECK-LE-NEXT: itt mi
1238 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #1]
1239 ; CHECK-LE-NEXT: vmovmi.8 q0[1], r2
1240 ; CHECK-LE-NEXT: lsls r2, r1, #29
1241 ; CHECK-LE-NEXT: itt mi
1242 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #2]
1243 ; CHECK-LE-NEXT: vmovmi.8 q0[2], r2
1244 ; CHECK-LE-NEXT: lsls r2, r1, #28
1245 ; CHECK-LE-NEXT: itt mi
1246 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #3]
1247 ; CHECK-LE-NEXT: vmovmi.8 q0[3], r2
1248 ; CHECK-LE-NEXT: lsls r2, r1, #27
1249 ; CHECK-LE-NEXT: itt mi
1250 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #4]
1251 ; CHECK-LE-NEXT: vmovmi.8 q0[4], r2
1252 ; CHECK-LE-NEXT: lsls r2, r1, #26
1253 ; CHECK-LE-NEXT: itt mi
1254 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #5]
1255 ; CHECK-LE-NEXT: vmovmi.8 q0[5], r2
1256 ; CHECK-LE-NEXT: lsls r2, r1, #25
1257 ; CHECK-LE-NEXT: itt mi
1258 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #6]
1259 ; CHECK-LE-NEXT: vmovmi.8 q0[6], r2
1260 ; CHECK-LE-NEXT: lsls r2, r1, #24
1261 ; CHECK-LE-NEXT: itt mi
1262 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #7]
1263 ; CHECK-LE-NEXT: vmovmi.8 q0[7], r2
1264 ; CHECK-LE-NEXT: lsls r2, r1, #23
1265 ; CHECK-LE-NEXT: itt mi
1266 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #8]
1267 ; CHECK-LE-NEXT: vmovmi.8 q0[8], r2
1268 ; CHECK-LE-NEXT: lsls r2, r1, #22
1269 ; CHECK-LE-NEXT: itt mi
1270 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #9]
1271 ; CHECK-LE-NEXT: vmovmi.8 q0[9], r2
1272 ; CHECK-LE-NEXT: lsls r2, r1, #21
1273 ; CHECK-LE-NEXT: itt mi
1274 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #10]
1275 ; CHECK-LE-NEXT: vmovmi.8 q0[10], r2
1276 ; CHECK-LE-NEXT: lsls r2, r1, #20
1277 ; CHECK-LE-NEXT: itt mi
1278 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #11]
1279 ; CHECK-LE-NEXT: vmovmi.8 q0[11], r2
1280 ; CHECK-LE-NEXT: lsls r2, r1, #19
1281 ; CHECK-LE-NEXT: itt mi
1282 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #12]
1283 ; CHECK-LE-NEXT: vmovmi.8 q0[12], r2
1284 ; CHECK-LE-NEXT: lsls r2, r1, #18
1285 ; CHECK-LE-NEXT: itt mi
1286 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #13]
1287 ; CHECK-LE-NEXT: vmovmi.8 q0[13], r2
1288 ; CHECK-LE-NEXT: lsls r2, r1, #17
1289 ; CHECK-LE-NEXT: itt mi
1290 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #14]
1291 ; CHECK-LE-NEXT: vmovmi.8 q0[14], r2
1292 ; CHECK-LE-NEXT: lsls r1, r1, #16
1293 ; CHECK-LE-NEXT: itt mi
1294 ; CHECK-LE-NEXT: ldrbmi r0, [r0, #15]
1295 ; CHECK-LE-NEXT: vmovmi.8 q0[15], r0
1296 ; CHECK-LE-NEXT: mov sp, r4
1297 ; CHECK-LE-NEXT: pop {r4, r6, r7, pc}
1299 ; CHECK-BE-LABEL: masked_v16i8_align4_undef:
1300 ; CHECK-BE: @ %bb.0: @ %entry
1301 ; CHECK-BE-NEXT: .save {r4, r6, r7, lr}
1302 ; CHECK-BE-NEXT: push {r4, r6, r7, lr}
1303 ; CHECK-BE-NEXT: .setfp r7, sp, #8
1304 ; CHECK-BE-NEXT: add r7, sp, #8
1305 ; CHECK-BE-NEXT: .pad #16
1306 ; CHECK-BE-NEXT: sub sp, #16
1307 ; CHECK-BE-NEXT: mov r4, sp
1308 ; CHECK-BE-NEXT: bfc r4, #0, #4
1309 ; CHECK-BE-NEXT: mov sp, r4
1310 ; CHECK-BE-NEXT: vrev64.8 q1, q0
1311 ; CHECK-BE-NEXT: mov r1, sp
1312 ; CHECK-BE-NEXT: vcmp.s8 gt, q1, zr
1313 ; CHECK-BE-NEXT: @ implicit-def: $q1
1314 ; CHECK-BE-NEXT: sub.w r4, r7, #8
1315 ; CHECK-BE-NEXT: vstr p0, [r1]
1316 ; CHECK-BE-NEXT: ldrh.w r1, [sp]
1317 ; CHECK-BE-NEXT: lsls r2, r1, #31
1318 ; CHECK-BE-NEXT: itt ne
1319 ; CHECK-BE-NEXT: ldrbne r2, [r0]
1320 ; CHECK-BE-NEXT: vmovne.8 q1[0], r2
1321 ; CHECK-BE-NEXT: lsls r2, r1, #30
1322 ; CHECK-BE-NEXT: itt mi
1323 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #1]
1324 ; CHECK-BE-NEXT: vmovmi.8 q1[1], r2
1325 ; CHECK-BE-NEXT: lsls r2, r1, #29
1326 ; CHECK-BE-NEXT: itt mi
1327 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #2]
1328 ; CHECK-BE-NEXT: vmovmi.8 q1[2], r2
1329 ; CHECK-BE-NEXT: lsls r2, r1, #28
1330 ; CHECK-BE-NEXT: itt mi
1331 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #3]
1332 ; CHECK-BE-NEXT: vmovmi.8 q1[3], r2
1333 ; CHECK-BE-NEXT: lsls r2, r1, #27
1334 ; CHECK-BE-NEXT: itt mi
1335 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #4]
1336 ; CHECK-BE-NEXT: vmovmi.8 q1[4], r2
1337 ; CHECK-BE-NEXT: lsls r2, r1, #26
1338 ; CHECK-BE-NEXT: itt mi
1339 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #5]
1340 ; CHECK-BE-NEXT: vmovmi.8 q1[5], r2
1341 ; CHECK-BE-NEXT: lsls r2, r1, #25
1342 ; CHECK-BE-NEXT: itt mi
1343 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #6]
1344 ; CHECK-BE-NEXT: vmovmi.8 q1[6], r2
1345 ; CHECK-BE-NEXT: lsls r2, r1, #24
1346 ; CHECK-BE-NEXT: itt mi
1347 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #7]
1348 ; CHECK-BE-NEXT: vmovmi.8 q1[7], r2
1349 ; CHECK-BE-NEXT: lsls r2, r1, #23
1350 ; CHECK-BE-NEXT: itt mi
1351 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #8]
1352 ; CHECK-BE-NEXT: vmovmi.8 q1[8], r2
1353 ; CHECK-BE-NEXT: lsls r2, r1, #22
1354 ; CHECK-BE-NEXT: itt mi
1355 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #9]
1356 ; CHECK-BE-NEXT: vmovmi.8 q1[9], r2
1357 ; CHECK-BE-NEXT: lsls r2, r1, #21
1358 ; CHECK-BE-NEXT: itt mi
1359 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #10]
1360 ; CHECK-BE-NEXT: vmovmi.8 q1[10], r2
1361 ; CHECK-BE-NEXT: lsls r2, r1, #20
1362 ; CHECK-BE-NEXT: itt mi
1363 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #11]
1364 ; CHECK-BE-NEXT: vmovmi.8 q1[11], r2
1365 ; CHECK-BE-NEXT: lsls r2, r1, #19
1366 ; CHECK-BE-NEXT: itt mi
1367 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #12]
1368 ; CHECK-BE-NEXT: vmovmi.8 q1[12], r2
1369 ; CHECK-BE-NEXT: lsls r2, r1, #18
1370 ; CHECK-BE-NEXT: itt mi
1371 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #13]
1372 ; CHECK-BE-NEXT: vmovmi.8 q1[13], r2
1373 ; CHECK-BE-NEXT: lsls r2, r1, #17
1374 ; CHECK-BE-NEXT: itt mi
1375 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #14]
1376 ; CHECK-BE-NEXT: vmovmi.8 q1[14], r2
1377 ; CHECK-BE-NEXT: lsls r1, r1, #16
1378 ; CHECK-BE-NEXT: itt mi
1379 ; CHECK-BE-NEXT: ldrbmi r0, [r0, #15]
1380 ; CHECK-BE-NEXT: vmovmi.8 q1[15], r0
1381 ; CHECK-BE-NEXT: vrev64.8 q0, q1
1382 ; CHECK-BE-NEXT: mov sp, r4
1383 ; CHECK-BE-NEXT: pop {r4, r6, r7, pc}
1385 %c = icmp sgt <16 x i8> %a, zeroinitializer
1386 %l = call <16 x i8> @llvm.masked.load.v16i8.p0v16i8(<16 x i8>* %dest, i32 1, <16 x i1> %c, <16 x i8> undef)
1390 define arm_aapcs_vfpcc <16 x i8> @masked_v16i8_align4_other(<16 x i8> *%dest, <16 x i8> %a) {
1391 ; CHECK-LE-LABEL: masked_v16i8_align4_other:
1392 ; CHECK-LE: @ %bb.0: @ %entry
1393 ; CHECK-LE-NEXT: .save {r4, r6, r7, lr}
1394 ; CHECK-LE-NEXT: push {r4, r6, r7, lr}
1395 ; CHECK-LE-NEXT: .setfp r7, sp, #8
1396 ; CHECK-LE-NEXT: add r7, sp, #8
1397 ; CHECK-LE-NEXT: .pad #16
1398 ; CHECK-LE-NEXT: sub sp, #16
1399 ; CHECK-LE-NEXT: mov r4, sp
1400 ; CHECK-LE-NEXT: bfc r4, #0, #4
1401 ; CHECK-LE-NEXT: mov sp, r4
1402 ; CHECK-LE-NEXT: mov r1, sp
1403 ; CHECK-LE-NEXT: vcmp.s8 gt, q0, zr
1404 ; CHECK-LE-NEXT: vstr p0, [r1]
1405 ; CHECK-LE-NEXT: sub.w r4, r7, #8
1406 ; CHECK-LE-NEXT: ldrh.w r1, [sp]
1407 ; CHECK-LE-NEXT: lsls r2, r1, #31
1408 ; CHECK-LE-NEXT: itt ne
1409 ; CHECK-LE-NEXT: ldrbne r2, [r0]
1410 ; CHECK-LE-NEXT: vmovne.8 q0[0], r2
1411 ; CHECK-LE-NEXT: lsls r2, r1, #30
1412 ; CHECK-LE-NEXT: itt mi
1413 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #1]
1414 ; CHECK-LE-NEXT: vmovmi.8 q0[1], r2
1415 ; CHECK-LE-NEXT: lsls r2, r1, #29
1416 ; CHECK-LE-NEXT: itt mi
1417 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #2]
1418 ; CHECK-LE-NEXT: vmovmi.8 q0[2], r2
1419 ; CHECK-LE-NEXT: lsls r2, r1, #28
1420 ; CHECK-LE-NEXT: itt mi
1421 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #3]
1422 ; CHECK-LE-NEXT: vmovmi.8 q0[3], r2
1423 ; CHECK-LE-NEXT: lsls r2, r1, #27
1424 ; CHECK-LE-NEXT: itt mi
1425 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #4]
1426 ; CHECK-LE-NEXT: vmovmi.8 q0[4], r2
1427 ; CHECK-LE-NEXT: lsls r2, r1, #26
1428 ; CHECK-LE-NEXT: itt mi
1429 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #5]
1430 ; CHECK-LE-NEXT: vmovmi.8 q0[5], r2
1431 ; CHECK-LE-NEXT: lsls r2, r1, #25
1432 ; CHECK-LE-NEXT: itt mi
1433 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #6]
1434 ; CHECK-LE-NEXT: vmovmi.8 q0[6], r2
1435 ; CHECK-LE-NEXT: lsls r2, r1, #24
1436 ; CHECK-LE-NEXT: itt mi
1437 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #7]
1438 ; CHECK-LE-NEXT: vmovmi.8 q0[7], r2
1439 ; CHECK-LE-NEXT: lsls r2, r1, #23
1440 ; CHECK-LE-NEXT: itt mi
1441 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #8]
1442 ; CHECK-LE-NEXT: vmovmi.8 q0[8], r2
1443 ; CHECK-LE-NEXT: lsls r2, r1, #22
1444 ; CHECK-LE-NEXT: itt mi
1445 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #9]
1446 ; CHECK-LE-NEXT: vmovmi.8 q0[9], r2
1447 ; CHECK-LE-NEXT: lsls r2, r1, #21
1448 ; CHECK-LE-NEXT: itt mi
1449 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #10]
1450 ; CHECK-LE-NEXT: vmovmi.8 q0[10], r2
1451 ; CHECK-LE-NEXT: lsls r2, r1, #20
1452 ; CHECK-LE-NEXT: itt mi
1453 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #11]
1454 ; CHECK-LE-NEXT: vmovmi.8 q0[11], r2
1455 ; CHECK-LE-NEXT: lsls r2, r1, #19
1456 ; CHECK-LE-NEXT: itt mi
1457 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #12]
1458 ; CHECK-LE-NEXT: vmovmi.8 q0[12], r2
1459 ; CHECK-LE-NEXT: lsls r2, r1, #18
1460 ; CHECK-LE-NEXT: itt mi
1461 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #13]
1462 ; CHECK-LE-NEXT: vmovmi.8 q0[13], r2
1463 ; CHECK-LE-NEXT: lsls r2, r1, #17
1464 ; CHECK-LE-NEXT: itt mi
1465 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #14]
1466 ; CHECK-LE-NEXT: vmovmi.8 q0[14], r2
1467 ; CHECK-LE-NEXT: lsls r1, r1, #16
1468 ; CHECK-LE-NEXT: itt mi
1469 ; CHECK-LE-NEXT: ldrbmi r0, [r0, #15]
1470 ; CHECK-LE-NEXT: vmovmi.8 q0[15], r0
1471 ; CHECK-LE-NEXT: mov sp, r4
1472 ; CHECK-LE-NEXT: pop {r4, r6, r7, pc}
1474 ; CHECK-BE-LABEL: masked_v16i8_align4_other:
1475 ; CHECK-BE: @ %bb.0: @ %entry
1476 ; CHECK-BE-NEXT: .save {r4, r6, r7, lr}
1477 ; CHECK-BE-NEXT: push {r4, r6, r7, lr}
1478 ; CHECK-BE-NEXT: .setfp r7, sp, #8
1479 ; CHECK-BE-NEXT: add r7, sp, #8
1480 ; CHECK-BE-NEXT: .pad #16
1481 ; CHECK-BE-NEXT: sub sp, #16
1482 ; CHECK-BE-NEXT: mov r4, sp
1483 ; CHECK-BE-NEXT: bfc r4, #0, #4
1484 ; CHECK-BE-NEXT: mov sp, r4
1485 ; CHECK-BE-NEXT: vrev64.8 q1, q0
1486 ; CHECK-BE-NEXT: mov r1, sp
1487 ; CHECK-BE-NEXT: vcmp.s8 gt, q1, zr
1488 ; CHECK-BE-NEXT: sub.w r4, r7, #8
1489 ; CHECK-BE-NEXT: vstr p0, [r1]
1490 ; CHECK-BE-NEXT: ldrh.w r1, [sp]
1491 ; CHECK-BE-NEXT: lsls r2, r1, #31
1492 ; CHECK-BE-NEXT: itt ne
1493 ; CHECK-BE-NEXT: ldrbne r2, [r0]
1494 ; CHECK-BE-NEXT: vmovne.8 q1[0], r2
1495 ; CHECK-BE-NEXT: lsls r2, r1, #30
1496 ; CHECK-BE-NEXT: itt mi
1497 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #1]
1498 ; CHECK-BE-NEXT: vmovmi.8 q1[1], r2
1499 ; CHECK-BE-NEXT: lsls r2, r1, #29
1500 ; CHECK-BE-NEXT: itt mi
1501 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #2]
1502 ; CHECK-BE-NEXT: vmovmi.8 q1[2], r2
1503 ; CHECK-BE-NEXT: lsls r2, r1, #28
1504 ; CHECK-BE-NEXT: itt mi
1505 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #3]
1506 ; CHECK-BE-NEXT: vmovmi.8 q1[3], r2
1507 ; CHECK-BE-NEXT: lsls r2, r1, #27
1508 ; CHECK-BE-NEXT: itt mi
1509 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #4]
1510 ; CHECK-BE-NEXT: vmovmi.8 q1[4], r2
1511 ; CHECK-BE-NEXT: lsls r2, r1, #26
1512 ; CHECK-BE-NEXT: itt mi
1513 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #5]
1514 ; CHECK-BE-NEXT: vmovmi.8 q1[5], r2
1515 ; CHECK-BE-NEXT: lsls r2, r1, #25
1516 ; CHECK-BE-NEXT: itt mi
1517 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #6]
1518 ; CHECK-BE-NEXT: vmovmi.8 q1[6], r2
1519 ; CHECK-BE-NEXT: lsls r2, r1, #24
1520 ; CHECK-BE-NEXT: itt mi
1521 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #7]
1522 ; CHECK-BE-NEXT: vmovmi.8 q1[7], r2
1523 ; CHECK-BE-NEXT: lsls r2, r1, #23
1524 ; CHECK-BE-NEXT: itt mi
1525 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #8]
1526 ; CHECK-BE-NEXT: vmovmi.8 q1[8], r2
1527 ; CHECK-BE-NEXT: lsls r2, r1, #22
1528 ; CHECK-BE-NEXT: itt mi
1529 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #9]
1530 ; CHECK-BE-NEXT: vmovmi.8 q1[9], r2
1531 ; CHECK-BE-NEXT: lsls r2, r1, #21
1532 ; CHECK-BE-NEXT: itt mi
1533 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #10]
1534 ; CHECK-BE-NEXT: vmovmi.8 q1[10], r2
1535 ; CHECK-BE-NEXT: lsls r2, r1, #20
1536 ; CHECK-BE-NEXT: itt mi
1537 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #11]
1538 ; CHECK-BE-NEXT: vmovmi.8 q1[11], r2
1539 ; CHECK-BE-NEXT: lsls r2, r1, #19
1540 ; CHECK-BE-NEXT: itt mi
1541 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #12]
1542 ; CHECK-BE-NEXT: vmovmi.8 q1[12], r2
1543 ; CHECK-BE-NEXT: lsls r2, r1, #18
1544 ; CHECK-BE-NEXT: itt mi
1545 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #13]
1546 ; CHECK-BE-NEXT: vmovmi.8 q1[13], r2
1547 ; CHECK-BE-NEXT: lsls r2, r1, #17
1548 ; CHECK-BE-NEXT: itt mi
1549 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #14]
1550 ; CHECK-BE-NEXT: vmovmi.8 q1[14], r2
1551 ; CHECK-BE-NEXT: lsls r1, r1, #16
1552 ; CHECK-BE-NEXT: itt mi
1553 ; CHECK-BE-NEXT: ldrbmi r0, [r0, #15]
1554 ; CHECK-BE-NEXT: vmovmi.8 q1[15], r0
1555 ; CHECK-BE-NEXT: vrev64.8 q0, q1
1556 ; CHECK-BE-NEXT: mov sp, r4
1557 ; CHECK-BE-NEXT: pop {r4, r6, r7, pc}
1559 %c = icmp sgt <16 x i8> %a, zeroinitializer
1560 %l = call <16 x i8> @llvm.masked.load.v16i8.p0v16i8(<16 x i8>* %dest, i32 1, <16 x i1> %c, <16 x i8> %a)
1564 define arm_aapcs_vfpcc i8* @masked_v16i8_preinc(i8* %x, i8* %y, <16 x i8> %a) {
1565 ; CHECK-LE-LABEL: masked_v16i8_preinc:
1566 ; CHECK-LE: @ %bb.0: @ %entry
1567 ; CHECK-LE-NEXT: .save {r4, r6, r7, lr}
1568 ; CHECK-LE-NEXT: push {r4, r6, r7, lr}
1569 ; CHECK-LE-NEXT: .setfp r7, sp, #8
1570 ; CHECK-LE-NEXT: add r7, sp, #8
1571 ; CHECK-LE-NEXT: .pad #16
1572 ; CHECK-LE-NEXT: sub sp, #16
1573 ; CHECK-LE-NEXT: mov r4, sp
1574 ; CHECK-LE-NEXT: bfc r4, #0, #4
1575 ; CHECK-LE-NEXT: mov sp, r4
1576 ; CHECK-LE-NEXT: vcmp.s8 gt, q0, zr
1577 ; CHECK-LE-NEXT: mov r2, sp
1578 ; CHECK-LE-NEXT: vstr p0, [r2]
1579 ; CHECK-LE-NEXT: @ implicit-def: $q0
1580 ; CHECK-LE-NEXT: adds r0, #4
1581 ; CHECK-LE-NEXT: ldrh.w r2, [sp]
1582 ; CHECK-LE-NEXT: sub.w r4, r7, #8
1583 ; CHECK-LE-NEXT: lsls r3, r2, #31
1584 ; CHECK-LE-NEXT: itt ne
1585 ; CHECK-LE-NEXT: ldrbne r3, [r0]
1586 ; CHECK-LE-NEXT: vmovne.8 q0[0], r3
1587 ; CHECK-LE-NEXT: lsls r3, r2, #30
1588 ; CHECK-LE-NEXT: itt mi
1589 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #1]
1590 ; CHECK-LE-NEXT: vmovmi.8 q0[1], r3
1591 ; CHECK-LE-NEXT: lsls r3, r2, #29
1592 ; CHECK-LE-NEXT: itt mi
1593 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #2]
1594 ; CHECK-LE-NEXT: vmovmi.8 q0[2], r3
1595 ; CHECK-LE-NEXT: lsls r3, r2, #28
1596 ; CHECK-LE-NEXT: itt mi
1597 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #3]
1598 ; CHECK-LE-NEXT: vmovmi.8 q0[3], r3
1599 ; CHECK-LE-NEXT: lsls r3, r2, #27
1600 ; CHECK-LE-NEXT: itt mi
1601 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #4]
1602 ; CHECK-LE-NEXT: vmovmi.8 q0[4], r3
1603 ; CHECK-LE-NEXT: lsls r3, r2, #26
1604 ; CHECK-LE-NEXT: itt mi
1605 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #5]
1606 ; CHECK-LE-NEXT: vmovmi.8 q0[5], r3
1607 ; CHECK-LE-NEXT: lsls r3, r2, #25
1608 ; CHECK-LE-NEXT: itt mi
1609 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #6]
1610 ; CHECK-LE-NEXT: vmovmi.8 q0[6], r3
1611 ; CHECK-LE-NEXT: lsls r3, r2, #24
1612 ; CHECK-LE-NEXT: itt mi
1613 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #7]
1614 ; CHECK-LE-NEXT: vmovmi.8 q0[7], r3
1615 ; CHECK-LE-NEXT: lsls r3, r2, #23
1616 ; CHECK-LE-NEXT: itt mi
1617 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #8]
1618 ; CHECK-LE-NEXT: vmovmi.8 q0[8], r3
1619 ; CHECK-LE-NEXT: lsls r3, r2, #22
1620 ; CHECK-LE-NEXT: itt mi
1621 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #9]
1622 ; CHECK-LE-NEXT: vmovmi.8 q0[9], r3
1623 ; CHECK-LE-NEXT: lsls r3, r2, #21
1624 ; CHECK-LE-NEXT: itt mi
1625 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #10]
1626 ; CHECK-LE-NEXT: vmovmi.8 q0[10], r3
1627 ; CHECK-LE-NEXT: lsls r3, r2, #20
1628 ; CHECK-LE-NEXT: itt mi
1629 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #11]
1630 ; CHECK-LE-NEXT: vmovmi.8 q0[11], r3
1631 ; CHECK-LE-NEXT: lsls r3, r2, #19
1632 ; CHECK-LE-NEXT: itt mi
1633 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #12]
1634 ; CHECK-LE-NEXT: vmovmi.8 q0[12], r3
1635 ; CHECK-LE-NEXT: lsls r3, r2, #18
1636 ; CHECK-LE-NEXT: itt mi
1637 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #13]
1638 ; CHECK-LE-NEXT: vmovmi.8 q0[13], r3
1639 ; CHECK-LE-NEXT: lsls r3, r2, #17
1640 ; CHECK-LE-NEXT: itt mi
1641 ; CHECK-LE-NEXT: ldrbmi r3, [r0, #14]
1642 ; CHECK-LE-NEXT: vmovmi.8 q0[14], r3
1643 ; CHECK-LE-NEXT: lsls r2, r2, #16
1644 ; CHECK-LE-NEXT: itt mi
1645 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #15]
1646 ; CHECK-LE-NEXT: vmovmi.8 q0[15], r2
1647 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
1648 ; CHECK-LE-NEXT: mov sp, r4
1649 ; CHECK-LE-NEXT: pop {r4, r6, r7, pc}
1651 ; CHECK-BE-LABEL: masked_v16i8_preinc:
1652 ; CHECK-BE: @ %bb.0: @ %entry
1653 ; CHECK-BE-NEXT: .save {r4, r6, r7, lr}
1654 ; CHECK-BE-NEXT: push {r4, r6, r7, lr}
1655 ; CHECK-BE-NEXT: .setfp r7, sp, #8
1656 ; CHECK-BE-NEXT: add r7, sp, #8
1657 ; CHECK-BE-NEXT: .pad #16
1658 ; CHECK-BE-NEXT: sub sp, #16
1659 ; CHECK-BE-NEXT: mov r4, sp
1660 ; CHECK-BE-NEXT: bfc r4, #0, #4
1661 ; CHECK-BE-NEXT: mov sp, r4
1662 ; CHECK-BE-NEXT: vrev64.8 q1, q0
1663 ; CHECK-BE-NEXT: mov r2, sp
1664 ; CHECK-BE-NEXT: vcmp.s8 gt, q1, zr
1665 ; CHECK-BE-NEXT: @ implicit-def: $q0
1666 ; CHECK-BE-NEXT: adds r0, #4
1667 ; CHECK-BE-NEXT: vstr p0, [r2]
1668 ; CHECK-BE-NEXT: sub.w r4, r7, #8
1669 ; CHECK-BE-NEXT: ldrh.w r2, [sp]
1670 ; CHECK-BE-NEXT: lsls r3, r2, #31
1671 ; CHECK-BE-NEXT: itt ne
1672 ; CHECK-BE-NEXT: ldrbne r3, [r0]
1673 ; CHECK-BE-NEXT: vmovne.8 q0[0], r3
1674 ; CHECK-BE-NEXT: lsls r3, r2, #30
1675 ; CHECK-BE-NEXT: itt mi
1676 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #1]
1677 ; CHECK-BE-NEXT: vmovmi.8 q0[1], r3
1678 ; CHECK-BE-NEXT: lsls r3, r2, #29
1679 ; CHECK-BE-NEXT: itt mi
1680 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #2]
1681 ; CHECK-BE-NEXT: vmovmi.8 q0[2], r3
1682 ; CHECK-BE-NEXT: lsls r3, r2, #28
1683 ; CHECK-BE-NEXT: itt mi
1684 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #3]
1685 ; CHECK-BE-NEXT: vmovmi.8 q0[3], r3
1686 ; CHECK-BE-NEXT: lsls r3, r2, #27
1687 ; CHECK-BE-NEXT: itt mi
1688 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #4]
1689 ; CHECK-BE-NEXT: vmovmi.8 q0[4], r3
1690 ; CHECK-BE-NEXT: lsls r3, r2, #26
1691 ; CHECK-BE-NEXT: itt mi
1692 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #5]
1693 ; CHECK-BE-NEXT: vmovmi.8 q0[5], r3
1694 ; CHECK-BE-NEXT: lsls r3, r2, #25
1695 ; CHECK-BE-NEXT: itt mi
1696 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #6]
1697 ; CHECK-BE-NEXT: vmovmi.8 q0[6], r3
1698 ; CHECK-BE-NEXT: lsls r3, r2, #24
1699 ; CHECK-BE-NEXT: itt mi
1700 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #7]
1701 ; CHECK-BE-NEXT: vmovmi.8 q0[7], r3
1702 ; CHECK-BE-NEXT: lsls r3, r2, #23
1703 ; CHECK-BE-NEXT: itt mi
1704 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #8]
1705 ; CHECK-BE-NEXT: vmovmi.8 q0[8], r3
1706 ; CHECK-BE-NEXT: lsls r3, r2, #22
1707 ; CHECK-BE-NEXT: itt mi
1708 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #9]
1709 ; CHECK-BE-NEXT: vmovmi.8 q0[9], r3
1710 ; CHECK-BE-NEXT: lsls r3, r2, #21
1711 ; CHECK-BE-NEXT: itt mi
1712 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #10]
1713 ; CHECK-BE-NEXT: vmovmi.8 q0[10], r3
1714 ; CHECK-BE-NEXT: lsls r3, r2, #20
1715 ; CHECK-BE-NEXT: itt mi
1716 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #11]
1717 ; CHECK-BE-NEXT: vmovmi.8 q0[11], r3
1718 ; CHECK-BE-NEXT: lsls r3, r2, #19
1719 ; CHECK-BE-NEXT: itt mi
1720 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #12]
1721 ; CHECK-BE-NEXT: vmovmi.8 q0[12], r3
1722 ; CHECK-BE-NEXT: lsls r3, r2, #18
1723 ; CHECK-BE-NEXT: itt mi
1724 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #13]
1725 ; CHECK-BE-NEXT: vmovmi.8 q0[13], r3
1726 ; CHECK-BE-NEXT: lsls r3, r2, #17
1727 ; CHECK-BE-NEXT: itt mi
1728 ; CHECK-BE-NEXT: ldrbmi r3, [r0, #14]
1729 ; CHECK-BE-NEXT: vmovmi.8 q0[14], r3
1730 ; CHECK-BE-NEXT: lsls r2, r2, #16
1731 ; CHECK-BE-NEXT: itt mi
1732 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #15]
1733 ; CHECK-BE-NEXT: vmovmi.8 q0[15], r2
1734 ; CHECK-BE-NEXT: vstrb.8 q0, [r1]
1735 ; CHECK-BE-NEXT: mov sp, r4
1736 ; CHECK-BE-NEXT: pop {r4, r6, r7, pc}
1738 %z = getelementptr inbounds i8, i8* %x, i32 4
1739 %0 = bitcast i8* %z to <16 x i8>*
1740 %c = icmp sgt <16 x i8> %a, zeroinitializer
1741 %1 = call <16 x i8> @llvm.masked.load.v16i8.p0v16i8(<16 x i8>* %0, i32 4, <16 x i1> %c, <16 x i8> undef)
1742 %2 = bitcast i8* %y to <16 x i8>*
1743 store <16 x i8> %1, <16 x i8>* %2, align 4
1747 define arm_aapcs_vfpcc i8* @masked_v16i8_postinc(i8* %x, i8* %y, <16 x i8> %a) {
1748 ; CHECK-LE-LABEL: masked_v16i8_postinc:
1749 ; CHECK-LE: @ %bb.0: @ %entry
1750 ; CHECK-LE-NEXT: .save {r4, r6, r7, lr}
1751 ; CHECK-LE-NEXT: push {r4, r6, r7, lr}
1752 ; CHECK-LE-NEXT: .setfp r7, sp, #8
1753 ; CHECK-LE-NEXT: add r7, sp, #8
1754 ; CHECK-LE-NEXT: .pad #16
1755 ; CHECK-LE-NEXT: sub sp, #16
1756 ; CHECK-LE-NEXT: mov r4, sp
1757 ; CHECK-LE-NEXT: bfc r4, #0, #4
1758 ; CHECK-LE-NEXT: mov sp, r4
1759 ; CHECK-LE-NEXT: vcmp.s8 gt, q0, zr
1760 ; CHECK-LE-NEXT: mov r2, sp
1761 ; CHECK-LE-NEXT: vstr p0, [r2]
1762 ; CHECK-LE-NEXT: @ implicit-def: $q0
1763 ; CHECK-LE-NEXT: sub.w r4, r7, #8
1764 ; CHECK-LE-NEXT: ldrh.w r3, [sp]
1765 ; CHECK-LE-NEXT: add.w r12, r0, #4
1766 ; CHECK-LE-NEXT: lsls r2, r3, #31
1767 ; CHECK-LE-NEXT: itt ne
1768 ; CHECK-LE-NEXT: ldrbne r2, [r0]
1769 ; CHECK-LE-NEXT: vmovne.8 q0[0], r2
1770 ; CHECK-LE-NEXT: lsls r2, r3, #30
1771 ; CHECK-LE-NEXT: itt mi
1772 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #1]
1773 ; CHECK-LE-NEXT: vmovmi.8 q0[1], r2
1774 ; CHECK-LE-NEXT: lsls r2, r3, #29
1775 ; CHECK-LE-NEXT: itt mi
1776 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #2]
1777 ; CHECK-LE-NEXT: vmovmi.8 q0[2], r2
1778 ; CHECK-LE-NEXT: lsls r2, r3, #28
1779 ; CHECK-LE-NEXT: itt mi
1780 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #3]
1781 ; CHECK-LE-NEXT: vmovmi.8 q0[3], r2
1782 ; CHECK-LE-NEXT: lsls r2, r3, #27
1783 ; CHECK-LE-NEXT: itt mi
1784 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #4]
1785 ; CHECK-LE-NEXT: vmovmi.8 q0[4], r2
1786 ; CHECK-LE-NEXT: lsls r2, r3, #26
1787 ; CHECK-LE-NEXT: itt mi
1788 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #5]
1789 ; CHECK-LE-NEXT: vmovmi.8 q0[5], r2
1790 ; CHECK-LE-NEXT: lsls r2, r3, #25
1791 ; CHECK-LE-NEXT: itt mi
1792 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #6]
1793 ; CHECK-LE-NEXT: vmovmi.8 q0[6], r2
1794 ; CHECK-LE-NEXT: lsls r2, r3, #24
1795 ; CHECK-LE-NEXT: itt mi
1796 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #7]
1797 ; CHECK-LE-NEXT: vmovmi.8 q0[7], r2
1798 ; CHECK-LE-NEXT: lsls r2, r3, #23
1799 ; CHECK-LE-NEXT: itt mi
1800 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #8]
1801 ; CHECK-LE-NEXT: vmovmi.8 q0[8], r2
1802 ; CHECK-LE-NEXT: lsls r2, r3, #22
1803 ; CHECK-LE-NEXT: itt mi
1804 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #9]
1805 ; CHECK-LE-NEXT: vmovmi.8 q0[9], r2
1806 ; CHECK-LE-NEXT: lsls r2, r3, #21
1807 ; CHECK-LE-NEXT: itt mi
1808 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #10]
1809 ; CHECK-LE-NEXT: vmovmi.8 q0[10], r2
1810 ; CHECK-LE-NEXT: lsls r2, r3, #20
1811 ; CHECK-LE-NEXT: itt mi
1812 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #11]
1813 ; CHECK-LE-NEXT: vmovmi.8 q0[11], r2
1814 ; CHECK-LE-NEXT: lsls r2, r3, #19
1815 ; CHECK-LE-NEXT: itt mi
1816 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #12]
1817 ; CHECK-LE-NEXT: vmovmi.8 q0[12], r2
1818 ; CHECK-LE-NEXT: lsls r2, r3, #18
1819 ; CHECK-LE-NEXT: itt mi
1820 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #13]
1821 ; CHECK-LE-NEXT: vmovmi.8 q0[13], r2
1822 ; CHECK-LE-NEXT: lsls r2, r3, #17
1823 ; CHECK-LE-NEXT: itt mi
1824 ; CHECK-LE-NEXT: ldrbmi r2, [r0, #14]
1825 ; CHECK-LE-NEXT: vmovmi.8 q0[14], r2
1826 ; CHECK-LE-NEXT: lsls r2, r3, #16
1827 ; CHECK-LE-NEXT: itt mi
1828 ; CHECK-LE-NEXT: ldrbmi r0, [r0, #15]
1829 ; CHECK-LE-NEXT: vmovmi.8 q0[15], r0
1830 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
1831 ; CHECK-LE-NEXT: mov r0, r12
1832 ; CHECK-LE-NEXT: mov sp, r4
1833 ; CHECK-LE-NEXT: pop {r4, r6, r7, pc}
1835 ; CHECK-BE-LABEL: masked_v16i8_postinc:
1836 ; CHECK-BE: @ %bb.0: @ %entry
1837 ; CHECK-BE-NEXT: .save {r4, r6, r7, lr}
1838 ; CHECK-BE-NEXT: push {r4, r6, r7, lr}
1839 ; CHECK-BE-NEXT: .setfp r7, sp, #8
1840 ; CHECK-BE-NEXT: add r7, sp, #8
1841 ; CHECK-BE-NEXT: .pad #16
1842 ; CHECK-BE-NEXT: sub sp, #16
1843 ; CHECK-BE-NEXT: mov r4, sp
1844 ; CHECK-BE-NEXT: bfc r4, #0, #4
1845 ; CHECK-BE-NEXT: mov sp, r4
1846 ; CHECK-BE-NEXT: vrev64.8 q1, q0
1847 ; CHECK-BE-NEXT: mov r2, sp
1848 ; CHECK-BE-NEXT: vcmp.s8 gt, q1, zr
1849 ; CHECK-BE-NEXT: @ implicit-def: $q0
1850 ; CHECK-BE-NEXT: sub.w r4, r7, #8
1851 ; CHECK-BE-NEXT: vstr p0, [r2]
1852 ; CHECK-BE-NEXT: add.w r12, r0, #4
1853 ; CHECK-BE-NEXT: ldrh.w r3, [sp]
1854 ; CHECK-BE-NEXT: lsls r2, r3, #31
1855 ; CHECK-BE-NEXT: itt ne
1856 ; CHECK-BE-NEXT: ldrbne r2, [r0]
1857 ; CHECK-BE-NEXT: vmovne.8 q0[0], r2
1858 ; CHECK-BE-NEXT: lsls r2, r3, #30
1859 ; CHECK-BE-NEXT: itt mi
1860 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #1]
1861 ; CHECK-BE-NEXT: vmovmi.8 q0[1], r2
1862 ; CHECK-BE-NEXT: lsls r2, r3, #29
1863 ; CHECK-BE-NEXT: itt mi
1864 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #2]
1865 ; CHECK-BE-NEXT: vmovmi.8 q0[2], r2
1866 ; CHECK-BE-NEXT: lsls r2, r3, #28
1867 ; CHECK-BE-NEXT: itt mi
1868 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #3]
1869 ; CHECK-BE-NEXT: vmovmi.8 q0[3], r2
1870 ; CHECK-BE-NEXT: lsls r2, r3, #27
1871 ; CHECK-BE-NEXT: itt mi
1872 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #4]
1873 ; CHECK-BE-NEXT: vmovmi.8 q0[4], r2
1874 ; CHECK-BE-NEXT: lsls r2, r3, #26
1875 ; CHECK-BE-NEXT: itt mi
1876 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #5]
1877 ; CHECK-BE-NEXT: vmovmi.8 q0[5], r2
1878 ; CHECK-BE-NEXT: lsls r2, r3, #25
1879 ; CHECK-BE-NEXT: itt mi
1880 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #6]
1881 ; CHECK-BE-NEXT: vmovmi.8 q0[6], r2
1882 ; CHECK-BE-NEXT: lsls r2, r3, #24
1883 ; CHECK-BE-NEXT: itt mi
1884 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #7]
1885 ; CHECK-BE-NEXT: vmovmi.8 q0[7], r2
1886 ; CHECK-BE-NEXT: lsls r2, r3, #23
1887 ; CHECK-BE-NEXT: itt mi
1888 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #8]
1889 ; CHECK-BE-NEXT: vmovmi.8 q0[8], r2
1890 ; CHECK-BE-NEXT: lsls r2, r3, #22
1891 ; CHECK-BE-NEXT: itt mi
1892 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #9]
1893 ; CHECK-BE-NEXT: vmovmi.8 q0[9], r2
1894 ; CHECK-BE-NEXT: lsls r2, r3, #21
1895 ; CHECK-BE-NEXT: itt mi
1896 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #10]
1897 ; CHECK-BE-NEXT: vmovmi.8 q0[10], r2
1898 ; CHECK-BE-NEXT: lsls r2, r3, #20
1899 ; CHECK-BE-NEXT: itt mi
1900 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #11]
1901 ; CHECK-BE-NEXT: vmovmi.8 q0[11], r2
1902 ; CHECK-BE-NEXT: lsls r2, r3, #19
1903 ; CHECK-BE-NEXT: itt mi
1904 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #12]
1905 ; CHECK-BE-NEXT: vmovmi.8 q0[12], r2
1906 ; CHECK-BE-NEXT: lsls r2, r3, #18
1907 ; CHECK-BE-NEXT: itt mi
1908 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #13]
1909 ; CHECK-BE-NEXT: vmovmi.8 q0[13], r2
1910 ; CHECK-BE-NEXT: lsls r2, r3, #17
1911 ; CHECK-BE-NEXT: itt mi
1912 ; CHECK-BE-NEXT: ldrbmi r2, [r0, #14]
1913 ; CHECK-BE-NEXT: vmovmi.8 q0[14], r2
1914 ; CHECK-BE-NEXT: lsls r2, r3, #16
1915 ; CHECK-BE-NEXT: itt mi
1916 ; CHECK-BE-NEXT: ldrbmi r0, [r0, #15]
1917 ; CHECK-BE-NEXT: vmovmi.8 q0[15], r0
1918 ; CHECK-BE-NEXT: vstrb.8 q0, [r1]
1919 ; CHECK-BE-NEXT: mov r0, r12
1920 ; CHECK-BE-NEXT: mov sp, r4
1921 ; CHECK-BE-NEXT: pop {r4, r6, r7, pc}
1923 %z = getelementptr inbounds i8, i8* %x, i32 4
1924 %0 = bitcast i8* %x to <16 x i8>*
1925 %c = icmp sgt <16 x i8> %a, zeroinitializer
1926 %1 = call <16 x i8> @llvm.masked.load.v16i8.p0v16i8(<16 x i8>* %0, i32 4, <16 x i1> %c, <16 x i8> undef)
1927 %2 = bitcast i8* %y to <16 x i8>*
1928 store <16 x i8> %1, <16 x i8>* %2, align 4
1933 define arm_aapcs_vfpcc <4 x float> @masked_v4f32_align4_zero(<4 x float> *%dest, <4 x i32> %a) {
1934 ; CHECK-LE-LABEL: masked_v4f32_align4_zero:
1935 ; CHECK-LE: @ %bb.0: @ %entry
1936 ; CHECK-LE-NEXT: .pad #4
1937 ; CHECK-LE-NEXT: sub sp, #4
1938 ; CHECK-LE-NEXT: mov r1, sp
1939 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
1940 ; CHECK-LE-NEXT: vstr p0, [r1]
1941 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
1942 ; CHECK-LE-NEXT: lsls r2, r1, #31
1943 ; CHECK-LE-NEXT: beq .LBB17_2
1944 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
1945 ; CHECK-LE-NEXT: vldr s0, .LCPI17_0
1946 ; CHECK-LE-NEXT: vldr s4, [r0]
1947 ; CHECK-LE-NEXT: vmov r2, s0
1948 ; CHECK-LE-NEXT: vdup.32 q0, r2
1949 ; CHECK-LE-NEXT: vmov.f32 s0, s4
1950 ; CHECK-LE-NEXT: b .LBB17_3
1951 ; CHECK-LE-NEXT: .LBB17_2:
1952 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
1953 ; CHECK-LE-NEXT: .LBB17_3: @ %else
1954 ; CHECK-LE-NEXT: lsls r2, r1, #30
1955 ; CHECK-LE-NEXT: it mi
1956 ; CHECK-LE-NEXT: vldrmi s1, [r0, #4]
1957 ; CHECK-LE-NEXT: lsls r2, r1, #29
1958 ; CHECK-LE-NEXT: it mi
1959 ; CHECK-LE-NEXT: vldrmi s2, [r0, #8]
1960 ; CHECK-LE-NEXT: lsls r1, r1, #28
1961 ; CHECK-LE-NEXT: it mi
1962 ; CHECK-LE-NEXT: vldrmi s3, [r0, #12]
1963 ; CHECK-LE-NEXT: add sp, #4
1964 ; CHECK-LE-NEXT: bx lr
1965 ; CHECK-LE-NEXT: .p2align 2
1966 ; CHECK-LE-NEXT: @ %bb.4:
1967 ; CHECK-LE-NEXT: .LCPI17_0:
1968 ; CHECK-LE-NEXT: .long 0 @ float 0
1970 ; CHECK-BE-LABEL: masked_v4f32_align4_zero:
1971 ; CHECK-BE: @ %bb.0: @ %entry
1972 ; CHECK-BE-NEXT: .pad #4
1973 ; CHECK-BE-NEXT: sub sp, #4
1974 ; CHECK-BE-NEXT: vrev64.32 q1, q0
1975 ; CHECK-BE-NEXT: mov r1, sp
1976 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
1977 ; CHECK-BE-NEXT: vstr p0, [r1]
1978 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
1979 ; CHECK-BE-NEXT: lsls r2, r1, #31
1980 ; CHECK-BE-NEXT: beq .LBB17_2
1981 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
1982 ; CHECK-BE-NEXT: vldr s0, .LCPI17_0
1983 ; CHECK-BE-NEXT: vldr s2, [r0]
1984 ; CHECK-BE-NEXT: vmov r2, s0
1985 ; CHECK-BE-NEXT: vdup.32 q1, r2
1986 ; CHECK-BE-NEXT: vmov.f32 s4, s2
1987 ; CHECK-BE-NEXT: b .LBB17_3
1988 ; CHECK-BE-NEXT: .LBB17_2:
1989 ; CHECK-BE-NEXT: vmov.i32 q1, #0x0
1990 ; CHECK-BE-NEXT: .LBB17_3: @ %else
1991 ; CHECK-BE-NEXT: lsls r2, r1, #30
1992 ; CHECK-BE-NEXT: it mi
1993 ; CHECK-BE-NEXT: vldrmi s5, [r0, #4]
1994 ; CHECK-BE-NEXT: lsls r2, r1, #29
1995 ; CHECK-BE-NEXT: it mi
1996 ; CHECK-BE-NEXT: vldrmi s6, [r0, #8]
1997 ; CHECK-BE-NEXT: lsls r1, r1, #28
1998 ; CHECK-BE-NEXT: it mi
1999 ; CHECK-BE-NEXT: vldrmi s7, [r0, #12]
2000 ; CHECK-BE-NEXT: vrev64.32 q0, q1
2001 ; CHECK-BE-NEXT: add sp, #4
2002 ; CHECK-BE-NEXT: bx lr
2003 ; CHECK-BE-NEXT: .p2align 2
2004 ; CHECK-BE-NEXT: @ %bb.4:
2005 ; CHECK-BE-NEXT: .LCPI17_0:
2006 ; CHECK-BE-NEXT: .long 0 @ float 0
2008 %c = icmp sgt <4 x i32> %a, zeroinitializer
2009 %l = call <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>* %dest, i32 4, <4 x i1> %c, <4 x float> zeroinitializer)
2013 define arm_aapcs_vfpcc <4 x float> @masked_v4f32_align4_undef(<4 x float> *%dest, <4 x i32> %a) {
2014 ; CHECK-LE-LABEL: masked_v4f32_align4_undef:
2015 ; CHECK-LE: @ %bb.0: @ %entry
2016 ; CHECK-LE-NEXT: .pad #4
2017 ; CHECK-LE-NEXT: sub sp, #4
2018 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
2019 ; CHECK-LE-NEXT: mov r1, sp
2020 ; CHECK-LE-NEXT: vstr p0, [r1]
2021 ; CHECK-LE-NEXT: @ implicit-def: $q0
2022 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
2023 ; CHECK-LE-NEXT: lsls r2, r1, #31
2024 ; CHECK-LE-NEXT: it ne
2025 ; CHECK-LE-NEXT: vldrne s0, [r0]
2026 ; CHECK-LE-NEXT: lsls r2, r1, #30
2027 ; CHECK-LE-NEXT: it mi
2028 ; CHECK-LE-NEXT: vldrmi s1, [r0, #4]
2029 ; CHECK-LE-NEXT: lsls r2, r1, #29
2030 ; CHECK-LE-NEXT: it mi
2031 ; CHECK-LE-NEXT: vldrmi s2, [r0, #8]
2032 ; CHECK-LE-NEXT: lsls r1, r1, #28
2033 ; CHECK-LE-NEXT: it mi
2034 ; CHECK-LE-NEXT: vldrmi s3, [r0, #12]
2035 ; CHECK-LE-NEXT: add sp, #4
2036 ; CHECK-LE-NEXT: bx lr
2038 ; CHECK-BE-LABEL: masked_v4f32_align4_undef:
2039 ; CHECK-BE: @ %bb.0: @ %entry
2040 ; CHECK-BE-NEXT: .pad #4
2041 ; CHECK-BE-NEXT: sub sp, #4
2042 ; CHECK-BE-NEXT: vrev64.32 q1, q0
2043 ; CHECK-BE-NEXT: mov r1, sp
2044 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
2045 ; CHECK-BE-NEXT: @ implicit-def: $q1
2046 ; CHECK-BE-NEXT: vstr p0, [r1]
2047 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
2048 ; CHECK-BE-NEXT: lsls r2, r1, #31
2049 ; CHECK-BE-NEXT: it ne
2050 ; CHECK-BE-NEXT: vldrne s4, [r0]
2051 ; CHECK-BE-NEXT: lsls r2, r1, #30
2052 ; CHECK-BE-NEXT: it mi
2053 ; CHECK-BE-NEXT: vldrmi s5, [r0, #4]
2054 ; CHECK-BE-NEXT: lsls r2, r1, #29
2055 ; CHECK-BE-NEXT: it mi
2056 ; CHECK-BE-NEXT: vldrmi s6, [r0, #8]
2057 ; CHECK-BE-NEXT: lsls r1, r1, #28
2058 ; CHECK-BE-NEXT: it mi
2059 ; CHECK-BE-NEXT: vldrmi s7, [r0, #12]
2060 ; CHECK-BE-NEXT: vrev64.32 q0, q1
2061 ; CHECK-BE-NEXT: add sp, #4
2062 ; CHECK-BE-NEXT: bx lr
2064 %c = icmp sgt <4 x i32> %a, zeroinitializer
2065 %l = call <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>* %dest, i32 4, <4 x i1> %c, <4 x float> undef)
2069 define arm_aapcs_vfpcc <4 x float> @masked_v4f32_align1_undef(<4 x float> *%dest, <4 x i32> %a) {
2070 ; CHECK-LE-LABEL: masked_v4f32_align1_undef:
2071 ; CHECK-LE: @ %bb.0: @ %entry
2072 ; CHECK-LE-NEXT: .pad #4
2073 ; CHECK-LE-NEXT: sub sp, #4
2074 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
2075 ; CHECK-LE-NEXT: mov r1, sp
2076 ; CHECK-LE-NEXT: vstr p0, [r1]
2077 ; CHECK-LE-NEXT: @ implicit-def: $q0
2078 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
2079 ; CHECK-LE-NEXT: lsls r2, r1, #31
2080 ; CHECK-LE-NEXT: itt ne
2081 ; CHECK-LE-NEXT: ldrne r2, [r0]
2082 ; CHECK-LE-NEXT: vmovne s0, r2
2083 ; CHECK-LE-NEXT: lsls r2, r1, #30
2084 ; CHECK-LE-NEXT: itt mi
2085 ; CHECK-LE-NEXT: ldrmi r2, [r0, #4]
2086 ; CHECK-LE-NEXT: vmovmi s1, r2
2087 ; CHECK-LE-NEXT: lsls r2, r1, #29
2088 ; CHECK-LE-NEXT: itt mi
2089 ; CHECK-LE-NEXT: ldrmi r2, [r0, #8]
2090 ; CHECK-LE-NEXT: vmovmi s2, r2
2091 ; CHECK-LE-NEXT: lsls r1, r1, #28
2092 ; CHECK-LE-NEXT: itt mi
2093 ; CHECK-LE-NEXT: ldrmi r0, [r0, #12]
2094 ; CHECK-LE-NEXT: vmovmi s3, r0
2095 ; CHECK-LE-NEXT: add sp, #4
2096 ; CHECK-LE-NEXT: bx lr
2098 ; CHECK-BE-LABEL: masked_v4f32_align1_undef:
2099 ; CHECK-BE: @ %bb.0: @ %entry
2100 ; CHECK-BE-NEXT: .pad #4
2101 ; CHECK-BE-NEXT: sub sp, #4
2102 ; CHECK-BE-NEXT: vrev64.32 q1, q0
2103 ; CHECK-BE-NEXT: mov r1, sp
2104 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
2105 ; CHECK-BE-NEXT: @ implicit-def: $q1
2106 ; CHECK-BE-NEXT: vstr p0, [r1]
2107 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
2108 ; CHECK-BE-NEXT: lsls r2, r1, #31
2109 ; CHECK-BE-NEXT: itt ne
2110 ; CHECK-BE-NEXT: ldrne r2, [r0]
2111 ; CHECK-BE-NEXT: vmovne s4, r2
2112 ; CHECK-BE-NEXT: lsls r2, r1, #30
2113 ; CHECK-BE-NEXT: itt mi
2114 ; CHECK-BE-NEXT: ldrmi r2, [r0, #4]
2115 ; CHECK-BE-NEXT: vmovmi s5, r2
2116 ; CHECK-BE-NEXT: lsls r2, r1, #29
2117 ; CHECK-BE-NEXT: itt mi
2118 ; CHECK-BE-NEXT: ldrmi r2, [r0, #8]
2119 ; CHECK-BE-NEXT: vmovmi s6, r2
2120 ; CHECK-BE-NEXT: lsls r1, r1, #28
2121 ; CHECK-BE-NEXT: itt mi
2122 ; CHECK-BE-NEXT: ldrmi r0, [r0, #12]
2123 ; CHECK-BE-NEXT: vmovmi s7, r0
2124 ; CHECK-BE-NEXT: vrev64.32 q0, q1
2125 ; CHECK-BE-NEXT: add sp, #4
2126 ; CHECK-BE-NEXT: bx lr
2128 %c = icmp sgt <4 x i32> %a, zeroinitializer
2129 %l = call <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>* %dest, i32 1, <4 x i1> %c, <4 x float> undef)
2133 define arm_aapcs_vfpcc <4 x float> @masked_v4f32_align4_other(<4 x float> *%dest, <4 x i32> %a, <4 x float> %b) {
2134 ; CHECK-LE-LABEL: masked_v4f32_align4_other:
2135 ; CHECK-LE: @ %bb.0: @ %entry
2136 ; CHECK-LE-NEXT: .pad #4
2137 ; CHECK-LE-NEXT: sub sp, #4
2138 ; CHECK-LE-NEXT: mov r1, sp
2139 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
2140 ; CHECK-LE-NEXT: vstr p0, [r1]
2141 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
2142 ; CHECK-LE-NEXT: lsls r2, r1, #31
2143 ; CHECK-LE-NEXT: it ne
2144 ; CHECK-LE-NEXT: vldrne s4, [r0]
2145 ; CHECK-LE-NEXT: lsls r2, r1, #30
2146 ; CHECK-LE-NEXT: it mi
2147 ; CHECK-LE-NEXT: vldrmi s5, [r0, #4]
2148 ; CHECK-LE-NEXT: lsls r2, r1, #29
2149 ; CHECK-LE-NEXT: it mi
2150 ; CHECK-LE-NEXT: vldrmi s6, [r0, #8]
2151 ; CHECK-LE-NEXT: lsls r1, r1, #28
2152 ; CHECK-LE-NEXT: it mi
2153 ; CHECK-LE-NEXT: vldrmi s7, [r0, #12]
2154 ; CHECK-LE-NEXT: vmov q0, q1
2155 ; CHECK-LE-NEXT: add sp, #4
2156 ; CHECK-LE-NEXT: bx lr
2158 ; CHECK-BE-LABEL: masked_v4f32_align4_other:
2159 ; CHECK-BE: @ %bb.0: @ %entry
2160 ; CHECK-BE-NEXT: .pad #4
2161 ; CHECK-BE-NEXT: sub sp, #4
2162 ; CHECK-BE-NEXT: vrev64.32 q2, q0
2163 ; CHECK-BE-NEXT: mov r1, sp
2164 ; CHECK-BE-NEXT: vcmp.s32 gt, q2, zr
2165 ; CHECK-BE-NEXT: vrev64.32 q2, q1
2166 ; CHECK-BE-NEXT: vstr p0, [r1]
2167 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
2168 ; CHECK-BE-NEXT: lsls r2, r1, #31
2169 ; CHECK-BE-NEXT: it ne
2170 ; CHECK-BE-NEXT: vldrne s8, [r0]
2171 ; CHECK-BE-NEXT: lsls r2, r1, #30
2172 ; CHECK-BE-NEXT: it mi
2173 ; CHECK-BE-NEXT: vldrmi s9, [r0, #4]
2174 ; CHECK-BE-NEXT: lsls r2, r1, #29
2175 ; CHECK-BE-NEXT: it mi
2176 ; CHECK-BE-NEXT: vldrmi s10, [r0, #8]
2177 ; CHECK-BE-NEXT: lsls r1, r1, #28
2178 ; CHECK-BE-NEXT: it mi
2179 ; CHECK-BE-NEXT: vldrmi s11, [r0, #12]
2180 ; CHECK-BE-NEXT: vrev64.32 q0, q2
2181 ; CHECK-BE-NEXT: add sp, #4
2182 ; CHECK-BE-NEXT: bx lr
2184 %c = icmp sgt <4 x i32> %a, zeroinitializer
2185 %l = call <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>* %dest, i32 4, <4 x i1> %c, <4 x float> %b)
2189 define arm_aapcs_vfpcc i8* @masked_v4f32_preinc(i8* %x, i8* %y, <4 x i32> %a) {
2190 ; CHECK-LE-LABEL: masked_v4f32_preinc:
2191 ; CHECK-LE: @ %bb.0: @ %entry
2192 ; CHECK-LE-NEXT: .pad #4
2193 ; CHECK-LE-NEXT: sub sp, #4
2194 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
2195 ; CHECK-LE-NEXT: mov r2, sp
2196 ; CHECK-LE-NEXT: vstr p0, [r2]
2197 ; CHECK-LE-NEXT: @ implicit-def: $q0
2198 ; CHECK-LE-NEXT: adds r0, #4
2199 ; CHECK-LE-NEXT: ldrb.w r2, [sp]
2200 ; CHECK-LE-NEXT: lsls r3, r2, #31
2201 ; CHECK-LE-NEXT: it ne
2202 ; CHECK-LE-NEXT: vldrne s0, [r0]
2203 ; CHECK-LE-NEXT: lsls r3, r2, #30
2204 ; CHECK-LE-NEXT: it mi
2205 ; CHECK-LE-NEXT: vldrmi s1, [r0, #4]
2206 ; CHECK-LE-NEXT: lsls r3, r2, #29
2207 ; CHECK-LE-NEXT: it mi
2208 ; CHECK-LE-NEXT: vldrmi s2, [r0, #8]
2209 ; CHECK-LE-NEXT: lsls r2, r2, #28
2210 ; CHECK-LE-NEXT: it mi
2211 ; CHECK-LE-NEXT: vldrmi s3, [r0, #12]
2212 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
2213 ; CHECK-LE-NEXT: add sp, #4
2214 ; CHECK-LE-NEXT: bx lr
2216 ; CHECK-BE-LABEL: masked_v4f32_preinc:
2217 ; CHECK-BE: @ %bb.0: @ %entry
2218 ; CHECK-BE-NEXT: .pad #4
2219 ; CHECK-BE-NEXT: sub sp, #4
2220 ; CHECK-BE-NEXT: vrev64.32 q1, q0
2221 ; CHECK-BE-NEXT: mov r2, sp
2222 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
2223 ; CHECK-BE-NEXT: @ implicit-def: $q0
2224 ; CHECK-BE-NEXT: adds r0, #4
2225 ; CHECK-BE-NEXT: vstr p0, [r2]
2226 ; CHECK-BE-NEXT: ldrb.w r2, [sp]
2227 ; CHECK-BE-NEXT: lsls r3, r2, #31
2228 ; CHECK-BE-NEXT: it ne
2229 ; CHECK-BE-NEXT: vldrne s0, [r0]
2230 ; CHECK-BE-NEXT: lsls r3, r2, #30
2231 ; CHECK-BE-NEXT: it mi
2232 ; CHECK-BE-NEXT: vldrmi s1, [r0, #4]
2233 ; CHECK-BE-NEXT: lsls r3, r2, #29
2234 ; CHECK-BE-NEXT: it mi
2235 ; CHECK-BE-NEXT: vldrmi s2, [r0, #8]
2236 ; CHECK-BE-NEXT: lsls r2, r2, #28
2237 ; CHECK-BE-NEXT: it mi
2238 ; CHECK-BE-NEXT: vldrmi s3, [r0, #12]
2239 ; CHECK-BE-NEXT: vstrw.32 q0, [r1]
2240 ; CHECK-BE-NEXT: add sp, #4
2241 ; CHECK-BE-NEXT: bx lr
2243 %z = getelementptr inbounds i8, i8* %x, i32 4
2244 %0 = bitcast i8* %z to <4 x float>*
2245 %c = icmp sgt <4 x i32> %a, zeroinitializer
2246 %1 = call <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>* %0, i32 4, <4 x i1> %c, <4 x float> undef)
2247 %2 = bitcast i8* %y to <4 x float>*
2248 store <4 x float> %1, <4 x float>* %2, align 4
2252 define arm_aapcs_vfpcc i8* @masked_v4f32_postinc(i8* %x, i8* %y, <4 x i32> %a) {
2253 ; CHECK-LE-LABEL: masked_v4f32_postinc:
2254 ; CHECK-LE: @ %bb.0: @ %entry
2255 ; CHECK-LE-NEXT: .pad #4
2256 ; CHECK-LE-NEXT: sub sp, #4
2257 ; CHECK-LE-NEXT: vcmp.s32 gt, q0, zr
2258 ; CHECK-LE-NEXT: mov r2, sp
2259 ; CHECK-LE-NEXT: vstr p0, [r2]
2260 ; CHECK-LE-NEXT: @ implicit-def: $q0
2261 ; CHECK-LE-NEXT: add.w r12, r0, #4
2262 ; CHECK-LE-NEXT: ldrb.w r3, [sp]
2263 ; CHECK-LE-NEXT: lsls r2, r3, #31
2264 ; CHECK-LE-NEXT: it ne
2265 ; CHECK-LE-NEXT: vldrne s0, [r0]
2266 ; CHECK-LE-NEXT: lsls r2, r3, #30
2267 ; CHECK-LE-NEXT: it mi
2268 ; CHECK-LE-NEXT: vldrmi s1, [r0, #4]
2269 ; CHECK-LE-NEXT: lsls r2, r3, #29
2270 ; CHECK-LE-NEXT: it mi
2271 ; CHECK-LE-NEXT: vldrmi s2, [r0, #8]
2272 ; CHECK-LE-NEXT: lsls r2, r3, #28
2273 ; CHECK-LE-NEXT: it mi
2274 ; CHECK-LE-NEXT: vldrmi s3, [r0, #12]
2275 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
2276 ; CHECK-LE-NEXT: mov r0, r12
2277 ; CHECK-LE-NEXT: add sp, #4
2278 ; CHECK-LE-NEXT: bx lr
2280 ; CHECK-BE-LABEL: masked_v4f32_postinc:
2281 ; CHECK-BE: @ %bb.0: @ %entry
2282 ; CHECK-BE-NEXT: .pad #4
2283 ; CHECK-BE-NEXT: sub sp, #4
2284 ; CHECK-BE-NEXT: vrev64.32 q1, q0
2285 ; CHECK-BE-NEXT: mov r2, sp
2286 ; CHECK-BE-NEXT: vcmp.s32 gt, q1, zr
2287 ; CHECK-BE-NEXT: @ implicit-def: $q0
2288 ; CHECK-BE-NEXT: add.w r12, r0, #4
2289 ; CHECK-BE-NEXT: vstr p0, [r2]
2290 ; CHECK-BE-NEXT: ldrb.w r3, [sp]
2291 ; CHECK-BE-NEXT: lsls r2, r3, #31
2292 ; CHECK-BE-NEXT: it ne
2293 ; CHECK-BE-NEXT: vldrne s0, [r0]
2294 ; CHECK-BE-NEXT: lsls r2, r3, #30
2295 ; CHECK-BE-NEXT: it mi
2296 ; CHECK-BE-NEXT: vldrmi s1, [r0, #4]
2297 ; CHECK-BE-NEXT: lsls r2, r3, #29
2298 ; CHECK-BE-NEXT: it mi
2299 ; CHECK-BE-NEXT: vldrmi s2, [r0, #8]
2300 ; CHECK-BE-NEXT: lsls r2, r3, #28
2301 ; CHECK-BE-NEXT: it mi
2302 ; CHECK-BE-NEXT: vldrmi s3, [r0, #12]
2303 ; CHECK-BE-NEXT: vstrw.32 q0, [r1]
2304 ; CHECK-BE-NEXT: mov r0, r12
2305 ; CHECK-BE-NEXT: add sp, #4
2306 ; CHECK-BE-NEXT: bx lr
2308 %z = getelementptr inbounds i8, i8* %x, i32 4
2309 %0 = bitcast i8* %x to <4 x float>*
2310 %c = icmp sgt <4 x i32> %a, zeroinitializer
2311 %1 = call <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>* %0, i32 4, <4 x i1> %c, <4 x float> undef)
2312 %2 = bitcast i8* %y to <4 x float>*
2313 store <4 x float> %1, <4 x float>* %2, align 4
2318 define arm_aapcs_vfpcc <8 x half> @masked_v8f16_align4_zero(<8 x half> *%dest, <8 x i16> %a) {
2319 ; CHECK-LE-LABEL: masked_v8f16_align4_zero:
2320 ; CHECK-LE: @ %bb.0: @ %entry
2321 ; CHECK-LE-NEXT: .pad #8
2322 ; CHECK-LE-NEXT: sub sp, #8
2323 ; CHECK-LE-NEXT: mov r1, sp
2324 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
2325 ; CHECK-LE-NEXT: vstr p0, [r1]
2326 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
2327 ; CHECK-LE-NEXT: lsls r2, r1, #31
2328 ; CHECK-LE-NEXT: beq .LBB23_2
2329 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
2330 ; CHECK-LE-NEXT: vldr.16 s0, .LCPI23_0
2331 ; CHECK-LE-NEXT: vmov r2, s0
2332 ; CHECK-LE-NEXT: vldr.16 s0, [r0]
2333 ; CHECK-LE-NEXT: vmov r3, s0
2334 ; CHECK-LE-NEXT: vdup.16 q0, r2
2335 ; CHECK-LE-NEXT: vmov.16 q0[0], r3
2336 ; CHECK-LE-NEXT: lsls r2, r1, #30
2337 ; CHECK-LE-NEXT: bmi .LBB23_3
2338 ; CHECK-LE-NEXT: b .LBB23_4
2339 ; CHECK-LE-NEXT: .LBB23_2:
2340 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
2341 ; CHECK-LE-NEXT: lsls r2, r1, #30
2342 ; CHECK-LE-NEXT: bpl .LBB23_4
2343 ; CHECK-LE-NEXT: .LBB23_3: @ %cond.load1
2344 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #2]
2345 ; CHECK-LE-NEXT: vmov r2, s4
2346 ; CHECK-LE-NEXT: vmov.16 q0[1], r2
2347 ; CHECK-LE-NEXT: .LBB23_4: @ %else2
2348 ; CHECK-LE-NEXT: lsls r2, r1, #29
2349 ; CHECK-LE-NEXT: bmi .LBB23_11
2350 ; CHECK-LE-NEXT: @ %bb.5: @ %else5
2351 ; CHECK-LE-NEXT: lsls r2, r1, #28
2352 ; CHECK-LE-NEXT: bmi .LBB23_12
2353 ; CHECK-LE-NEXT: .LBB23_6: @ %else8
2354 ; CHECK-LE-NEXT: lsls r2, r1, #27
2355 ; CHECK-LE-NEXT: bmi .LBB23_13
2356 ; CHECK-LE-NEXT: .LBB23_7: @ %else11
2357 ; CHECK-LE-NEXT: lsls r2, r1, #26
2358 ; CHECK-LE-NEXT: bmi .LBB23_14
2359 ; CHECK-LE-NEXT: .LBB23_8: @ %else14
2360 ; CHECK-LE-NEXT: lsls r2, r1, #25
2361 ; CHECK-LE-NEXT: bmi .LBB23_15
2362 ; CHECK-LE-NEXT: .LBB23_9: @ %else17
2363 ; CHECK-LE-NEXT: lsls r1, r1, #24
2364 ; CHECK-LE-NEXT: bmi .LBB23_16
2365 ; CHECK-LE-NEXT: .LBB23_10: @ %else20
2366 ; CHECK-LE-NEXT: add sp, #8
2367 ; CHECK-LE-NEXT: bx lr
2368 ; CHECK-LE-NEXT: .LBB23_11: @ %cond.load4
2369 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #4]
2370 ; CHECK-LE-NEXT: vmov r2, s4
2371 ; CHECK-LE-NEXT: vmov.16 q0[2], r2
2372 ; CHECK-LE-NEXT: lsls r2, r1, #28
2373 ; CHECK-LE-NEXT: bpl .LBB23_6
2374 ; CHECK-LE-NEXT: .LBB23_12: @ %cond.load7
2375 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #6]
2376 ; CHECK-LE-NEXT: vmov r2, s4
2377 ; CHECK-LE-NEXT: vmov.16 q0[3], r2
2378 ; CHECK-LE-NEXT: lsls r2, r1, #27
2379 ; CHECK-LE-NEXT: bpl .LBB23_7
2380 ; CHECK-LE-NEXT: .LBB23_13: @ %cond.load10
2381 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #8]
2382 ; CHECK-LE-NEXT: vmov r2, s4
2383 ; CHECK-LE-NEXT: vmov.16 q0[4], r2
2384 ; CHECK-LE-NEXT: lsls r2, r1, #26
2385 ; CHECK-LE-NEXT: bpl .LBB23_8
2386 ; CHECK-LE-NEXT: .LBB23_14: @ %cond.load13
2387 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #10]
2388 ; CHECK-LE-NEXT: vmov r2, s4
2389 ; CHECK-LE-NEXT: vmov.16 q0[5], r2
2390 ; CHECK-LE-NEXT: lsls r2, r1, #25
2391 ; CHECK-LE-NEXT: bpl .LBB23_9
2392 ; CHECK-LE-NEXT: .LBB23_15: @ %cond.load16
2393 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #12]
2394 ; CHECK-LE-NEXT: vmov r2, s4
2395 ; CHECK-LE-NEXT: vmov.16 q0[6], r2
2396 ; CHECK-LE-NEXT: lsls r1, r1, #24
2397 ; CHECK-LE-NEXT: bpl .LBB23_10
2398 ; CHECK-LE-NEXT: .LBB23_16: @ %cond.load19
2399 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #14]
2400 ; CHECK-LE-NEXT: vmov r0, s4
2401 ; CHECK-LE-NEXT: vmov.16 q0[7], r0
2402 ; CHECK-LE-NEXT: add sp, #8
2403 ; CHECK-LE-NEXT: bx lr
2404 ; CHECK-LE-NEXT: .p2align 1
2405 ; CHECK-LE-NEXT: @ %bb.17:
2406 ; CHECK-LE-NEXT: .LCPI23_0:
2407 ; CHECK-LE-NEXT: .short 0 @ half 0
2409 ; CHECK-BE-LABEL: masked_v8f16_align4_zero:
2410 ; CHECK-BE: @ %bb.0: @ %entry
2411 ; CHECK-BE-NEXT: .pad #8
2412 ; CHECK-BE-NEXT: sub sp, #8
2413 ; CHECK-BE-NEXT: vrev64.16 q1, q0
2414 ; CHECK-BE-NEXT: mov r1, sp
2415 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
2416 ; CHECK-BE-NEXT: vstr p0, [r1]
2417 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
2418 ; CHECK-BE-NEXT: lsls r2, r1, #31
2419 ; CHECK-BE-NEXT: beq .LBB23_2
2420 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
2421 ; CHECK-BE-NEXT: vldr.16 s0, .LCPI23_0
2422 ; CHECK-BE-NEXT: vmov r2, s0
2423 ; CHECK-BE-NEXT: vldr.16 s0, [r0]
2424 ; CHECK-BE-NEXT: vdup.16 q1, r2
2425 ; CHECK-BE-NEXT: vmov r3, s0
2426 ; CHECK-BE-NEXT: vmov.16 q1[0], r3
2427 ; CHECK-BE-NEXT: lsls r2, r1, #30
2428 ; CHECK-BE-NEXT: bmi .LBB23_3
2429 ; CHECK-BE-NEXT: b .LBB23_4
2430 ; CHECK-BE-NEXT: .LBB23_2:
2431 ; CHECK-BE-NEXT: vmov.i32 q0, #0x0
2432 ; CHECK-BE-NEXT: vrev32.16 q1, q0
2433 ; CHECK-BE-NEXT: lsls r2, r1, #30
2434 ; CHECK-BE-NEXT: bpl .LBB23_4
2435 ; CHECK-BE-NEXT: .LBB23_3: @ %cond.load1
2436 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #2]
2437 ; CHECK-BE-NEXT: vmov r2, s0
2438 ; CHECK-BE-NEXT: vmov.16 q1[1], r2
2439 ; CHECK-BE-NEXT: .LBB23_4: @ %else2
2440 ; CHECK-BE-NEXT: lsls r2, r1, #29
2441 ; CHECK-BE-NEXT: bmi .LBB23_12
2442 ; CHECK-BE-NEXT: @ %bb.5: @ %else5
2443 ; CHECK-BE-NEXT: lsls r2, r1, #28
2444 ; CHECK-BE-NEXT: bmi .LBB23_13
2445 ; CHECK-BE-NEXT: .LBB23_6: @ %else8
2446 ; CHECK-BE-NEXT: lsls r2, r1, #27
2447 ; CHECK-BE-NEXT: bmi .LBB23_14
2448 ; CHECK-BE-NEXT: .LBB23_7: @ %else11
2449 ; CHECK-BE-NEXT: lsls r2, r1, #26
2450 ; CHECK-BE-NEXT: bmi .LBB23_15
2451 ; CHECK-BE-NEXT: .LBB23_8: @ %else14
2452 ; CHECK-BE-NEXT: lsls r2, r1, #25
2453 ; CHECK-BE-NEXT: bmi .LBB23_16
2454 ; CHECK-BE-NEXT: .LBB23_9: @ %else17
2455 ; CHECK-BE-NEXT: lsls r1, r1, #24
2456 ; CHECK-BE-NEXT: bpl .LBB23_11
2457 ; CHECK-BE-NEXT: .LBB23_10: @ %cond.load19
2458 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #14]
2459 ; CHECK-BE-NEXT: vmov r0, s0
2460 ; CHECK-BE-NEXT: vmov.16 q1[7], r0
2461 ; CHECK-BE-NEXT: .LBB23_11: @ %else20
2462 ; CHECK-BE-NEXT: vrev64.16 q0, q1
2463 ; CHECK-BE-NEXT: add sp, #8
2464 ; CHECK-BE-NEXT: bx lr
2465 ; CHECK-BE-NEXT: .LBB23_12: @ %cond.load4
2466 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #4]
2467 ; CHECK-BE-NEXT: vmov r2, s0
2468 ; CHECK-BE-NEXT: vmov.16 q1[2], r2
2469 ; CHECK-BE-NEXT: lsls r2, r1, #28
2470 ; CHECK-BE-NEXT: bpl .LBB23_6
2471 ; CHECK-BE-NEXT: .LBB23_13: @ %cond.load7
2472 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #6]
2473 ; CHECK-BE-NEXT: vmov r2, s0
2474 ; CHECK-BE-NEXT: vmov.16 q1[3], r2
2475 ; CHECK-BE-NEXT: lsls r2, r1, #27
2476 ; CHECK-BE-NEXT: bpl .LBB23_7
2477 ; CHECK-BE-NEXT: .LBB23_14: @ %cond.load10
2478 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #8]
2479 ; CHECK-BE-NEXT: vmov r2, s0
2480 ; CHECK-BE-NEXT: vmov.16 q1[4], r2
2481 ; CHECK-BE-NEXT: lsls r2, r1, #26
2482 ; CHECK-BE-NEXT: bpl .LBB23_8
2483 ; CHECK-BE-NEXT: .LBB23_15: @ %cond.load13
2484 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #10]
2485 ; CHECK-BE-NEXT: vmov r2, s0
2486 ; CHECK-BE-NEXT: vmov.16 q1[5], r2
2487 ; CHECK-BE-NEXT: lsls r2, r1, #25
2488 ; CHECK-BE-NEXT: bpl .LBB23_9
2489 ; CHECK-BE-NEXT: .LBB23_16: @ %cond.load16
2490 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #12]
2491 ; CHECK-BE-NEXT: vmov r2, s0
2492 ; CHECK-BE-NEXT: vmov.16 q1[6], r2
2493 ; CHECK-BE-NEXT: lsls r1, r1, #24
2494 ; CHECK-BE-NEXT: bmi .LBB23_10
2495 ; CHECK-BE-NEXT: b .LBB23_11
2496 ; CHECK-BE-NEXT: .p2align 1
2497 ; CHECK-BE-NEXT: @ %bb.17:
2498 ; CHECK-BE-NEXT: .LCPI23_0:
2499 ; CHECK-BE-NEXT: .short 0 @ half 0
2501 %c = icmp sgt <8 x i16> %a, zeroinitializer
2502 %l = call <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>* %dest, i32 2, <8 x i1> %c, <8 x half> zeroinitializer)
2506 define arm_aapcs_vfpcc <8 x half> @masked_v8f16_align4_undef(<8 x half> *%dest, <8 x i16> %a) {
2507 ; CHECK-LE-LABEL: masked_v8f16_align4_undef:
2508 ; CHECK-LE: @ %bb.0: @ %entry
2509 ; CHECK-LE-NEXT: .pad #8
2510 ; CHECK-LE-NEXT: sub sp, #8
2511 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
2512 ; CHECK-LE-NEXT: mov r1, sp
2513 ; CHECK-LE-NEXT: vstr p0, [r1]
2514 ; CHECK-LE-NEXT: @ implicit-def: $q0
2515 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
2516 ; CHECK-LE-NEXT: lsls r2, r1, #31
2517 ; CHECK-LE-NEXT: bne .LBB24_9
2518 ; CHECK-LE-NEXT: @ %bb.1: @ %else
2519 ; CHECK-LE-NEXT: lsls r2, r1, #30
2520 ; CHECK-LE-NEXT: bmi .LBB24_10
2521 ; CHECK-LE-NEXT: .LBB24_2: @ %else2
2522 ; CHECK-LE-NEXT: lsls r2, r1, #29
2523 ; CHECK-LE-NEXT: bmi .LBB24_11
2524 ; CHECK-LE-NEXT: .LBB24_3: @ %else5
2525 ; CHECK-LE-NEXT: lsls r2, r1, #28
2526 ; CHECK-LE-NEXT: bmi .LBB24_12
2527 ; CHECK-LE-NEXT: .LBB24_4: @ %else8
2528 ; CHECK-LE-NEXT: lsls r2, r1, #27
2529 ; CHECK-LE-NEXT: bmi .LBB24_13
2530 ; CHECK-LE-NEXT: .LBB24_5: @ %else11
2531 ; CHECK-LE-NEXT: lsls r2, r1, #26
2532 ; CHECK-LE-NEXT: bmi .LBB24_14
2533 ; CHECK-LE-NEXT: .LBB24_6: @ %else14
2534 ; CHECK-LE-NEXT: lsls r2, r1, #25
2535 ; CHECK-LE-NEXT: bmi .LBB24_15
2536 ; CHECK-LE-NEXT: .LBB24_7: @ %else17
2537 ; CHECK-LE-NEXT: lsls r1, r1, #24
2538 ; CHECK-LE-NEXT: bmi .LBB24_16
2539 ; CHECK-LE-NEXT: .LBB24_8: @ %else20
2540 ; CHECK-LE-NEXT: add sp, #8
2541 ; CHECK-LE-NEXT: bx lr
2542 ; CHECK-LE-NEXT: .LBB24_9: @ %cond.load
2543 ; CHECK-LE-NEXT: vldr.16 s0, [r0]
2544 ; CHECK-LE-NEXT: lsls r2, r1, #30
2545 ; CHECK-LE-NEXT: bpl .LBB24_2
2546 ; CHECK-LE-NEXT: .LBB24_10: @ %cond.load1
2547 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #2]
2548 ; CHECK-LE-NEXT: vmov r2, s4
2549 ; CHECK-LE-NEXT: vmov.16 q0[1], r2
2550 ; CHECK-LE-NEXT: lsls r2, r1, #29
2551 ; CHECK-LE-NEXT: bpl .LBB24_3
2552 ; CHECK-LE-NEXT: .LBB24_11: @ %cond.load4
2553 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #4]
2554 ; CHECK-LE-NEXT: vmov r2, s4
2555 ; CHECK-LE-NEXT: vmov.16 q0[2], r2
2556 ; CHECK-LE-NEXT: lsls r2, r1, #28
2557 ; CHECK-LE-NEXT: bpl .LBB24_4
2558 ; CHECK-LE-NEXT: .LBB24_12: @ %cond.load7
2559 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #6]
2560 ; CHECK-LE-NEXT: vmov r2, s4
2561 ; CHECK-LE-NEXT: vmov.16 q0[3], r2
2562 ; CHECK-LE-NEXT: lsls r2, r1, #27
2563 ; CHECK-LE-NEXT: bpl .LBB24_5
2564 ; CHECK-LE-NEXT: .LBB24_13: @ %cond.load10
2565 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #8]
2566 ; CHECK-LE-NEXT: vmov r2, s4
2567 ; CHECK-LE-NEXT: vmov.16 q0[4], r2
2568 ; CHECK-LE-NEXT: lsls r2, r1, #26
2569 ; CHECK-LE-NEXT: bpl .LBB24_6
2570 ; CHECK-LE-NEXT: .LBB24_14: @ %cond.load13
2571 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #10]
2572 ; CHECK-LE-NEXT: vmov r2, s4
2573 ; CHECK-LE-NEXT: vmov.16 q0[5], r2
2574 ; CHECK-LE-NEXT: lsls r2, r1, #25
2575 ; CHECK-LE-NEXT: bpl .LBB24_7
2576 ; CHECK-LE-NEXT: .LBB24_15: @ %cond.load16
2577 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #12]
2578 ; CHECK-LE-NEXT: vmov r2, s4
2579 ; CHECK-LE-NEXT: vmov.16 q0[6], r2
2580 ; CHECK-LE-NEXT: lsls r1, r1, #24
2581 ; CHECK-LE-NEXT: bpl .LBB24_8
2582 ; CHECK-LE-NEXT: .LBB24_16: @ %cond.load19
2583 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #14]
2584 ; CHECK-LE-NEXT: vmov r0, s4
2585 ; CHECK-LE-NEXT: vmov.16 q0[7], r0
2586 ; CHECK-LE-NEXT: add sp, #8
2587 ; CHECK-LE-NEXT: bx lr
2589 ; CHECK-BE-LABEL: masked_v8f16_align4_undef:
2590 ; CHECK-BE: @ %bb.0: @ %entry
2591 ; CHECK-BE-NEXT: .pad #8
2592 ; CHECK-BE-NEXT: sub sp, #8
2593 ; CHECK-BE-NEXT: vrev64.16 q1, q0
2594 ; CHECK-BE-NEXT: mov r1, sp
2595 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
2596 ; CHECK-BE-NEXT: @ implicit-def: $q1
2597 ; CHECK-BE-NEXT: vstr p0, [r1]
2598 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
2599 ; CHECK-BE-NEXT: lsls r2, r1, #31
2600 ; CHECK-BE-NEXT: bne .LBB24_10
2601 ; CHECK-BE-NEXT: @ %bb.1: @ %else
2602 ; CHECK-BE-NEXT: lsls r2, r1, #30
2603 ; CHECK-BE-NEXT: bmi .LBB24_11
2604 ; CHECK-BE-NEXT: .LBB24_2: @ %else2
2605 ; CHECK-BE-NEXT: lsls r2, r1, #29
2606 ; CHECK-BE-NEXT: bmi .LBB24_12
2607 ; CHECK-BE-NEXT: .LBB24_3: @ %else5
2608 ; CHECK-BE-NEXT: lsls r2, r1, #28
2609 ; CHECK-BE-NEXT: bmi .LBB24_13
2610 ; CHECK-BE-NEXT: .LBB24_4: @ %else8
2611 ; CHECK-BE-NEXT: lsls r2, r1, #27
2612 ; CHECK-BE-NEXT: bmi .LBB24_14
2613 ; CHECK-BE-NEXT: .LBB24_5: @ %else11
2614 ; CHECK-BE-NEXT: lsls r2, r1, #26
2615 ; CHECK-BE-NEXT: bmi .LBB24_15
2616 ; CHECK-BE-NEXT: .LBB24_6: @ %else14
2617 ; CHECK-BE-NEXT: lsls r2, r1, #25
2618 ; CHECK-BE-NEXT: bmi .LBB24_16
2619 ; CHECK-BE-NEXT: .LBB24_7: @ %else17
2620 ; CHECK-BE-NEXT: lsls r1, r1, #24
2621 ; CHECK-BE-NEXT: bpl .LBB24_9
2622 ; CHECK-BE-NEXT: .LBB24_8: @ %cond.load19
2623 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #14]
2624 ; CHECK-BE-NEXT: vmov r0, s0
2625 ; CHECK-BE-NEXT: vmov.16 q1[7], r0
2626 ; CHECK-BE-NEXT: .LBB24_9: @ %else20
2627 ; CHECK-BE-NEXT: vrev64.16 q0, q1
2628 ; CHECK-BE-NEXT: add sp, #8
2629 ; CHECK-BE-NEXT: bx lr
2630 ; CHECK-BE-NEXT: .LBB24_10: @ %cond.load
2631 ; CHECK-BE-NEXT: vldr.16 s4, [r0]
2632 ; CHECK-BE-NEXT: lsls r2, r1, #30
2633 ; CHECK-BE-NEXT: bpl .LBB24_2
2634 ; CHECK-BE-NEXT: .LBB24_11: @ %cond.load1
2635 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #2]
2636 ; CHECK-BE-NEXT: vmov r2, s0
2637 ; CHECK-BE-NEXT: vmov.16 q1[1], r2
2638 ; CHECK-BE-NEXT: lsls r2, r1, #29
2639 ; CHECK-BE-NEXT: bpl .LBB24_3
2640 ; CHECK-BE-NEXT: .LBB24_12: @ %cond.load4
2641 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #4]
2642 ; CHECK-BE-NEXT: vmov r2, s0
2643 ; CHECK-BE-NEXT: vmov.16 q1[2], r2
2644 ; CHECK-BE-NEXT: lsls r2, r1, #28
2645 ; CHECK-BE-NEXT: bpl .LBB24_4
2646 ; CHECK-BE-NEXT: .LBB24_13: @ %cond.load7
2647 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #6]
2648 ; CHECK-BE-NEXT: vmov r2, s0
2649 ; CHECK-BE-NEXT: vmov.16 q1[3], r2
2650 ; CHECK-BE-NEXT: lsls r2, r1, #27
2651 ; CHECK-BE-NEXT: bpl .LBB24_5
2652 ; CHECK-BE-NEXT: .LBB24_14: @ %cond.load10
2653 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #8]
2654 ; CHECK-BE-NEXT: vmov r2, s0
2655 ; CHECK-BE-NEXT: vmov.16 q1[4], r2
2656 ; CHECK-BE-NEXT: lsls r2, r1, #26
2657 ; CHECK-BE-NEXT: bpl .LBB24_6
2658 ; CHECK-BE-NEXT: .LBB24_15: @ %cond.load13
2659 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #10]
2660 ; CHECK-BE-NEXT: vmov r2, s0
2661 ; CHECK-BE-NEXT: vmov.16 q1[5], r2
2662 ; CHECK-BE-NEXT: lsls r2, r1, #25
2663 ; CHECK-BE-NEXT: bpl .LBB24_7
2664 ; CHECK-BE-NEXT: .LBB24_16: @ %cond.load16
2665 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #12]
2666 ; CHECK-BE-NEXT: vmov r2, s0
2667 ; CHECK-BE-NEXT: vmov.16 q1[6], r2
2668 ; CHECK-BE-NEXT: lsls r1, r1, #24
2669 ; CHECK-BE-NEXT: bmi .LBB24_8
2670 ; CHECK-BE-NEXT: b .LBB24_9
2672 %c = icmp sgt <8 x i16> %a, zeroinitializer
2673 %l = call <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>* %dest, i32 2, <8 x i1> %c, <8 x half> undef)
2677 define arm_aapcs_vfpcc <8 x half> @masked_v8f16_align1_undef(<8 x half> *%dest, <8 x i16> %a) {
2678 ; CHECK-LE-LABEL: masked_v8f16_align1_undef:
2679 ; CHECK-LE: @ %bb.0: @ %entry
2680 ; CHECK-LE-NEXT: .pad #40
2681 ; CHECK-LE-NEXT: sub sp, #40
2682 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
2683 ; CHECK-LE-NEXT: add r1, sp, #32
2684 ; CHECK-LE-NEXT: vstr p0, [r1]
2685 ; CHECK-LE-NEXT: @ implicit-def: $q0
2686 ; CHECK-LE-NEXT: ldrb.w r1, [sp, #32]
2687 ; CHECK-LE-NEXT: lsls r2, r1, #31
2688 ; CHECK-LE-NEXT: bne .LBB25_9
2689 ; CHECK-LE-NEXT: @ %bb.1: @ %else
2690 ; CHECK-LE-NEXT: lsls r2, r1, #30
2691 ; CHECK-LE-NEXT: bmi .LBB25_10
2692 ; CHECK-LE-NEXT: .LBB25_2: @ %else2
2693 ; CHECK-LE-NEXT: lsls r2, r1, #29
2694 ; CHECK-LE-NEXT: bmi .LBB25_11
2695 ; CHECK-LE-NEXT: .LBB25_3: @ %else5
2696 ; CHECK-LE-NEXT: lsls r2, r1, #28
2697 ; CHECK-LE-NEXT: bmi .LBB25_12
2698 ; CHECK-LE-NEXT: .LBB25_4: @ %else8
2699 ; CHECK-LE-NEXT: lsls r2, r1, #27
2700 ; CHECK-LE-NEXT: bmi .LBB25_13
2701 ; CHECK-LE-NEXT: .LBB25_5: @ %else11
2702 ; CHECK-LE-NEXT: lsls r2, r1, #26
2703 ; CHECK-LE-NEXT: bmi .LBB25_14
2704 ; CHECK-LE-NEXT: .LBB25_6: @ %else14
2705 ; CHECK-LE-NEXT: lsls r2, r1, #25
2706 ; CHECK-LE-NEXT: bmi .LBB25_15
2707 ; CHECK-LE-NEXT: .LBB25_7: @ %else17
2708 ; CHECK-LE-NEXT: lsls r1, r1, #24
2709 ; CHECK-LE-NEXT: bmi .LBB25_16
2710 ; CHECK-LE-NEXT: .LBB25_8: @ %else20
2711 ; CHECK-LE-NEXT: add sp, #40
2712 ; CHECK-LE-NEXT: bx lr
2713 ; CHECK-LE-NEXT: .LBB25_9: @ %cond.load
2714 ; CHECK-LE-NEXT: ldrh r2, [r0]
2715 ; CHECK-LE-NEXT: strh.w r2, [sp, #28]
2716 ; CHECK-LE-NEXT: vldr.16 s0, [sp, #28]
2717 ; CHECK-LE-NEXT: lsls r2, r1, #30
2718 ; CHECK-LE-NEXT: bpl .LBB25_2
2719 ; CHECK-LE-NEXT: .LBB25_10: @ %cond.load1
2720 ; CHECK-LE-NEXT: ldrh r2, [r0, #2]
2721 ; CHECK-LE-NEXT: strh.w r2, [sp, #24]
2722 ; CHECK-LE-NEXT: vldr.16 s4, [sp, #24]
2723 ; CHECK-LE-NEXT: vmov r2, s4
2724 ; CHECK-LE-NEXT: vmov.16 q0[1], r2
2725 ; CHECK-LE-NEXT: lsls r2, r1, #29
2726 ; CHECK-LE-NEXT: bpl .LBB25_3
2727 ; CHECK-LE-NEXT: .LBB25_11: @ %cond.load4
2728 ; CHECK-LE-NEXT: ldrh r2, [r0, #4]
2729 ; CHECK-LE-NEXT: strh.w r2, [sp, #20]
2730 ; CHECK-LE-NEXT: vldr.16 s4, [sp, #20]
2731 ; CHECK-LE-NEXT: vmov r2, s4
2732 ; CHECK-LE-NEXT: vmov.16 q0[2], r2
2733 ; CHECK-LE-NEXT: lsls r2, r1, #28
2734 ; CHECK-LE-NEXT: bpl .LBB25_4
2735 ; CHECK-LE-NEXT: .LBB25_12: @ %cond.load7
2736 ; CHECK-LE-NEXT: ldrh r2, [r0, #6]
2737 ; CHECK-LE-NEXT: strh.w r2, [sp, #16]
2738 ; CHECK-LE-NEXT: vldr.16 s4, [sp, #16]
2739 ; CHECK-LE-NEXT: vmov r2, s4
2740 ; CHECK-LE-NEXT: vmov.16 q0[3], r2
2741 ; CHECK-LE-NEXT: lsls r2, r1, #27
2742 ; CHECK-LE-NEXT: bpl .LBB25_5
2743 ; CHECK-LE-NEXT: .LBB25_13: @ %cond.load10
2744 ; CHECK-LE-NEXT: ldrh r2, [r0, #8]
2745 ; CHECK-LE-NEXT: strh.w r2, [sp, #12]
2746 ; CHECK-LE-NEXT: vldr.16 s4, [sp, #12]
2747 ; CHECK-LE-NEXT: vmov r2, s4
2748 ; CHECK-LE-NEXT: vmov.16 q0[4], r2
2749 ; CHECK-LE-NEXT: lsls r2, r1, #26
2750 ; CHECK-LE-NEXT: bpl .LBB25_6
2751 ; CHECK-LE-NEXT: .LBB25_14: @ %cond.load13
2752 ; CHECK-LE-NEXT: ldrh r2, [r0, #10]
2753 ; CHECK-LE-NEXT: strh.w r2, [sp, #8]
2754 ; CHECK-LE-NEXT: vldr.16 s4, [sp, #8]
2755 ; CHECK-LE-NEXT: vmov r2, s4
2756 ; CHECK-LE-NEXT: vmov.16 q0[5], r2
2757 ; CHECK-LE-NEXT: lsls r2, r1, #25
2758 ; CHECK-LE-NEXT: bpl .LBB25_7
2759 ; CHECK-LE-NEXT: .LBB25_15: @ %cond.load16
2760 ; CHECK-LE-NEXT: ldrh r2, [r0, #12]
2761 ; CHECK-LE-NEXT: strh.w r2, [sp, #4]
2762 ; CHECK-LE-NEXT: vldr.16 s4, [sp, #4]
2763 ; CHECK-LE-NEXT: vmov r2, s4
2764 ; CHECK-LE-NEXT: vmov.16 q0[6], r2
2765 ; CHECK-LE-NEXT: lsls r1, r1, #24
2766 ; CHECK-LE-NEXT: bpl .LBB25_8
2767 ; CHECK-LE-NEXT: .LBB25_16: @ %cond.load19
2768 ; CHECK-LE-NEXT: ldrh r0, [r0, #14]
2769 ; CHECK-LE-NEXT: strh.w r0, [sp]
2770 ; CHECK-LE-NEXT: vldr.16 s4, [sp]
2771 ; CHECK-LE-NEXT: vmov r0, s4
2772 ; CHECK-LE-NEXT: vmov.16 q0[7], r0
2773 ; CHECK-LE-NEXT: add sp, #40
2774 ; CHECK-LE-NEXT: bx lr
2776 ; CHECK-BE-LABEL: masked_v8f16_align1_undef:
2777 ; CHECK-BE: @ %bb.0: @ %entry
2778 ; CHECK-BE-NEXT: .pad #40
2779 ; CHECK-BE-NEXT: sub sp, #40
2780 ; CHECK-BE-NEXT: vrev64.16 q1, q0
2781 ; CHECK-BE-NEXT: add r1, sp, #32
2782 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
2783 ; CHECK-BE-NEXT: @ implicit-def: $q1
2784 ; CHECK-BE-NEXT: vstr p0, [r1]
2785 ; CHECK-BE-NEXT: ldrb.w r1, [sp, #32]
2786 ; CHECK-BE-NEXT: lsls r2, r1, #31
2787 ; CHECK-BE-NEXT: bne .LBB25_10
2788 ; CHECK-BE-NEXT: @ %bb.1: @ %else
2789 ; CHECK-BE-NEXT: lsls r2, r1, #30
2790 ; CHECK-BE-NEXT: bmi .LBB25_11
2791 ; CHECK-BE-NEXT: .LBB25_2: @ %else2
2792 ; CHECK-BE-NEXT: lsls r2, r1, #29
2793 ; CHECK-BE-NEXT: bmi .LBB25_12
2794 ; CHECK-BE-NEXT: .LBB25_3: @ %else5
2795 ; CHECK-BE-NEXT: lsls r2, r1, #28
2796 ; CHECK-BE-NEXT: bmi .LBB25_13
2797 ; CHECK-BE-NEXT: .LBB25_4: @ %else8
2798 ; CHECK-BE-NEXT: lsls r2, r1, #27
2799 ; CHECK-BE-NEXT: bmi .LBB25_14
2800 ; CHECK-BE-NEXT: .LBB25_5: @ %else11
2801 ; CHECK-BE-NEXT: lsls r2, r1, #26
2802 ; CHECK-BE-NEXT: bmi .LBB25_15
2803 ; CHECK-BE-NEXT: .LBB25_6: @ %else14
2804 ; CHECK-BE-NEXT: lsls r2, r1, #25
2805 ; CHECK-BE-NEXT: bmi .LBB25_16
2806 ; CHECK-BE-NEXT: .LBB25_7: @ %else17
2807 ; CHECK-BE-NEXT: lsls r1, r1, #24
2808 ; CHECK-BE-NEXT: bpl .LBB25_9
2809 ; CHECK-BE-NEXT: .LBB25_8: @ %cond.load19
2810 ; CHECK-BE-NEXT: ldrh r0, [r0, #14]
2811 ; CHECK-BE-NEXT: strh.w r0, [sp]
2812 ; CHECK-BE-NEXT: vldr.16 s0, [sp]
2813 ; CHECK-BE-NEXT: vmov r0, s0
2814 ; CHECK-BE-NEXT: vmov.16 q1[7], r0
2815 ; CHECK-BE-NEXT: .LBB25_9: @ %else20
2816 ; CHECK-BE-NEXT: vrev64.16 q0, q1
2817 ; CHECK-BE-NEXT: add sp, #40
2818 ; CHECK-BE-NEXT: bx lr
2819 ; CHECK-BE-NEXT: .LBB25_10: @ %cond.load
2820 ; CHECK-BE-NEXT: ldrh r2, [r0]
2821 ; CHECK-BE-NEXT: strh.w r2, [sp, #28]
2822 ; CHECK-BE-NEXT: vldr.16 s4, [sp, #28]
2823 ; CHECK-BE-NEXT: lsls r2, r1, #30
2824 ; CHECK-BE-NEXT: bpl .LBB25_2
2825 ; CHECK-BE-NEXT: .LBB25_11: @ %cond.load1
2826 ; CHECK-BE-NEXT: ldrh r2, [r0, #2]
2827 ; CHECK-BE-NEXT: strh.w r2, [sp, #24]
2828 ; CHECK-BE-NEXT: vldr.16 s0, [sp, #24]
2829 ; CHECK-BE-NEXT: vmov r2, s0
2830 ; CHECK-BE-NEXT: vmov.16 q1[1], r2
2831 ; CHECK-BE-NEXT: lsls r2, r1, #29
2832 ; CHECK-BE-NEXT: bpl .LBB25_3
2833 ; CHECK-BE-NEXT: .LBB25_12: @ %cond.load4
2834 ; CHECK-BE-NEXT: ldrh r2, [r0, #4]
2835 ; CHECK-BE-NEXT: strh.w r2, [sp, #20]
2836 ; CHECK-BE-NEXT: vldr.16 s0, [sp, #20]
2837 ; CHECK-BE-NEXT: vmov r2, s0
2838 ; CHECK-BE-NEXT: vmov.16 q1[2], r2
2839 ; CHECK-BE-NEXT: lsls r2, r1, #28
2840 ; CHECK-BE-NEXT: bpl .LBB25_4
2841 ; CHECK-BE-NEXT: .LBB25_13: @ %cond.load7
2842 ; CHECK-BE-NEXT: ldrh r2, [r0, #6]
2843 ; CHECK-BE-NEXT: strh.w r2, [sp, #16]
2844 ; CHECK-BE-NEXT: vldr.16 s0, [sp, #16]
2845 ; CHECK-BE-NEXT: vmov r2, s0
2846 ; CHECK-BE-NEXT: vmov.16 q1[3], r2
2847 ; CHECK-BE-NEXT: lsls r2, r1, #27
2848 ; CHECK-BE-NEXT: bpl .LBB25_5
2849 ; CHECK-BE-NEXT: .LBB25_14: @ %cond.load10
2850 ; CHECK-BE-NEXT: ldrh r2, [r0, #8]
2851 ; CHECK-BE-NEXT: strh.w r2, [sp, #12]
2852 ; CHECK-BE-NEXT: vldr.16 s0, [sp, #12]
2853 ; CHECK-BE-NEXT: vmov r2, s0
2854 ; CHECK-BE-NEXT: vmov.16 q1[4], r2
2855 ; CHECK-BE-NEXT: lsls r2, r1, #26
2856 ; CHECK-BE-NEXT: bpl .LBB25_6
2857 ; CHECK-BE-NEXT: .LBB25_15: @ %cond.load13
2858 ; CHECK-BE-NEXT: ldrh r2, [r0, #10]
2859 ; CHECK-BE-NEXT: strh.w r2, [sp, #8]
2860 ; CHECK-BE-NEXT: vldr.16 s0, [sp, #8]
2861 ; CHECK-BE-NEXT: vmov r2, s0
2862 ; CHECK-BE-NEXT: vmov.16 q1[5], r2
2863 ; CHECK-BE-NEXT: lsls r2, r1, #25
2864 ; CHECK-BE-NEXT: bpl .LBB25_7
2865 ; CHECK-BE-NEXT: .LBB25_16: @ %cond.load16
2866 ; CHECK-BE-NEXT: ldrh r2, [r0, #12]
2867 ; CHECK-BE-NEXT: strh.w r2, [sp, #4]
2868 ; CHECK-BE-NEXT: vldr.16 s0, [sp, #4]
2869 ; CHECK-BE-NEXT: vmov r2, s0
2870 ; CHECK-BE-NEXT: vmov.16 q1[6], r2
2871 ; CHECK-BE-NEXT: lsls r1, r1, #24
2872 ; CHECK-BE-NEXT: bmi .LBB25_8
2873 ; CHECK-BE-NEXT: b .LBB25_9
2875 %c = icmp sgt <8 x i16> %a, zeroinitializer
2876 %l = call <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>* %dest, i32 1, <8 x i1> %c, <8 x half> undef)
2880 define arm_aapcs_vfpcc <8 x half> @masked_v8f16_align4_other(<8 x half> *%dest, <8 x i16> %a, <8 x half> %b) {
2881 ; CHECK-LE-LABEL: masked_v8f16_align4_other:
2882 ; CHECK-LE: @ %bb.0: @ %entry
2883 ; CHECK-LE-NEXT: .pad #8
2884 ; CHECK-LE-NEXT: sub sp, #8
2885 ; CHECK-LE-NEXT: mov r1, sp
2886 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
2887 ; CHECK-LE-NEXT: vstr p0, [r1]
2888 ; CHECK-LE-NEXT: ldrb.w r1, [sp]
2889 ; CHECK-LE-NEXT: lsls r2, r1, #31
2890 ; CHECK-LE-NEXT: bne .LBB26_10
2891 ; CHECK-LE-NEXT: @ %bb.1: @ %else
2892 ; CHECK-LE-NEXT: lsls r2, r1, #30
2893 ; CHECK-LE-NEXT: bmi .LBB26_11
2894 ; CHECK-LE-NEXT: .LBB26_2: @ %else2
2895 ; CHECK-LE-NEXT: lsls r2, r1, #29
2896 ; CHECK-LE-NEXT: bmi .LBB26_12
2897 ; CHECK-LE-NEXT: .LBB26_3: @ %else5
2898 ; CHECK-LE-NEXT: lsls r2, r1, #28
2899 ; CHECK-LE-NEXT: bmi .LBB26_13
2900 ; CHECK-LE-NEXT: .LBB26_4: @ %else8
2901 ; CHECK-LE-NEXT: lsls r2, r1, #27
2902 ; CHECK-LE-NEXT: bmi .LBB26_14
2903 ; CHECK-LE-NEXT: .LBB26_5: @ %else11
2904 ; CHECK-LE-NEXT: lsls r2, r1, #26
2905 ; CHECK-LE-NEXT: bmi .LBB26_15
2906 ; CHECK-LE-NEXT: .LBB26_6: @ %else14
2907 ; CHECK-LE-NEXT: lsls r2, r1, #25
2908 ; CHECK-LE-NEXT: bmi .LBB26_16
2909 ; CHECK-LE-NEXT: .LBB26_7: @ %else17
2910 ; CHECK-LE-NEXT: lsls r1, r1, #24
2911 ; CHECK-LE-NEXT: bpl .LBB26_9
2912 ; CHECK-LE-NEXT: .LBB26_8: @ %cond.load19
2913 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #14]
2914 ; CHECK-LE-NEXT: vmov r0, s0
2915 ; CHECK-LE-NEXT: vmov.16 q1[7], r0
2916 ; CHECK-LE-NEXT: .LBB26_9: @ %else20
2917 ; CHECK-LE-NEXT: vmov q0, q1
2918 ; CHECK-LE-NEXT: add sp, #8
2919 ; CHECK-LE-NEXT: bx lr
2920 ; CHECK-LE-NEXT: .LBB26_10: @ %cond.load
2921 ; CHECK-LE-NEXT: vldr.16 s0, [r0]
2922 ; CHECK-LE-NEXT: vmov r2, s0
2923 ; CHECK-LE-NEXT: vmov.16 q1[0], r2
2924 ; CHECK-LE-NEXT: lsls r2, r1, #30
2925 ; CHECK-LE-NEXT: bpl .LBB26_2
2926 ; CHECK-LE-NEXT: .LBB26_11: @ %cond.load1
2927 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #2]
2928 ; CHECK-LE-NEXT: vmov r2, s0
2929 ; CHECK-LE-NEXT: vmov.16 q1[1], r2
2930 ; CHECK-LE-NEXT: lsls r2, r1, #29
2931 ; CHECK-LE-NEXT: bpl .LBB26_3
2932 ; CHECK-LE-NEXT: .LBB26_12: @ %cond.load4
2933 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #4]
2934 ; CHECK-LE-NEXT: vmov r2, s0
2935 ; CHECK-LE-NEXT: vmov.16 q1[2], r2
2936 ; CHECK-LE-NEXT: lsls r2, r1, #28
2937 ; CHECK-LE-NEXT: bpl .LBB26_4
2938 ; CHECK-LE-NEXT: .LBB26_13: @ %cond.load7
2939 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #6]
2940 ; CHECK-LE-NEXT: vmov r2, s0
2941 ; CHECK-LE-NEXT: vmov.16 q1[3], r2
2942 ; CHECK-LE-NEXT: lsls r2, r1, #27
2943 ; CHECK-LE-NEXT: bpl .LBB26_5
2944 ; CHECK-LE-NEXT: .LBB26_14: @ %cond.load10
2945 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #8]
2946 ; CHECK-LE-NEXT: vmov r2, s0
2947 ; CHECK-LE-NEXT: vmov.16 q1[4], r2
2948 ; CHECK-LE-NEXT: lsls r2, r1, #26
2949 ; CHECK-LE-NEXT: bpl .LBB26_6
2950 ; CHECK-LE-NEXT: .LBB26_15: @ %cond.load13
2951 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #10]
2952 ; CHECK-LE-NEXT: vmov r2, s0
2953 ; CHECK-LE-NEXT: vmov.16 q1[5], r2
2954 ; CHECK-LE-NEXT: lsls r2, r1, #25
2955 ; CHECK-LE-NEXT: bpl .LBB26_7
2956 ; CHECK-LE-NEXT: .LBB26_16: @ %cond.load16
2957 ; CHECK-LE-NEXT: vldr.16 s0, [r0, #12]
2958 ; CHECK-LE-NEXT: vmov r2, s0
2959 ; CHECK-LE-NEXT: vmov.16 q1[6], r2
2960 ; CHECK-LE-NEXT: lsls r1, r1, #24
2961 ; CHECK-LE-NEXT: bmi .LBB26_8
2962 ; CHECK-LE-NEXT: b .LBB26_9
2964 ; CHECK-BE-LABEL: masked_v8f16_align4_other:
2965 ; CHECK-BE: @ %bb.0: @ %entry
2966 ; CHECK-BE-NEXT: .pad #8
2967 ; CHECK-BE-NEXT: sub sp, #8
2968 ; CHECK-BE-NEXT: vrev64.16 q2, q0
2969 ; CHECK-BE-NEXT: mov r1, sp
2970 ; CHECK-BE-NEXT: vcmp.s16 gt, q2, zr
2971 ; CHECK-BE-NEXT: vrev64.16 q2, q1
2972 ; CHECK-BE-NEXT: vstr p0, [r1]
2973 ; CHECK-BE-NEXT: ldrb.w r1, [sp]
2974 ; CHECK-BE-NEXT: lsls r2, r1, #31
2975 ; CHECK-BE-NEXT: bne .LBB26_10
2976 ; CHECK-BE-NEXT: @ %bb.1: @ %else
2977 ; CHECK-BE-NEXT: lsls r2, r1, #30
2978 ; CHECK-BE-NEXT: bmi .LBB26_11
2979 ; CHECK-BE-NEXT: .LBB26_2: @ %else2
2980 ; CHECK-BE-NEXT: lsls r2, r1, #29
2981 ; CHECK-BE-NEXT: bmi .LBB26_12
2982 ; CHECK-BE-NEXT: .LBB26_3: @ %else5
2983 ; CHECK-BE-NEXT: lsls r2, r1, #28
2984 ; CHECK-BE-NEXT: bmi .LBB26_13
2985 ; CHECK-BE-NEXT: .LBB26_4: @ %else8
2986 ; CHECK-BE-NEXT: lsls r2, r1, #27
2987 ; CHECK-BE-NEXT: bmi .LBB26_14
2988 ; CHECK-BE-NEXT: .LBB26_5: @ %else11
2989 ; CHECK-BE-NEXT: lsls r2, r1, #26
2990 ; CHECK-BE-NEXT: bmi .LBB26_15
2991 ; CHECK-BE-NEXT: .LBB26_6: @ %else14
2992 ; CHECK-BE-NEXT: lsls r2, r1, #25
2993 ; CHECK-BE-NEXT: bmi .LBB26_16
2994 ; CHECK-BE-NEXT: .LBB26_7: @ %else17
2995 ; CHECK-BE-NEXT: lsls r1, r1, #24
2996 ; CHECK-BE-NEXT: bpl .LBB26_9
2997 ; CHECK-BE-NEXT: .LBB26_8: @ %cond.load19
2998 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #14]
2999 ; CHECK-BE-NEXT: vmov r0, s0
3000 ; CHECK-BE-NEXT: vmov.16 q2[7], r0
3001 ; CHECK-BE-NEXT: .LBB26_9: @ %else20
3002 ; CHECK-BE-NEXT: vrev64.16 q0, q2
3003 ; CHECK-BE-NEXT: add sp, #8
3004 ; CHECK-BE-NEXT: bx lr
3005 ; CHECK-BE-NEXT: .LBB26_10: @ %cond.load
3006 ; CHECK-BE-NEXT: vldr.16 s0, [r0]
3007 ; CHECK-BE-NEXT: vmov r2, s0
3008 ; CHECK-BE-NEXT: vmov.16 q2[0], r2
3009 ; CHECK-BE-NEXT: lsls r2, r1, #30
3010 ; CHECK-BE-NEXT: bpl .LBB26_2
3011 ; CHECK-BE-NEXT: .LBB26_11: @ %cond.load1
3012 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #2]
3013 ; CHECK-BE-NEXT: vmov r2, s0
3014 ; CHECK-BE-NEXT: vmov.16 q2[1], r2
3015 ; CHECK-BE-NEXT: lsls r2, r1, #29
3016 ; CHECK-BE-NEXT: bpl .LBB26_3
3017 ; CHECK-BE-NEXT: .LBB26_12: @ %cond.load4
3018 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #4]
3019 ; CHECK-BE-NEXT: vmov r2, s0
3020 ; CHECK-BE-NEXT: vmov.16 q2[2], r2
3021 ; CHECK-BE-NEXT: lsls r2, r1, #28
3022 ; CHECK-BE-NEXT: bpl .LBB26_4
3023 ; CHECK-BE-NEXT: .LBB26_13: @ %cond.load7
3024 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #6]
3025 ; CHECK-BE-NEXT: vmov r2, s0
3026 ; CHECK-BE-NEXT: vmov.16 q2[3], r2
3027 ; CHECK-BE-NEXT: lsls r2, r1, #27
3028 ; CHECK-BE-NEXT: bpl .LBB26_5
3029 ; CHECK-BE-NEXT: .LBB26_14: @ %cond.load10
3030 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #8]
3031 ; CHECK-BE-NEXT: vmov r2, s0
3032 ; CHECK-BE-NEXT: vmov.16 q2[4], r2
3033 ; CHECK-BE-NEXT: lsls r2, r1, #26
3034 ; CHECK-BE-NEXT: bpl .LBB26_6
3035 ; CHECK-BE-NEXT: .LBB26_15: @ %cond.load13
3036 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #10]
3037 ; CHECK-BE-NEXT: vmov r2, s0
3038 ; CHECK-BE-NEXT: vmov.16 q2[5], r2
3039 ; CHECK-BE-NEXT: lsls r2, r1, #25
3040 ; CHECK-BE-NEXT: bpl .LBB26_7
3041 ; CHECK-BE-NEXT: .LBB26_16: @ %cond.load16
3042 ; CHECK-BE-NEXT: vldr.16 s0, [r0, #12]
3043 ; CHECK-BE-NEXT: vmov r2, s0
3044 ; CHECK-BE-NEXT: vmov.16 q2[6], r2
3045 ; CHECK-BE-NEXT: lsls r1, r1, #24
3046 ; CHECK-BE-NEXT: bmi .LBB26_8
3047 ; CHECK-BE-NEXT: b .LBB26_9
3049 %c = icmp sgt <8 x i16> %a, zeroinitializer
3050 %l = call <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>* %dest, i32 2, <8 x i1> %c, <8 x half> %b)
3054 define arm_aapcs_vfpcc i8* @masked_v8f16_preinc(i8* %x, i8* %y, <8 x i16> %a) {
3055 ; CHECK-LE-LABEL: masked_v8f16_preinc:
3056 ; CHECK-LE: @ %bb.0: @ %entry
3057 ; CHECK-LE-NEXT: .pad #8
3058 ; CHECK-LE-NEXT: sub sp, #8
3059 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
3060 ; CHECK-LE-NEXT: mov r2, sp
3061 ; CHECK-LE-NEXT: vstr p0, [r2]
3062 ; CHECK-LE-NEXT: adds r0, #4
3063 ; CHECK-LE-NEXT: ldrb.w r2, [sp]
3064 ; CHECK-LE-NEXT: @ implicit-def: $q0
3065 ; CHECK-LE-NEXT: lsls r3, r2, #31
3066 ; CHECK-LE-NEXT: bne .LBB27_10
3067 ; CHECK-LE-NEXT: @ %bb.1: @ %else
3068 ; CHECK-LE-NEXT: lsls r3, r2, #30
3069 ; CHECK-LE-NEXT: bmi .LBB27_11
3070 ; CHECK-LE-NEXT: .LBB27_2: @ %else2
3071 ; CHECK-LE-NEXT: lsls r3, r2, #29
3072 ; CHECK-LE-NEXT: bmi .LBB27_12
3073 ; CHECK-LE-NEXT: .LBB27_3: @ %else5
3074 ; CHECK-LE-NEXT: lsls r3, r2, #28
3075 ; CHECK-LE-NEXT: bmi .LBB27_13
3076 ; CHECK-LE-NEXT: .LBB27_4: @ %else8
3077 ; CHECK-LE-NEXT: lsls r3, r2, #27
3078 ; CHECK-LE-NEXT: bmi .LBB27_14
3079 ; CHECK-LE-NEXT: .LBB27_5: @ %else11
3080 ; CHECK-LE-NEXT: lsls r3, r2, #26
3081 ; CHECK-LE-NEXT: bmi .LBB27_15
3082 ; CHECK-LE-NEXT: .LBB27_6: @ %else14
3083 ; CHECK-LE-NEXT: lsls r3, r2, #25
3084 ; CHECK-LE-NEXT: bmi .LBB27_16
3085 ; CHECK-LE-NEXT: .LBB27_7: @ %else17
3086 ; CHECK-LE-NEXT: lsls r2, r2, #24
3087 ; CHECK-LE-NEXT: bpl .LBB27_9
3088 ; CHECK-LE-NEXT: .LBB27_8: @ %cond.load19
3089 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #14]
3090 ; CHECK-LE-NEXT: vmov r2, s4
3091 ; CHECK-LE-NEXT: vmov.16 q0[7], r2
3092 ; CHECK-LE-NEXT: .LBB27_9: @ %else20
3093 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
3094 ; CHECK-LE-NEXT: add sp, #8
3095 ; CHECK-LE-NEXT: bx lr
3096 ; CHECK-LE-NEXT: .LBB27_10: @ %cond.load
3097 ; CHECK-LE-NEXT: vldr.16 s0, [r0]
3098 ; CHECK-LE-NEXT: lsls r3, r2, #30
3099 ; CHECK-LE-NEXT: bpl .LBB27_2
3100 ; CHECK-LE-NEXT: .LBB27_11: @ %cond.load1
3101 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #2]
3102 ; CHECK-LE-NEXT: vmov r3, s4
3103 ; CHECK-LE-NEXT: vmov.16 q0[1], r3
3104 ; CHECK-LE-NEXT: lsls r3, r2, #29
3105 ; CHECK-LE-NEXT: bpl .LBB27_3
3106 ; CHECK-LE-NEXT: .LBB27_12: @ %cond.load4
3107 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #4]
3108 ; CHECK-LE-NEXT: vmov r3, s4
3109 ; CHECK-LE-NEXT: vmov.16 q0[2], r3
3110 ; CHECK-LE-NEXT: lsls r3, r2, #28
3111 ; CHECK-LE-NEXT: bpl .LBB27_4
3112 ; CHECK-LE-NEXT: .LBB27_13: @ %cond.load7
3113 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #6]
3114 ; CHECK-LE-NEXT: vmov r3, s4
3115 ; CHECK-LE-NEXT: vmov.16 q0[3], r3
3116 ; CHECK-LE-NEXT: lsls r3, r2, #27
3117 ; CHECK-LE-NEXT: bpl .LBB27_5
3118 ; CHECK-LE-NEXT: .LBB27_14: @ %cond.load10
3119 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #8]
3120 ; CHECK-LE-NEXT: vmov r3, s4
3121 ; CHECK-LE-NEXT: vmov.16 q0[4], r3
3122 ; CHECK-LE-NEXT: lsls r3, r2, #26
3123 ; CHECK-LE-NEXT: bpl .LBB27_6
3124 ; CHECK-LE-NEXT: .LBB27_15: @ %cond.load13
3125 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #10]
3126 ; CHECK-LE-NEXT: vmov r3, s4
3127 ; CHECK-LE-NEXT: vmov.16 q0[5], r3
3128 ; CHECK-LE-NEXT: lsls r3, r2, #25
3129 ; CHECK-LE-NEXT: bpl .LBB27_7
3130 ; CHECK-LE-NEXT: .LBB27_16: @ %cond.load16
3131 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #12]
3132 ; CHECK-LE-NEXT: vmov r3, s4
3133 ; CHECK-LE-NEXT: vmov.16 q0[6], r3
3134 ; CHECK-LE-NEXT: lsls r2, r2, #24
3135 ; CHECK-LE-NEXT: bmi .LBB27_8
3136 ; CHECK-LE-NEXT: b .LBB27_9
3138 ; CHECK-BE-LABEL: masked_v8f16_preinc:
3139 ; CHECK-BE: @ %bb.0: @ %entry
3140 ; CHECK-BE-NEXT: .pad #8
3141 ; CHECK-BE-NEXT: sub sp, #8
3142 ; CHECK-BE-NEXT: vrev64.16 q1, q0
3143 ; CHECK-BE-NEXT: mov r2, sp
3144 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
3145 ; CHECK-BE-NEXT: adds r0, #4
3146 ; CHECK-BE-NEXT: vstr p0, [r2]
3147 ; CHECK-BE-NEXT: @ implicit-def: $q0
3148 ; CHECK-BE-NEXT: ldrb.w r2, [sp]
3149 ; CHECK-BE-NEXT: lsls r3, r2, #31
3150 ; CHECK-BE-NEXT: bne .LBB27_10
3151 ; CHECK-BE-NEXT: @ %bb.1: @ %else
3152 ; CHECK-BE-NEXT: lsls r3, r2, #30
3153 ; CHECK-BE-NEXT: bmi .LBB27_11
3154 ; CHECK-BE-NEXT: .LBB27_2: @ %else2
3155 ; CHECK-BE-NEXT: lsls r3, r2, #29
3156 ; CHECK-BE-NEXT: bmi .LBB27_12
3157 ; CHECK-BE-NEXT: .LBB27_3: @ %else5
3158 ; CHECK-BE-NEXT: lsls r3, r2, #28
3159 ; CHECK-BE-NEXT: bmi .LBB27_13
3160 ; CHECK-BE-NEXT: .LBB27_4: @ %else8
3161 ; CHECK-BE-NEXT: lsls r3, r2, #27
3162 ; CHECK-BE-NEXT: bmi .LBB27_14
3163 ; CHECK-BE-NEXT: .LBB27_5: @ %else11
3164 ; CHECK-BE-NEXT: lsls r3, r2, #26
3165 ; CHECK-BE-NEXT: bmi .LBB27_15
3166 ; CHECK-BE-NEXT: .LBB27_6: @ %else14
3167 ; CHECK-BE-NEXT: lsls r3, r2, #25
3168 ; CHECK-BE-NEXT: bmi .LBB27_16
3169 ; CHECK-BE-NEXT: .LBB27_7: @ %else17
3170 ; CHECK-BE-NEXT: lsls r2, r2, #24
3171 ; CHECK-BE-NEXT: bpl .LBB27_9
3172 ; CHECK-BE-NEXT: .LBB27_8: @ %cond.load19
3173 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #14]
3174 ; CHECK-BE-NEXT: vmov r2, s4
3175 ; CHECK-BE-NEXT: vmov.16 q0[7], r2
3176 ; CHECK-BE-NEXT: .LBB27_9: @ %else20
3177 ; CHECK-BE-NEXT: vstrh.16 q0, [r1]
3178 ; CHECK-BE-NEXT: add sp, #8
3179 ; CHECK-BE-NEXT: bx lr
3180 ; CHECK-BE-NEXT: .LBB27_10: @ %cond.load
3181 ; CHECK-BE-NEXT: vldr.16 s0, [r0]
3182 ; CHECK-BE-NEXT: lsls r3, r2, #30
3183 ; CHECK-BE-NEXT: bpl .LBB27_2
3184 ; CHECK-BE-NEXT: .LBB27_11: @ %cond.load1
3185 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #2]
3186 ; CHECK-BE-NEXT: vmov r3, s4
3187 ; CHECK-BE-NEXT: vmov.16 q0[1], r3
3188 ; CHECK-BE-NEXT: lsls r3, r2, #29
3189 ; CHECK-BE-NEXT: bpl .LBB27_3
3190 ; CHECK-BE-NEXT: .LBB27_12: @ %cond.load4
3191 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #4]
3192 ; CHECK-BE-NEXT: vmov r3, s4
3193 ; CHECK-BE-NEXT: vmov.16 q0[2], r3
3194 ; CHECK-BE-NEXT: lsls r3, r2, #28
3195 ; CHECK-BE-NEXT: bpl .LBB27_4
3196 ; CHECK-BE-NEXT: .LBB27_13: @ %cond.load7
3197 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #6]
3198 ; CHECK-BE-NEXT: vmov r3, s4
3199 ; CHECK-BE-NEXT: vmov.16 q0[3], r3
3200 ; CHECK-BE-NEXT: lsls r3, r2, #27
3201 ; CHECK-BE-NEXT: bpl .LBB27_5
3202 ; CHECK-BE-NEXT: .LBB27_14: @ %cond.load10
3203 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #8]
3204 ; CHECK-BE-NEXT: vmov r3, s4
3205 ; CHECK-BE-NEXT: vmov.16 q0[4], r3
3206 ; CHECK-BE-NEXT: lsls r3, r2, #26
3207 ; CHECK-BE-NEXT: bpl .LBB27_6
3208 ; CHECK-BE-NEXT: .LBB27_15: @ %cond.load13
3209 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #10]
3210 ; CHECK-BE-NEXT: vmov r3, s4
3211 ; CHECK-BE-NEXT: vmov.16 q0[5], r3
3212 ; CHECK-BE-NEXT: lsls r3, r2, #25
3213 ; CHECK-BE-NEXT: bpl .LBB27_7
3214 ; CHECK-BE-NEXT: .LBB27_16: @ %cond.load16
3215 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #12]
3216 ; CHECK-BE-NEXT: vmov r3, s4
3217 ; CHECK-BE-NEXT: vmov.16 q0[6], r3
3218 ; CHECK-BE-NEXT: lsls r2, r2, #24
3219 ; CHECK-BE-NEXT: bmi .LBB27_8
3220 ; CHECK-BE-NEXT: b .LBB27_9
3222 %z = getelementptr inbounds i8, i8* %x, i32 4
3223 %0 = bitcast i8* %z to <8 x half>*
3224 %c = icmp sgt <8 x i16> %a, zeroinitializer
3225 %1 = call <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>* %0, i32 4, <8 x i1> %c, <8 x half> undef)
3226 %2 = bitcast i8* %y to <8 x half>*
3227 store <8 x half> %1, <8 x half>* %2, align 4
3231 define arm_aapcs_vfpcc i8* @masked_v8f16_postinc(i8* %x, i8* %y, <8 x i16> %a) {
3232 ; CHECK-LE-LABEL: masked_v8f16_postinc:
3233 ; CHECK-LE: @ %bb.0: @ %entry
3234 ; CHECK-LE-NEXT: .pad #8
3235 ; CHECK-LE-NEXT: sub sp, #8
3236 ; CHECK-LE-NEXT: vcmp.s16 gt, q0, zr
3237 ; CHECK-LE-NEXT: mov r2, sp
3238 ; CHECK-LE-NEXT: vstr p0, [r2]
3239 ; CHECK-LE-NEXT: @ implicit-def: $q0
3240 ; CHECK-LE-NEXT: ldrb.w r3, [sp]
3241 ; CHECK-LE-NEXT: lsls r2, r3, #31
3242 ; CHECK-LE-NEXT: bne .LBB28_12
3243 ; CHECK-LE-NEXT: @ %bb.1: @ %else
3244 ; CHECK-LE-NEXT: lsls r2, r3, #30
3245 ; CHECK-LE-NEXT: bmi .LBB28_13
3246 ; CHECK-LE-NEXT: .LBB28_2: @ %else2
3247 ; CHECK-LE-NEXT: lsls r2, r3, #29
3248 ; CHECK-LE-NEXT: bmi .LBB28_14
3249 ; CHECK-LE-NEXT: .LBB28_3: @ %else5
3250 ; CHECK-LE-NEXT: lsls r2, r3, #28
3251 ; CHECK-LE-NEXT: bmi .LBB28_15
3252 ; CHECK-LE-NEXT: .LBB28_4: @ %else8
3253 ; CHECK-LE-NEXT: lsls r2, r3, #27
3254 ; CHECK-LE-NEXT: bmi .LBB28_16
3255 ; CHECK-LE-NEXT: .LBB28_5: @ %else11
3256 ; CHECK-LE-NEXT: lsls r2, r3, #26
3257 ; CHECK-LE-NEXT: bpl .LBB28_7
3258 ; CHECK-LE-NEXT: .LBB28_6: @ %cond.load13
3259 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #10]
3260 ; CHECK-LE-NEXT: vmov r2, s4
3261 ; CHECK-LE-NEXT: vmov.16 q0[5], r2
3262 ; CHECK-LE-NEXT: .LBB28_7: @ %else14
3263 ; CHECK-LE-NEXT: add.w r12, r0, #4
3264 ; CHECK-LE-NEXT: lsls r2, r3, #25
3265 ; CHECK-LE-NEXT: bpl .LBB28_9
3266 ; CHECK-LE-NEXT: @ %bb.8: @ %cond.load16
3267 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #12]
3268 ; CHECK-LE-NEXT: vmov r2, s4
3269 ; CHECK-LE-NEXT: vmov.16 q0[6], r2
3270 ; CHECK-LE-NEXT: .LBB28_9: @ %else17
3271 ; CHECK-LE-NEXT: lsls r2, r3, #24
3272 ; CHECK-LE-NEXT: bpl .LBB28_11
3273 ; CHECK-LE-NEXT: @ %bb.10: @ %cond.load19
3274 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #14]
3275 ; CHECK-LE-NEXT: vmov r0, s4
3276 ; CHECK-LE-NEXT: vmov.16 q0[7], r0
3277 ; CHECK-LE-NEXT: .LBB28_11: @ %else20
3278 ; CHECK-LE-NEXT: vstrw.32 q0, [r1]
3279 ; CHECK-LE-NEXT: mov r0, r12
3280 ; CHECK-LE-NEXT: add sp, #8
3281 ; CHECK-LE-NEXT: bx lr
3282 ; CHECK-LE-NEXT: .LBB28_12: @ %cond.load
3283 ; CHECK-LE-NEXT: vldr.16 s0, [r0]
3284 ; CHECK-LE-NEXT: lsls r2, r3, #30
3285 ; CHECK-LE-NEXT: bpl .LBB28_2
3286 ; CHECK-LE-NEXT: .LBB28_13: @ %cond.load1
3287 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #2]
3288 ; CHECK-LE-NEXT: vmov r2, s4
3289 ; CHECK-LE-NEXT: vmov.16 q0[1], r2
3290 ; CHECK-LE-NEXT: lsls r2, r3, #29
3291 ; CHECK-LE-NEXT: bpl .LBB28_3
3292 ; CHECK-LE-NEXT: .LBB28_14: @ %cond.load4
3293 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #4]
3294 ; CHECK-LE-NEXT: vmov r2, s4
3295 ; CHECK-LE-NEXT: vmov.16 q0[2], r2
3296 ; CHECK-LE-NEXT: lsls r2, r3, #28
3297 ; CHECK-LE-NEXT: bpl .LBB28_4
3298 ; CHECK-LE-NEXT: .LBB28_15: @ %cond.load7
3299 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #6]
3300 ; CHECK-LE-NEXT: vmov r2, s4
3301 ; CHECK-LE-NEXT: vmov.16 q0[3], r2
3302 ; CHECK-LE-NEXT: lsls r2, r3, #27
3303 ; CHECK-LE-NEXT: bpl .LBB28_5
3304 ; CHECK-LE-NEXT: .LBB28_16: @ %cond.load10
3305 ; CHECK-LE-NEXT: vldr.16 s4, [r0, #8]
3306 ; CHECK-LE-NEXT: vmov r2, s4
3307 ; CHECK-LE-NEXT: vmov.16 q0[4], r2
3308 ; CHECK-LE-NEXT: lsls r2, r3, #26
3309 ; CHECK-LE-NEXT: bmi .LBB28_6
3310 ; CHECK-LE-NEXT: b .LBB28_7
3312 ; CHECK-BE-LABEL: masked_v8f16_postinc:
3313 ; CHECK-BE: @ %bb.0: @ %entry
3314 ; CHECK-BE-NEXT: .pad #8
3315 ; CHECK-BE-NEXT: sub sp, #8
3316 ; CHECK-BE-NEXT: vrev64.16 q1, q0
3317 ; CHECK-BE-NEXT: mov r2, sp
3318 ; CHECK-BE-NEXT: vcmp.s16 gt, q1, zr
3319 ; CHECK-BE-NEXT: @ implicit-def: $q0
3320 ; CHECK-BE-NEXT: vstr p0, [r2]
3321 ; CHECK-BE-NEXT: ldrb.w r3, [sp]
3322 ; CHECK-BE-NEXT: lsls r2, r3, #31
3323 ; CHECK-BE-NEXT: bne .LBB28_12
3324 ; CHECK-BE-NEXT: @ %bb.1: @ %else
3325 ; CHECK-BE-NEXT: lsls r2, r3, #30
3326 ; CHECK-BE-NEXT: bmi .LBB28_13
3327 ; CHECK-BE-NEXT: .LBB28_2: @ %else2
3328 ; CHECK-BE-NEXT: lsls r2, r3, #29
3329 ; CHECK-BE-NEXT: bmi .LBB28_14
3330 ; CHECK-BE-NEXT: .LBB28_3: @ %else5
3331 ; CHECK-BE-NEXT: lsls r2, r3, #28
3332 ; CHECK-BE-NEXT: bmi .LBB28_15
3333 ; CHECK-BE-NEXT: .LBB28_4: @ %else8
3334 ; CHECK-BE-NEXT: lsls r2, r3, #27
3335 ; CHECK-BE-NEXT: bmi .LBB28_16
3336 ; CHECK-BE-NEXT: .LBB28_5: @ %else11
3337 ; CHECK-BE-NEXT: lsls r2, r3, #26
3338 ; CHECK-BE-NEXT: bpl .LBB28_7
3339 ; CHECK-BE-NEXT: .LBB28_6: @ %cond.load13
3340 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #10]
3341 ; CHECK-BE-NEXT: vmov r2, s4
3342 ; CHECK-BE-NEXT: vmov.16 q0[5], r2
3343 ; CHECK-BE-NEXT: .LBB28_7: @ %else14
3344 ; CHECK-BE-NEXT: add.w r12, r0, #4
3345 ; CHECK-BE-NEXT: lsls r2, r3, #25
3346 ; CHECK-BE-NEXT: bpl .LBB28_9
3347 ; CHECK-BE-NEXT: @ %bb.8: @ %cond.load16
3348 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #12]
3349 ; CHECK-BE-NEXT: vmov r2, s4
3350 ; CHECK-BE-NEXT: vmov.16 q0[6], r2
3351 ; CHECK-BE-NEXT: .LBB28_9: @ %else17
3352 ; CHECK-BE-NEXT: lsls r2, r3, #24
3353 ; CHECK-BE-NEXT: bpl .LBB28_11
3354 ; CHECK-BE-NEXT: @ %bb.10: @ %cond.load19
3355 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #14]
3356 ; CHECK-BE-NEXT: vmov r0, s4
3357 ; CHECK-BE-NEXT: vmov.16 q0[7], r0
3358 ; CHECK-BE-NEXT: .LBB28_11: @ %else20
3359 ; CHECK-BE-NEXT: vstrh.16 q0, [r1]
3360 ; CHECK-BE-NEXT: mov r0, r12
3361 ; CHECK-BE-NEXT: add sp, #8
3362 ; CHECK-BE-NEXT: bx lr
3363 ; CHECK-BE-NEXT: .LBB28_12: @ %cond.load
3364 ; CHECK-BE-NEXT: vldr.16 s0, [r0]
3365 ; CHECK-BE-NEXT: lsls r2, r3, #30
3366 ; CHECK-BE-NEXT: bpl .LBB28_2
3367 ; CHECK-BE-NEXT: .LBB28_13: @ %cond.load1
3368 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #2]
3369 ; CHECK-BE-NEXT: vmov r2, s4
3370 ; CHECK-BE-NEXT: vmov.16 q0[1], r2
3371 ; CHECK-BE-NEXT: lsls r2, r3, #29
3372 ; CHECK-BE-NEXT: bpl .LBB28_3
3373 ; CHECK-BE-NEXT: .LBB28_14: @ %cond.load4
3374 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #4]
3375 ; CHECK-BE-NEXT: vmov r2, s4
3376 ; CHECK-BE-NEXT: vmov.16 q0[2], r2
3377 ; CHECK-BE-NEXT: lsls r2, r3, #28
3378 ; CHECK-BE-NEXT: bpl .LBB28_4
3379 ; CHECK-BE-NEXT: .LBB28_15: @ %cond.load7
3380 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #6]
3381 ; CHECK-BE-NEXT: vmov r2, s4
3382 ; CHECK-BE-NEXT: vmov.16 q0[3], r2
3383 ; CHECK-BE-NEXT: lsls r2, r3, #27
3384 ; CHECK-BE-NEXT: bpl .LBB28_5
3385 ; CHECK-BE-NEXT: .LBB28_16: @ %cond.load10
3386 ; CHECK-BE-NEXT: vldr.16 s4, [r0, #8]
3387 ; CHECK-BE-NEXT: vmov r2, s4
3388 ; CHECK-BE-NEXT: vmov.16 q0[4], r2
3389 ; CHECK-BE-NEXT: lsls r2, r3, #26
3390 ; CHECK-BE-NEXT: bmi .LBB28_6
3391 ; CHECK-BE-NEXT: b .LBB28_7
3393 %z = getelementptr inbounds i8, i8* %x, i32 4
3394 %0 = bitcast i8* %x to <8 x half>*
3395 %c = icmp sgt <8 x i16> %a, zeroinitializer
3396 %1 = call <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>* %0, i32 4, <8 x i1> %c, <8 x half> undef)
3397 %2 = bitcast i8* %y to <8 x half>*
3398 store <8 x half> %1, <8 x half>* %2, align 4
3403 define arm_aapcs_vfpcc <2 x i64> @masked_v2i64_align4_zero(<2 x i64> *%dest, <2 x i64> %a) {
3404 ; CHECK-LE-LABEL: masked_v2i64_align4_zero:
3405 ; CHECK-LE: @ %bb.0: @ %entry
3406 ; CHECK-LE-NEXT: .pad #4
3407 ; CHECK-LE-NEXT: sub sp, #4
3408 ; CHECK-LE-NEXT: vmov r3, s0
3409 ; CHECK-LE-NEXT: movs r2, #0
3410 ; CHECK-LE-NEXT: vmov r1, s1
3411 ; CHECK-LE-NEXT: vmov r12, s3
3412 ; CHECK-LE-NEXT: rsbs r3, r3, #0
3413 ; CHECK-LE-NEXT: vmov r3, s2
3414 ; CHECK-LE-NEXT: sbcs.w r1, r2, r1
3415 ; CHECK-LE-NEXT: mov.w r1, #0
3416 ; CHECK-LE-NEXT: it lt
3417 ; CHECK-LE-NEXT: movlt r1, #1
3418 ; CHECK-LE-NEXT: rsbs r3, r3, #0
3419 ; CHECK-LE-NEXT: sbcs.w r3, r2, r12
3420 ; CHECK-LE-NEXT: it lt
3421 ; CHECK-LE-NEXT: movlt r2, #1
3422 ; CHECK-LE-NEXT: cmp r2, #0
3423 ; CHECK-LE-NEXT: it ne
3424 ; CHECK-LE-NEXT: mvnne r2, #1
3425 ; CHECK-LE-NEXT: bfi r2, r1, #0, #1
3426 ; CHECK-LE-NEXT: and r1, r2, #3
3427 ; CHECK-LE-NEXT: lsls r2, r2, #31
3428 ; CHECK-LE-NEXT: beq .LBB29_2
3429 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
3430 ; CHECK-LE-NEXT: vldr d1, .LCPI29_0
3431 ; CHECK-LE-NEXT: vldr d0, [r0]
3432 ; CHECK-LE-NEXT: b .LBB29_3
3433 ; CHECK-LE-NEXT: .LBB29_2:
3434 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
3435 ; CHECK-LE-NEXT: .LBB29_3: @ %else
3436 ; CHECK-LE-NEXT: lsls r1, r1, #30
3437 ; CHECK-LE-NEXT: it mi
3438 ; CHECK-LE-NEXT: vldrmi d1, [r0, #8]
3439 ; CHECK-LE-NEXT: add sp, #4
3440 ; CHECK-LE-NEXT: bx lr
3441 ; CHECK-LE-NEXT: .p2align 3
3442 ; CHECK-LE-NEXT: @ %bb.4:
3443 ; CHECK-LE-NEXT: .LCPI29_0:
3444 ; CHECK-LE-NEXT: .long 0 @ double 0
3445 ; CHECK-LE-NEXT: .long 0
3447 ; CHECK-BE-LABEL: masked_v2i64_align4_zero:
3448 ; CHECK-BE: @ %bb.0: @ %entry
3449 ; CHECK-BE-NEXT: .pad #4
3450 ; CHECK-BE-NEXT: sub sp, #4
3451 ; CHECK-BE-NEXT: vrev64.32 q1, q0
3452 ; CHECK-BE-NEXT: movs r2, #0
3453 ; CHECK-BE-NEXT: vmov r3, s7
3454 ; CHECK-BE-NEXT: vmov r1, s6
3455 ; CHECK-BE-NEXT: vmov r12, s4
3456 ; CHECK-BE-NEXT: rsbs r3, r3, #0
3457 ; CHECK-BE-NEXT: vmov r3, s5
3458 ; CHECK-BE-NEXT: sbcs.w r1, r2, r1
3459 ; CHECK-BE-NEXT: mov.w r1, #0
3460 ; CHECK-BE-NEXT: it lt
3461 ; CHECK-BE-NEXT: movlt r1, #1
3462 ; CHECK-BE-NEXT: rsbs r3, r3, #0
3463 ; CHECK-BE-NEXT: sbcs.w r3, r2, r12
3464 ; CHECK-BE-NEXT: it lt
3465 ; CHECK-BE-NEXT: movlt r2, #1
3466 ; CHECK-BE-NEXT: cmp r2, #0
3467 ; CHECK-BE-NEXT: it ne
3468 ; CHECK-BE-NEXT: mvnne r2, #1
3469 ; CHECK-BE-NEXT: bfi r2, r1, #0, #1
3470 ; CHECK-BE-NEXT: and r1, r2, #3
3471 ; CHECK-BE-NEXT: lsls r2, r2, #31
3472 ; CHECK-BE-NEXT: beq .LBB29_2
3473 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
3474 ; CHECK-BE-NEXT: vldr d1, .LCPI29_0
3475 ; CHECK-BE-NEXT: vldr d0, [r0]
3476 ; CHECK-BE-NEXT: b .LBB29_3
3477 ; CHECK-BE-NEXT: .LBB29_2:
3478 ; CHECK-BE-NEXT: vmov.i32 q1, #0x0
3479 ; CHECK-BE-NEXT: vrev64.32 q0, q1
3480 ; CHECK-BE-NEXT: .LBB29_3: @ %else
3481 ; CHECK-BE-NEXT: lsls r1, r1, #30
3482 ; CHECK-BE-NEXT: it mi
3483 ; CHECK-BE-NEXT: vldrmi d1, [r0, #8]
3484 ; CHECK-BE-NEXT: add sp, #4
3485 ; CHECK-BE-NEXT: bx lr
3486 ; CHECK-BE-NEXT: .p2align 3
3487 ; CHECK-BE-NEXT: @ %bb.4:
3488 ; CHECK-BE-NEXT: .LCPI29_0:
3489 ; CHECK-BE-NEXT: .long 0 @ double 0
3490 ; CHECK-BE-NEXT: .long 0
3492 %c = icmp sgt <2 x i64> %a, zeroinitializer
3493 %l = call <2 x i64> @llvm.masked.load.v2i64.p0v2i64(<2 x i64>* %dest, i32 8, <2 x i1> %c, <2 x i64> zeroinitializer)
3497 define arm_aapcs_vfpcc <2 x double> @masked_v2f64_align4_zero(<2 x double> *%dest, <2 x double> %a, <2 x i64> %b) {
3498 ; CHECK-LE-LABEL: masked_v2f64_align4_zero:
3499 ; CHECK-LE: @ %bb.0: @ %entry
3500 ; CHECK-LE-NEXT: .pad #4
3501 ; CHECK-LE-NEXT: sub sp, #4
3502 ; CHECK-LE-NEXT: vmov r3, s4
3503 ; CHECK-LE-NEXT: movs r2, #0
3504 ; CHECK-LE-NEXT: vmov r1, s5
3505 ; CHECK-LE-NEXT: vmov r12, s7
3506 ; CHECK-LE-NEXT: rsbs r3, r3, #0
3507 ; CHECK-LE-NEXT: vmov r3, s6
3508 ; CHECK-LE-NEXT: sbcs.w r1, r2, r1
3509 ; CHECK-LE-NEXT: mov.w r1, #0
3510 ; CHECK-LE-NEXT: it lt
3511 ; CHECK-LE-NEXT: movlt r1, #1
3512 ; CHECK-LE-NEXT: rsbs r3, r3, #0
3513 ; CHECK-LE-NEXT: sbcs.w r3, r2, r12
3514 ; CHECK-LE-NEXT: it lt
3515 ; CHECK-LE-NEXT: movlt r2, #1
3516 ; CHECK-LE-NEXT: cmp r2, #0
3517 ; CHECK-LE-NEXT: it ne
3518 ; CHECK-LE-NEXT: mvnne r2, #1
3519 ; CHECK-LE-NEXT: bfi r2, r1, #0, #1
3520 ; CHECK-LE-NEXT: and r1, r2, #3
3521 ; CHECK-LE-NEXT: lsls r2, r2, #31
3522 ; CHECK-LE-NEXT: beq .LBB30_2
3523 ; CHECK-LE-NEXT: @ %bb.1: @ %cond.load
3524 ; CHECK-LE-NEXT: vldr d1, .LCPI30_0
3525 ; CHECK-LE-NEXT: vldr d0, [r0]
3526 ; CHECK-LE-NEXT: b .LBB30_3
3527 ; CHECK-LE-NEXT: .LBB30_2:
3528 ; CHECK-LE-NEXT: vmov.i32 q0, #0x0
3529 ; CHECK-LE-NEXT: .LBB30_3: @ %else
3530 ; CHECK-LE-NEXT: lsls r1, r1, #30
3531 ; CHECK-LE-NEXT: it mi
3532 ; CHECK-LE-NEXT: vldrmi d1, [r0, #8]
3533 ; CHECK-LE-NEXT: add sp, #4
3534 ; CHECK-LE-NEXT: bx lr
3535 ; CHECK-LE-NEXT: .p2align 3
3536 ; CHECK-LE-NEXT: @ %bb.4:
3537 ; CHECK-LE-NEXT: .LCPI30_0:
3538 ; CHECK-LE-NEXT: .long 0 @ double 0
3539 ; CHECK-LE-NEXT: .long 0
3541 ; CHECK-BE-LABEL: masked_v2f64_align4_zero:
3542 ; CHECK-BE: @ %bb.0: @ %entry
3543 ; CHECK-BE-NEXT: .pad #4
3544 ; CHECK-BE-NEXT: sub sp, #4
3545 ; CHECK-BE-NEXT: vrev64.32 q0, q1
3546 ; CHECK-BE-NEXT: movs r2, #0
3547 ; CHECK-BE-NEXT: vmov r3, s3
3548 ; CHECK-BE-NEXT: vmov r1, s2
3549 ; CHECK-BE-NEXT: vmov r12, s0
3550 ; CHECK-BE-NEXT: rsbs r3, r3, #0
3551 ; CHECK-BE-NEXT: vmov r3, s1
3552 ; CHECK-BE-NEXT: sbcs.w r1, r2, r1
3553 ; CHECK-BE-NEXT: mov.w r1, #0
3554 ; CHECK-BE-NEXT: it lt
3555 ; CHECK-BE-NEXT: movlt r1, #1
3556 ; CHECK-BE-NEXT: rsbs r3, r3, #0
3557 ; CHECK-BE-NEXT: sbcs.w r3, r2, r12
3558 ; CHECK-BE-NEXT: it lt
3559 ; CHECK-BE-NEXT: movlt r2, #1
3560 ; CHECK-BE-NEXT: cmp r2, #0
3561 ; CHECK-BE-NEXT: it ne
3562 ; CHECK-BE-NEXT: mvnne r2, #1
3563 ; CHECK-BE-NEXT: bfi r2, r1, #0, #1
3564 ; CHECK-BE-NEXT: and r1, r2, #3
3565 ; CHECK-BE-NEXT: lsls r2, r2, #31
3566 ; CHECK-BE-NEXT: beq .LBB30_2
3567 ; CHECK-BE-NEXT: @ %bb.1: @ %cond.load
3568 ; CHECK-BE-NEXT: vldr d1, .LCPI30_0
3569 ; CHECK-BE-NEXT: vldr d0, [r0]
3570 ; CHECK-BE-NEXT: b .LBB30_3
3571 ; CHECK-BE-NEXT: .LBB30_2:
3572 ; CHECK-BE-NEXT: vmov.i32 q1, #0x0
3573 ; CHECK-BE-NEXT: vrev64.32 q0, q1
3574 ; CHECK-BE-NEXT: .LBB30_3: @ %else
3575 ; CHECK-BE-NEXT: lsls r1, r1, #30
3576 ; CHECK-BE-NEXT: it mi
3577 ; CHECK-BE-NEXT: vldrmi d1, [r0, #8]
3578 ; CHECK-BE-NEXT: add sp, #4
3579 ; CHECK-BE-NEXT: bx lr
3580 ; CHECK-BE-NEXT: .p2align 3
3581 ; CHECK-BE-NEXT: @ %bb.4:
3582 ; CHECK-BE-NEXT: .LCPI30_0:
3583 ; CHECK-BE-NEXT: .long 0 @ double 0
3584 ; CHECK-BE-NEXT: .long 0
3586 %c = icmp sgt <2 x i64> %b, zeroinitializer
3587 %l = call <2 x double> @llvm.masked.load.v2f64.p0v2f64(<2 x double>* %dest, i32 8, <2 x i1> %c, <2 x double> zeroinitializer)
3591 declare <4 x i32> @llvm.masked.load.v4i32.p0v4i32(<4 x i32>*, i32, <4 x i1>, <4 x i32>)
3592 declare <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>*, i32, <8 x i1>, <8 x i16>)
3593 declare <16 x i8> @llvm.masked.load.v16i8.p0v16i8(<16 x i8>*, i32, <16 x i1>, <16 x i8>)
3594 declare <4 x float> @llvm.masked.load.v4f32.p0v4f32(<4 x float>*, i32, <4 x i1>, <4 x float>)
3595 declare <8 x half> @llvm.masked.load.v8f16.p0v8f16(<8 x half>*, i32, <8 x i1>, <8 x half>)
3596 declare <2 x i64> @llvm.masked.load.v2i64.p0v2i64(<2 x i64>*, i32, <2 x i1>, <2 x i64>)
3597 declare <2 x double> @llvm.masked.load.v2f64.p0v2f64(<2 x double>*, i32, <2 x i1>, <2 x double>)