1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=thumbv8.1m.main-none-none-eabi -mattr=+mve,+fullfp16 -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=CHECK-MVE
3 ; RUN: llc -mtriple=thumbv8.1m.main-none-none-eabi -mattr=+mve.fp -verify-machineinstrs %s -o - | FileCheck %s --check-prefix=CHECK-MVEFP
5 define arm_aapcs_vfpcc <4 x float> @vcmp_oeq_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
6 ; CHECK-MVE-LABEL: vcmp_oeq_v4f32:
7 ; CHECK-MVE: @ %bb.0: @ %entry
8 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
9 ; CHECK-MVE-NEXT: movs r1, #0
10 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
11 ; CHECK-MVE-NEXT: it eq
12 ; CHECK-MVE-NEXT: moveq r1, #1
13 ; CHECK-MVE-NEXT: cmp r1, #0
14 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
15 ; CHECK-MVE-NEXT: cset r1, ne
16 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
17 ; CHECK-MVE-NEXT: mov.w r2, #0
18 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
19 ; CHECK-MVE-NEXT: it eq
20 ; CHECK-MVE-NEXT: moveq r2, #1
21 ; CHECK-MVE-NEXT: cmp r2, #0
22 ; CHECK-MVE-NEXT: cset r2, ne
23 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
24 ; CHECK-MVE-NEXT: mov.w r3, #0
25 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
26 ; CHECK-MVE-NEXT: it eq
27 ; CHECK-MVE-NEXT: moveq r3, #1
28 ; CHECK-MVE-NEXT: cmp r3, #0
29 ; CHECK-MVE-NEXT: cset r3, ne
30 ; CHECK-MVE-NEXT: movs r0, #0
31 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
32 ; CHECK-MVE-NEXT: it eq
33 ; CHECK-MVE-NEXT: moveq r0, #1
34 ; CHECK-MVE-NEXT: cmp r0, #0
35 ; CHECK-MVE-NEXT: cset r0, ne
36 ; CHECK-MVE-NEXT: cmp r3, #0
37 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
38 ; CHECK-MVE-NEXT: cmp r0, #0
39 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
40 ; CHECK-MVE-NEXT: cmp r1, #0
41 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
42 ; CHECK-MVE-NEXT: cmp r2, #0
43 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
44 ; CHECK-MVE-NEXT: bx lr
46 ; CHECK-MVEFP-LABEL: vcmp_oeq_v4f32:
47 ; CHECK-MVEFP: @ %bb.0: @ %entry
48 ; CHECK-MVEFP-NEXT: vcmp.f32 eq, q0, q1
49 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
50 ; CHECK-MVEFP-NEXT: bx lr
52 %c = fcmp oeq <4 x float> %src, %src2
53 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
57 define arm_aapcs_vfpcc <4 x float> @vcmp_one_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
58 ; CHECK-MVE-LABEL: vcmp_one_v4f32:
59 ; CHECK-MVE: @ %bb.0: @ %entry
60 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
61 ; CHECK-MVE-NEXT: movs r1, #0
62 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
63 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
64 ; CHECK-MVE-NEXT: it mi
65 ; CHECK-MVE-NEXT: movmi r1, #1
66 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
67 ; CHECK-MVE-NEXT: it gt
68 ; CHECK-MVE-NEXT: movgt r1, #1
69 ; CHECK-MVE-NEXT: cmp r1, #0
70 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
71 ; CHECK-MVE-NEXT: mov.w r2, #0
72 ; CHECK-MVE-NEXT: cset r1, ne
73 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
74 ; CHECK-MVE-NEXT: it mi
75 ; CHECK-MVE-NEXT: movmi r2, #1
76 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
77 ; CHECK-MVE-NEXT: it gt
78 ; CHECK-MVE-NEXT: movgt r2, #1
79 ; CHECK-MVE-NEXT: cmp r2, #0
80 ; CHECK-MVE-NEXT: mov.w r3, #0
81 ; CHECK-MVE-NEXT: cset r2, ne
82 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
83 ; CHECK-MVE-NEXT: it mi
84 ; CHECK-MVE-NEXT: movmi r3, #1
85 ; CHECK-MVE-NEXT: it gt
86 ; CHECK-MVE-NEXT: movgt r3, #1
87 ; CHECK-MVE-NEXT: cmp r3, #0
88 ; CHECK-MVE-NEXT: mov.w r0, #0
89 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
90 ; CHECK-MVE-NEXT: cset r3, ne
91 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
92 ; CHECK-MVE-NEXT: it mi
93 ; CHECK-MVE-NEXT: movmi r0, #1
94 ; CHECK-MVE-NEXT: it gt
95 ; CHECK-MVE-NEXT: movgt r0, #1
96 ; CHECK-MVE-NEXT: cmp r0, #0
97 ; CHECK-MVE-NEXT: cset r0, ne
98 ; CHECK-MVE-NEXT: cmp r3, #0
99 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
100 ; CHECK-MVE-NEXT: cmp r0, #0
101 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
102 ; CHECK-MVE-NEXT: cmp r1, #0
103 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
104 ; CHECK-MVE-NEXT: cmp r2, #0
105 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
106 ; CHECK-MVE-NEXT: bx lr
108 ; CHECK-MVEFP-LABEL: vcmp_one_v4f32:
109 ; CHECK-MVEFP: @ %bb.0: @ %entry
110 ; CHECK-MVEFP-NEXT: vpt.f32 le, q1, q0
111 ; CHECK-MVEFP-NEXT: vcmpt.f32 le, q0, q1
112 ; CHECK-MVEFP-NEXT: vpsel q0, q3, q2
113 ; CHECK-MVEFP-NEXT: bx lr
115 %c = fcmp one <4 x float> %src, %src2
116 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
120 define arm_aapcs_vfpcc <4 x float> @vcmp_ogt_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
121 ; CHECK-MVE-LABEL: vcmp_ogt_v4f32:
122 ; CHECK-MVE: @ %bb.0: @ %entry
123 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
124 ; CHECK-MVE-NEXT: movs r1, #0
125 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
126 ; CHECK-MVE-NEXT: it gt
127 ; CHECK-MVE-NEXT: movgt r1, #1
128 ; CHECK-MVE-NEXT: cmp r1, #0
129 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
130 ; CHECK-MVE-NEXT: cset r1, ne
131 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
132 ; CHECK-MVE-NEXT: mov.w r2, #0
133 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
134 ; CHECK-MVE-NEXT: it gt
135 ; CHECK-MVE-NEXT: movgt r2, #1
136 ; CHECK-MVE-NEXT: cmp r2, #0
137 ; CHECK-MVE-NEXT: cset r2, ne
138 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
139 ; CHECK-MVE-NEXT: mov.w r3, #0
140 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
141 ; CHECK-MVE-NEXT: it gt
142 ; CHECK-MVE-NEXT: movgt r3, #1
143 ; CHECK-MVE-NEXT: cmp r3, #0
144 ; CHECK-MVE-NEXT: cset r3, ne
145 ; CHECK-MVE-NEXT: movs r0, #0
146 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
147 ; CHECK-MVE-NEXT: it gt
148 ; CHECK-MVE-NEXT: movgt r0, #1
149 ; CHECK-MVE-NEXT: cmp r0, #0
150 ; CHECK-MVE-NEXT: cset r0, ne
151 ; CHECK-MVE-NEXT: cmp r3, #0
152 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
153 ; CHECK-MVE-NEXT: cmp r0, #0
154 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
155 ; CHECK-MVE-NEXT: cmp r1, #0
156 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
157 ; CHECK-MVE-NEXT: cmp r2, #0
158 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
159 ; CHECK-MVE-NEXT: bx lr
161 ; CHECK-MVEFP-LABEL: vcmp_ogt_v4f32:
162 ; CHECK-MVEFP: @ %bb.0: @ %entry
163 ; CHECK-MVEFP-NEXT: vcmp.f32 gt, q0, q1
164 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
165 ; CHECK-MVEFP-NEXT: bx lr
167 %c = fcmp ogt <4 x float> %src, %src2
168 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
172 define arm_aapcs_vfpcc <4 x float> @vcmp_oge_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
173 ; CHECK-MVE-LABEL: vcmp_oge_v4f32:
174 ; CHECK-MVE: @ %bb.0: @ %entry
175 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
176 ; CHECK-MVE-NEXT: movs r1, #0
177 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
178 ; CHECK-MVE-NEXT: it ge
179 ; CHECK-MVE-NEXT: movge r1, #1
180 ; CHECK-MVE-NEXT: cmp r1, #0
181 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
182 ; CHECK-MVE-NEXT: cset r1, ne
183 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
184 ; CHECK-MVE-NEXT: mov.w r2, #0
185 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
186 ; CHECK-MVE-NEXT: it ge
187 ; CHECK-MVE-NEXT: movge r2, #1
188 ; CHECK-MVE-NEXT: cmp r2, #0
189 ; CHECK-MVE-NEXT: cset r2, ne
190 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
191 ; CHECK-MVE-NEXT: mov.w r3, #0
192 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
193 ; CHECK-MVE-NEXT: it ge
194 ; CHECK-MVE-NEXT: movge r3, #1
195 ; CHECK-MVE-NEXT: cmp r3, #0
196 ; CHECK-MVE-NEXT: cset r3, ne
197 ; CHECK-MVE-NEXT: movs r0, #0
198 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
199 ; CHECK-MVE-NEXT: it ge
200 ; CHECK-MVE-NEXT: movge r0, #1
201 ; CHECK-MVE-NEXT: cmp r0, #0
202 ; CHECK-MVE-NEXT: cset r0, ne
203 ; CHECK-MVE-NEXT: cmp r3, #0
204 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
205 ; CHECK-MVE-NEXT: cmp r0, #0
206 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
207 ; CHECK-MVE-NEXT: cmp r1, #0
208 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
209 ; CHECK-MVE-NEXT: cmp r2, #0
210 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
211 ; CHECK-MVE-NEXT: bx lr
213 ; CHECK-MVEFP-LABEL: vcmp_oge_v4f32:
214 ; CHECK-MVEFP: @ %bb.0: @ %entry
215 ; CHECK-MVEFP-NEXT: vcmp.f32 ge, q0, q1
216 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
217 ; CHECK-MVEFP-NEXT: bx lr
219 %c = fcmp oge <4 x float> %src, %src2
220 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
224 define arm_aapcs_vfpcc <4 x float> @vcmp_olt_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
225 ; CHECK-MVE-LABEL: vcmp_olt_v4f32:
226 ; CHECK-MVE: @ %bb.0: @ %entry
227 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
228 ; CHECK-MVE-NEXT: movs r1, #0
229 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
230 ; CHECK-MVE-NEXT: it mi
231 ; CHECK-MVE-NEXT: movmi r1, #1
232 ; CHECK-MVE-NEXT: cmp r1, #0
233 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
234 ; CHECK-MVE-NEXT: cset r1, ne
235 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
236 ; CHECK-MVE-NEXT: mov.w r2, #0
237 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
238 ; CHECK-MVE-NEXT: it mi
239 ; CHECK-MVE-NEXT: movmi r2, #1
240 ; CHECK-MVE-NEXT: cmp r2, #0
241 ; CHECK-MVE-NEXT: cset r2, ne
242 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
243 ; CHECK-MVE-NEXT: mov.w r3, #0
244 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
245 ; CHECK-MVE-NEXT: it mi
246 ; CHECK-MVE-NEXT: movmi r3, #1
247 ; CHECK-MVE-NEXT: cmp r3, #0
248 ; CHECK-MVE-NEXT: cset r3, ne
249 ; CHECK-MVE-NEXT: movs r0, #0
250 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
251 ; CHECK-MVE-NEXT: it mi
252 ; CHECK-MVE-NEXT: movmi r0, #1
253 ; CHECK-MVE-NEXT: cmp r0, #0
254 ; CHECK-MVE-NEXT: cset r0, ne
255 ; CHECK-MVE-NEXT: cmp r3, #0
256 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
257 ; CHECK-MVE-NEXT: cmp r0, #0
258 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
259 ; CHECK-MVE-NEXT: cmp r1, #0
260 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
261 ; CHECK-MVE-NEXT: cmp r2, #0
262 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
263 ; CHECK-MVE-NEXT: bx lr
265 ; CHECK-MVEFP-LABEL: vcmp_olt_v4f32:
266 ; CHECK-MVEFP: @ %bb.0: @ %entry
267 ; CHECK-MVEFP-NEXT: vcmp.f32 gt, q1, q0
268 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
269 ; CHECK-MVEFP-NEXT: bx lr
271 %c = fcmp olt <4 x float> %src, %src2
272 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
276 define arm_aapcs_vfpcc <4 x float> @vcmp_ole_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
277 ; CHECK-MVE-LABEL: vcmp_ole_v4f32:
278 ; CHECK-MVE: @ %bb.0: @ %entry
279 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
280 ; CHECK-MVE-NEXT: movs r1, #0
281 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
282 ; CHECK-MVE-NEXT: it ls
283 ; CHECK-MVE-NEXT: movls r1, #1
284 ; CHECK-MVE-NEXT: cmp r1, #0
285 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
286 ; CHECK-MVE-NEXT: cset r1, ne
287 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
288 ; CHECK-MVE-NEXT: mov.w r2, #0
289 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
290 ; CHECK-MVE-NEXT: it ls
291 ; CHECK-MVE-NEXT: movls r2, #1
292 ; CHECK-MVE-NEXT: cmp r2, #0
293 ; CHECK-MVE-NEXT: cset r2, ne
294 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
295 ; CHECK-MVE-NEXT: mov.w r3, #0
296 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
297 ; CHECK-MVE-NEXT: it ls
298 ; CHECK-MVE-NEXT: movls r3, #1
299 ; CHECK-MVE-NEXT: cmp r3, #0
300 ; CHECK-MVE-NEXT: cset r3, ne
301 ; CHECK-MVE-NEXT: movs r0, #0
302 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
303 ; CHECK-MVE-NEXT: it ls
304 ; CHECK-MVE-NEXT: movls r0, #1
305 ; CHECK-MVE-NEXT: cmp r0, #0
306 ; CHECK-MVE-NEXT: cset r0, ne
307 ; CHECK-MVE-NEXT: cmp r3, #0
308 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
309 ; CHECK-MVE-NEXT: cmp r0, #0
310 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
311 ; CHECK-MVE-NEXT: cmp r1, #0
312 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
313 ; CHECK-MVE-NEXT: cmp r2, #0
314 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
315 ; CHECK-MVE-NEXT: bx lr
317 ; CHECK-MVEFP-LABEL: vcmp_ole_v4f32:
318 ; CHECK-MVEFP: @ %bb.0: @ %entry
319 ; CHECK-MVEFP-NEXT: vcmp.f32 ge, q1, q0
320 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
321 ; CHECK-MVEFP-NEXT: bx lr
323 %c = fcmp ole <4 x float> %src, %src2
324 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
328 define arm_aapcs_vfpcc <4 x float> @vcmp_ueq_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
329 ; CHECK-MVE-LABEL: vcmp_ueq_v4f32:
330 ; CHECK-MVE: @ %bb.0: @ %entry
331 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
332 ; CHECK-MVE-NEXT: movs r1, #0
333 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
334 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
335 ; CHECK-MVE-NEXT: it eq
336 ; CHECK-MVE-NEXT: moveq r1, #1
337 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
338 ; CHECK-MVE-NEXT: it vs
339 ; CHECK-MVE-NEXT: movvs r1, #1
340 ; CHECK-MVE-NEXT: cmp r1, #0
341 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
342 ; CHECK-MVE-NEXT: mov.w r2, #0
343 ; CHECK-MVE-NEXT: cset r1, ne
344 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
345 ; CHECK-MVE-NEXT: it eq
346 ; CHECK-MVE-NEXT: moveq r2, #1
347 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
348 ; CHECK-MVE-NEXT: it vs
349 ; CHECK-MVE-NEXT: movvs r2, #1
350 ; CHECK-MVE-NEXT: cmp r2, #0
351 ; CHECK-MVE-NEXT: mov.w r3, #0
352 ; CHECK-MVE-NEXT: cset r2, ne
353 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
354 ; CHECK-MVE-NEXT: it eq
355 ; CHECK-MVE-NEXT: moveq r3, #1
356 ; CHECK-MVE-NEXT: it vs
357 ; CHECK-MVE-NEXT: movvs r3, #1
358 ; CHECK-MVE-NEXT: cmp r3, #0
359 ; CHECK-MVE-NEXT: mov.w r0, #0
360 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
361 ; CHECK-MVE-NEXT: cset r3, ne
362 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
363 ; CHECK-MVE-NEXT: it eq
364 ; CHECK-MVE-NEXT: moveq r0, #1
365 ; CHECK-MVE-NEXT: it vs
366 ; CHECK-MVE-NEXT: movvs r0, #1
367 ; CHECK-MVE-NEXT: cmp r0, #0
368 ; CHECK-MVE-NEXT: cset r0, ne
369 ; CHECK-MVE-NEXT: cmp r3, #0
370 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
371 ; CHECK-MVE-NEXT: cmp r0, #0
372 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
373 ; CHECK-MVE-NEXT: cmp r1, #0
374 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
375 ; CHECK-MVE-NEXT: cmp r2, #0
376 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
377 ; CHECK-MVE-NEXT: bx lr
379 ; CHECK-MVEFP-LABEL: vcmp_ueq_v4f32:
380 ; CHECK-MVEFP: @ %bb.0: @ %entry
381 ; CHECK-MVEFP-NEXT: vpt.f32 le, q1, q0
382 ; CHECK-MVEFP-NEXT: vcmpt.f32 le, q0, q1
383 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
384 ; CHECK-MVEFP-NEXT: bx lr
386 %c = fcmp ueq <4 x float> %src, %src2
387 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
391 define arm_aapcs_vfpcc <4 x float> @vcmp_une_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
392 ; CHECK-MVE-LABEL: vcmp_une_v4f32:
393 ; CHECK-MVE: @ %bb.0: @ %entry
394 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
395 ; CHECK-MVE-NEXT: movs r1, #0
396 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
397 ; CHECK-MVE-NEXT: it ne
398 ; CHECK-MVE-NEXT: movne r1, #1
399 ; CHECK-MVE-NEXT: cmp r1, #0
400 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
401 ; CHECK-MVE-NEXT: cset r1, ne
402 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
403 ; CHECK-MVE-NEXT: mov.w r2, #0
404 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
405 ; CHECK-MVE-NEXT: it ne
406 ; CHECK-MVE-NEXT: movne r2, #1
407 ; CHECK-MVE-NEXT: cmp r2, #0
408 ; CHECK-MVE-NEXT: cset r2, ne
409 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
410 ; CHECK-MVE-NEXT: mov.w r3, #0
411 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
412 ; CHECK-MVE-NEXT: it ne
413 ; CHECK-MVE-NEXT: movne r3, #1
414 ; CHECK-MVE-NEXT: cmp r3, #0
415 ; CHECK-MVE-NEXT: cset r3, ne
416 ; CHECK-MVE-NEXT: movs r0, #0
417 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
418 ; CHECK-MVE-NEXT: it ne
419 ; CHECK-MVE-NEXT: movne r0, #1
420 ; CHECK-MVE-NEXT: cmp r0, #0
421 ; CHECK-MVE-NEXT: cset r0, ne
422 ; CHECK-MVE-NEXT: cmp r3, #0
423 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
424 ; CHECK-MVE-NEXT: cmp r0, #0
425 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
426 ; CHECK-MVE-NEXT: cmp r1, #0
427 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
428 ; CHECK-MVE-NEXT: cmp r2, #0
429 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
430 ; CHECK-MVE-NEXT: bx lr
432 ; CHECK-MVEFP-LABEL: vcmp_une_v4f32:
433 ; CHECK-MVEFP: @ %bb.0: @ %entry
434 ; CHECK-MVEFP-NEXT: vcmp.f32 ne, q0, q1
435 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
436 ; CHECK-MVEFP-NEXT: bx lr
438 %c = fcmp une <4 x float> %src, %src2
439 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
443 define arm_aapcs_vfpcc <4 x float> @vcmp_ugt_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
444 ; CHECK-MVE-LABEL: vcmp_ugt_v4f32:
445 ; CHECK-MVE: @ %bb.0: @ %entry
446 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
447 ; CHECK-MVE-NEXT: movs r1, #0
448 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
449 ; CHECK-MVE-NEXT: it hi
450 ; CHECK-MVE-NEXT: movhi r1, #1
451 ; CHECK-MVE-NEXT: cmp r1, #0
452 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
453 ; CHECK-MVE-NEXT: cset r1, ne
454 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
455 ; CHECK-MVE-NEXT: mov.w r2, #0
456 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
457 ; CHECK-MVE-NEXT: it hi
458 ; CHECK-MVE-NEXT: movhi r2, #1
459 ; CHECK-MVE-NEXT: cmp r2, #0
460 ; CHECK-MVE-NEXT: cset r2, ne
461 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
462 ; CHECK-MVE-NEXT: mov.w r3, #0
463 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
464 ; CHECK-MVE-NEXT: it hi
465 ; CHECK-MVE-NEXT: movhi r3, #1
466 ; CHECK-MVE-NEXT: cmp r3, #0
467 ; CHECK-MVE-NEXT: cset r3, ne
468 ; CHECK-MVE-NEXT: movs r0, #0
469 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
470 ; CHECK-MVE-NEXT: it hi
471 ; CHECK-MVE-NEXT: movhi r0, #1
472 ; CHECK-MVE-NEXT: cmp r0, #0
473 ; CHECK-MVE-NEXT: cset r0, ne
474 ; CHECK-MVE-NEXT: cmp r3, #0
475 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
476 ; CHECK-MVE-NEXT: cmp r0, #0
477 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
478 ; CHECK-MVE-NEXT: cmp r1, #0
479 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
480 ; CHECK-MVE-NEXT: cmp r2, #0
481 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
482 ; CHECK-MVE-NEXT: bx lr
484 ; CHECK-MVEFP-LABEL: vcmp_ugt_v4f32:
485 ; CHECK-MVEFP: @ %bb.0: @ %entry
486 ; CHECK-MVEFP-NEXT: vcmp.f32 lt, q1, q0
487 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
488 ; CHECK-MVEFP-NEXT: bx lr
490 %c = fcmp ugt <4 x float> %src, %src2
491 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
495 define arm_aapcs_vfpcc <4 x float> @vcmp_uge_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
496 ; CHECK-MVE-LABEL: vcmp_uge_v4f32:
497 ; CHECK-MVE: @ %bb.0: @ %entry
498 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
499 ; CHECK-MVE-NEXT: movs r1, #0
500 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
501 ; CHECK-MVE-NEXT: it pl
502 ; CHECK-MVE-NEXT: movpl r1, #1
503 ; CHECK-MVE-NEXT: cmp r1, #0
504 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
505 ; CHECK-MVE-NEXT: cset r1, ne
506 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
507 ; CHECK-MVE-NEXT: mov.w r2, #0
508 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
509 ; CHECK-MVE-NEXT: it pl
510 ; CHECK-MVE-NEXT: movpl r2, #1
511 ; CHECK-MVE-NEXT: cmp r2, #0
512 ; CHECK-MVE-NEXT: cset r2, ne
513 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
514 ; CHECK-MVE-NEXT: mov.w r3, #0
515 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
516 ; CHECK-MVE-NEXT: it pl
517 ; CHECK-MVE-NEXT: movpl r3, #1
518 ; CHECK-MVE-NEXT: cmp r3, #0
519 ; CHECK-MVE-NEXT: cset r3, ne
520 ; CHECK-MVE-NEXT: movs r0, #0
521 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
522 ; CHECK-MVE-NEXT: it pl
523 ; CHECK-MVE-NEXT: movpl r0, #1
524 ; CHECK-MVE-NEXT: cmp r0, #0
525 ; CHECK-MVE-NEXT: cset r0, ne
526 ; CHECK-MVE-NEXT: cmp r3, #0
527 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
528 ; CHECK-MVE-NEXT: cmp r0, #0
529 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
530 ; CHECK-MVE-NEXT: cmp r1, #0
531 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
532 ; CHECK-MVE-NEXT: cmp r2, #0
533 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
534 ; CHECK-MVE-NEXT: bx lr
536 ; CHECK-MVEFP-LABEL: vcmp_uge_v4f32:
537 ; CHECK-MVEFP: @ %bb.0: @ %entry
538 ; CHECK-MVEFP-NEXT: vcmp.f32 le, q1, q0
539 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
540 ; CHECK-MVEFP-NEXT: bx lr
542 %c = fcmp uge <4 x float> %src, %src2
543 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
547 define arm_aapcs_vfpcc <4 x float> @vcmp_ult_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
548 ; CHECK-MVE-LABEL: vcmp_ult_v4f32:
549 ; CHECK-MVE: @ %bb.0: @ %entry
550 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
551 ; CHECK-MVE-NEXT: movs r1, #0
552 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
553 ; CHECK-MVE-NEXT: it lt
554 ; CHECK-MVE-NEXT: movlt r1, #1
555 ; CHECK-MVE-NEXT: cmp r1, #0
556 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
557 ; CHECK-MVE-NEXT: cset r1, ne
558 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
559 ; CHECK-MVE-NEXT: mov.w r2, #0
560 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
561 ; CHECK-MVE-NEXT: it lt
562 ; CHECK-MVE-NEXT: movlt r2, #1
563 ; CHECK-MVE-NEXT: cmp r2, #0
564 ; CHECK-MVE-NEXT: cset r2, ne
565 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
566 ; CHECK-MVE-NEXT: mov.w r3, #0
567 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
568 ; CHECK-MVE-NEXT: it lt
569 ; CHECK-MVE-NEXT: movlt r3, #1
570 ; CHECK-MVE-NEXT: cmp r3, #0
571 ; CHECK-MVE-NEXT: cset r3, ne
572 ; CHECK-MVE-NEXT: movs r0, #0
573 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
574 ; CHECK-MVE-NEXT: it lt
575 ; CHECK-MVE-NEXT: movlt r0, #1
576 ; CHECK-MVE-NEXT: cmp r0, #0
577 ; CHECK-MVE-NEXT: cset r0, ne
578 ; CHECK-MVE-NEXT: cmp r3, #0
579 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
580 ; CHECK-MVE-NEXT: cmp r0, #0
581 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
582 ; CHECK-MVE-NEXT: cmp r1, #0
583 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
584 ; CHECK-MVE-NEXT: cmp r2, #0
585 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
586 ; CHECK-MVE-NEXT: bx lr
588 ; CHECK-MVEFP-LABEL: vcmp_ult_v4f32:
589 ; CHECK-MVEFP: @ %bb.0: @ %entry
590 ; CHECK-MVEFP-NEXT: vcmp.f32 lt, q0, q1
591 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
592 ; CHECK-MVEFP-NEXT: bx lr
594 %c = fcmp ult <4 x float> %src, %src2
595 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
599 define arm_aapcs_vfpcc <4 x float> @vcmp_ule_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
600 ; CHECK-MVE-LABEL: vcmp_ule_v4f32:
601 ; CHECK-MVE: @ %bb.0: @ %entry
602 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
603 ; CHECK-MVE-NEXT: movs r1, #0
604 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
605 ; CHECK-MVE-NEXT: it le
606 ; CHECK-MVE-NEXT: movle r1, #1
607 ; CHECK-MVE-NEXT: cmp r1, #0
608 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
609 ; CHECK-MVE-NEXT: cset r1, ne
610 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
611 ; CHECK-MVE-NEXT: mov.w r2, #0
612 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
613 ; CHECK-MVE-NEXT: it le
614 ; CHECK-MVE-NEXT: movle r2, #1
615 ; CHECK-MVE-NEXT: cmp r2, #0
616 ; CHECK-MVE-NEXT: cset r2, ne
617 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
618 ; CHECK-MVE-NEXT: mov.w r3, #0
619 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
620 ; CHECK-MVE-NEXT: it le
621 ; CHECK-MVE-NEXT: movle r3, #1
622 ; CHECK-MVE-NEXT: cmp r3, #0
623 ; CHECK-MVE-NEXT: cset r3, ne
624 ; CHECK-MVE-NEXT: movs r0, #0
625 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
626 ; CHECK-MVE-NEXT: it le
627 ; CHECK-MVE-NEXT: movle r0, #1
628 ; CHECK-MVE-NEXT: cmp r0, #0
629 ; CHECK-MVE-NEXT: cset r0, ne
630 ; CHECK-MVE-NEXT: cmp r3, #0
631 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
632 ; CHECK-MVE-NEXT: cmp r0, #0
633 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
634 ; CHECK-MVE-NEXT: cmp r1, #0
635 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
636 ; CHECK-MVE-NEXT: cmp r2, #0
637 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
638 ; CHECK-MVE-NEXT: bx lr
640 ; CHECK-MVEFP-LABEL: vcmp_ule_v4f32:
641 ; CHECK-MVEFP: @ %bb.0: @ %entry
642 ; CHECK-MVEFP-NEXT: vcmp.f32 le, q0, q1
643 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
644 ; CHECK-MVEFP-NEXT: bx lr
646 %c = fcmp ule <4 x float> %src, %src2
647 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
651 define arm_aapcs_vfpcc <4 x float> @vcmp_ord_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
652 ; CHECK-MVE-LABEL: vcmp_ord_v4f32:
653 ; CHECK-MVE: @ %bb.0: @ %entry
654 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
655 ; CHECK-MVE-NEXT: movs r1, #0
656 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
657 ; CHECK-MVE-NEXT: it vc
658 ; CHECK-MVE-NEXT: movvc r1, #1
659 ; CHECK-MVE-NEXT: cmp r1, #0
660 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
661 ; CHECK-MVE-NEXT: cset r1, ne
662 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
663 ; CHECK-MVE-NEXT: mov.w r2, #0
664 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
665 ; CHECK-MVE-NEXT: it vc
666 ; CHECK-MVE-NEXT: movvc r2, #1
667 ; CHECK-MVE-NEXT: cmp r2, #0
668 ; CHECK-MVE-NEXT: cset r2, ne
669 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
670 ; CHECK-MVE-NEXT: mov.w r3, #0
671 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
672 ; CHECK-MVE-NEXT: it vc
673 ; CHECK-MVE-NEXT: movvc r3, #1
674 ; CHECK-MVE-NEXT: cmp r3, #0
675 ; CHECK-MVE-NEXT: cset r3, ne
676 ; CHECK-MVE-NEXT: movs r0, #0
677 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
678 ; CHECK-MVE-NEXT: it vc
679 ; CHECK-MVE-NEXT: movvc r0, #1
680 ; CHECK-MVE-NEXT: cmp r0, #0
681 ; CHECK-MVE-NEXT: cset r0, ne
682 ; CHECK-MVE-NEXT: cmp r3, #0
683 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
684 ; CHECK-MVE-NEXT: cmp r0, #0
685 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
686 ; CHECK-MVE-NEXT: cmp r1, #0
687 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
688 ; CHECK-MVE-NEXT: cmp r2, #0
689 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
690 ; CHECK-MVE-NEXT: bx lr
692 ; CHECK-MVEFP-LABEL: vcmp_ord_v4f32:
693 ; CHECK-MVEFP: @ %bb.0: @ %entry
694 ; CHECK-MVEFP-NEXT: vpt.f32 le, q1, q0
695 ; CHECK-MVEFP-NEXT: vcmpt.f32 lt, q0, q1
696 ; CHECK-MVEFP-NEXT: vpsel q0, q3, q2
697 ; CHECK-MVEFP-NEXT: bx lr
699 %c = fcmp ord <4 x float> %src, %src2
700 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
704 define arm_aapcs_vfpcc <4 x float> @vcmp_uno_v4f32(<4 x float> %src, <4 x float> %src2, <4 x float> %a, <4 x float> %b) {
705 ; CHECK-MVE-LABEL: vcmp_uno_v4f32:
706 ; CHECK-MVE: @ %bb.0: @ %entry
707 ; CHECK-MVE-NEXT: vcmp.f32 s1, s5
708 ; CHECK-MVE-NEXT: movs r1, #0
709 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
710 ; CHECK-MVE-NEXT: it vs
711 ; CHECK-MVE-NEXT: movvs r1, #1
712 ; CHECK-MVE-NEXT: cmp r1, #0
713 ; CHECK-MVE-NEXT: vcmp.f32 s0, s4
714 ; CHECK-MVE-NEXT: cset r1, ne
715 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
716 ; CHECK-MVE-NEXT: mov.w r2, #0
717 ; CHECK-MVE-NEXT: vcmp.f32 s3, s7
718 ; CHECK-MVE-NEXT: it vs
719 ; CHECK-MVE-NEXT: movvs r2, #1
720 ; CHECK-MVE-NEXT: cmp r2, #0
721 ; CHECK-MVE-NEXT: cset r2, ne
722 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
723 ; CHECK-MVE-NEXT: mov.w r3, #0
724 ; CHECK-MVE-NEXT: vcmp.f32 s2, s6
725 ; CHECK-MVE-NEXT: it vs
726 ; CHECK-MVE-NEXT: movvs r3, #1
727 ; CHECK-MVE-NEXT: cmp r3, #0
728 ; CHECK-MVE-NEXT: cset r3, ne
729 ; CHECK-MVE-NEXT: movs r0, #0
730 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
731 ; CHECK-MVE-NEXT: it vs
732 ; CHECK-MVE-NEXT: movvs r0, #1
733 ; CHECK-MVE-NEXT: cmp r0, #0
734 ; CHECK-MVE-NEXT: cset r0, ne
735 ; CHECK-MVE-NEXT: cmp r3, #0
736 ; CHECK-MVE-NEXT: vseleq.f32 s3, s15, s11
737 ; CHECK-MVE-NEXT: cmp r0, #0
738 ; CHECK-MVE-NEXT: vseleq.f32 s2, s14, s10
739 ; CHECK-MVE-NEXT: cmp r1, #0
740 ; CHECK-MVE-NEXT: vseleq.f32 s1, s13, s9
741 ; CHECK-MVE-NEXT: cmp r2, #0
742 ; CHECK-MVE-NEXT: vseleq.f32 s0, s12, s8
743 ; CHECK-MVE-NEXT: bx lr
745 ; CHECK-MVEFP-LABEL: vcmp_uno_v4f32:
746 ; CHECK-MVEFP: @ %bb.0: @ %entry
747 ; CHECK-MVEFP-NEXT: vpt.f32 le, q1, q0
748 ; CHECK-MVEFP-NEXT: vcmpt.f32 lt, q0, q1
749 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
750 ; CHECK-MVEFP-NEXT: bx lr
752 %c = fcmp uno <4 x float> %src, %src2
753 %s = select <4 x i1> %c, <4 x float> %a, <4 x float> %b
759 define arm_aapcs_vfpcc <8 x half> @vcmp_oeq_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
760 ; CHECK-MVE-LABEL: vcmp_oeq_v8f16:
761 ; CHECK-MVE: @ %bb.0: @ %entry
762 ; CHECK-MVE-NEXT: .vsave {d8, d9}
763 ; CHECK-MVE-NEXT: vpush {d8, d9}
764 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
765 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
766 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
767 ; CHECK-MVE-NEXT: movs r1, #0
768 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
769 ; CHECK-MVE-NEXT: it eq
770 ; CHECK-MVE-NEXT: moveq r1, #1
771 ; CHECK-MVE-NEXT: cmp r1, #0
772 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
773 ; CHECK-MVE-NEXT: cset r1, ne
774 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
775 ; CHECK-MVE-NEXT: cmp r1, #0
776 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
777 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
778 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
779 ; CHECK-MVE-NEXT: mov.w r1, #0
780 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
781 ; CHECK-MVE-NEXT: it eq
782 ; CHECK-MVE-NEXT: moveq r1, #1
783 ; CHECK-MVE-NEXT: cmp r1, #0
784 ; CHECK-MVE-NEXT: cset r1, ne
785 ; CHECK-MVE-NEXT: movs r0, #0
786 ; CHECK-MVE-NEXT: cmp r1, #0
787 ; CHECK-MVE-NEXT: mov.w r1, #0
788 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
789 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
790 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
791 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
792 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
793 ; CHECK-MVE-NEXT: it eq
794 ; CHECK-MVE-NEXT: moveq r1, #1
795 ; CHECK-MVE-NEXT: cmp r1, #0
796 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
797 ; CHECK-MVE-NEXT: cset r1, ne
798 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
799 ; CHECK-MVE-NEXT: cmp r1, #0
800 ; CHECK-MVE-NEXT: mov.w r1, #0
801 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
802 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
803 ; CHECK-MVE-NEXT: it eq
804 ; CHECK-MVE-NEXT: moveq r1, #1
805 ; CHECK-MVE-NEXT: cmp r1, #0
806 ; CHECK-MVE-NEXT: cset r1, ne
807 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
808 ; CHECK-MVE-NEXT: cmp r1, #0
809 ; CHECK-MVE-NEXT: mov.w r1, #0
810 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
811 ; CHECK-MVE-NEXT: vins.f16 s0, s16
812 ; CHECK-MVE-NEXT: vins.f16 s1, s4
813 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
814 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
815 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
816 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
817 ; CHECK-MVE-NEXT: it eq
818 ; CHECK-MVE-NEXT: moveq r1, #1
819 ; CHECK-MVE-NEXT: cmp r1, #0
820 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
821 ; CHECK-MVE-NEXT: cset r1, ne
822 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
823 ; CHECK-MVE-NEXT: cmp r1, #0
824 ; CHECK-MVE-NEXT: mov.w r1, #0
825 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
826 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
827 ; CHECK-MVE-NEXT: it eq
828 ; CHECK-MVE-NEXT: moveq r1, #1
829 ; CHECK-MVE-NEXT: cmp r1, #0
830 ; CHECK-MVE-NEXT: cset r1, ne
831 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
832 ; CHECK-MVE-NEXT: cmp r1, #0
833 ; CHECK-MVE-NEXT: mov.w r1, #0
834 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
835 ; CHECK-MVE-NEXT: vins.f16 s2, s4
836 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
837 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
838 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
839 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
840 ; CHECK-MVE-NEXT: it eq
841 ; CHECK-MVE-NEXT: moveq r1, #1
842 ; CHECK-MVE-NEXT: cmp r1, #0
843 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
844 ; CHECK-MVE-NEXT: cset r1, ne
845 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
846 ; CHECK-MVE-NEXT: cmp r1, #0
847 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
848 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
849 ; CHECK-MVE-NEXT: it eq
850 ; CHECK-MVE-NEXT: moveq r0, #1
851 ; CHECK-MVE-NEXT: cmp r0, #0
852 ; CHECK-MVE-NEXT: cset r0, ne
853 ; CHECK-MVE-NEXT: cmp r0, #0
854 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
855 ; CHECK-MVE-NEXT: vins.f16 s3, s4
856 ; CHECK-MVE-NEXT: vpop {d8, d9}
857 ; CHECK-MVE-NEXT: bx lr
859 ; CHECK-MVEFP-LABEL: vcmp_oeq_v8f16:
860 ; CHECK-MVEFP: @ %bb.0: @ %entry
861 ; CHECK-MVEFP-NEXT: vcmp.f16 eq, q0, q1
862 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
863 ; CHECK-MVEFP-NEXT: bx lr
865 %c = fcmp oeq <8 x half> %src, %src2
866 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
870 define arm_aapcs_vfpcc <8 x half> @vcmp_one_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
871 ; CHECK-MVE-LABEL: vcmp_one_v8f16:
872 ; CHECK-MVE: @ %bb.0: @ %entry
873 ; CHECK-MVE-NEXT: .vsave {d8, d9}
874 ; CHECK-MVE-NEXT: vpush {d8, d9}
875 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
876 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
877 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
878 ; CHECK-MVE-NEXT: movs r1, #0
879 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
880 ; CHECK-MVE-NEXT: it mi
881 ; CHECK-MVE-NEXT: movmi r1, #1
882 ; CHECK-MVE-NEXT: it gt
883 ; CHECK-MVE-NEXT: movgt r1, #1
884 ; CHECK-MVE-NEXT: cmp r1, #0
885 ; CHECK-MVE-NEXT: cset r1, ne
886 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
887 ; CHECK-MVE-NEXT: cmp r1, #0
888 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
889 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
890 ; CHECK-MVE-NEXT: mov.w r1, #0
891 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
892 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
893 ; CHECK-MVE-NEXT: it mi
894 ; CHECK-MVE-NEXT: movmi r1, #1
895 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
896 ; CHECK-MVE-NEXT: it gt
897 ; CHECK-MVE-NEXT: movgt r1, #1
898 ; CHECK-MVE-NEXT: cmp r1, #0
899 ; CHECK-MVE-NEXT: cset r1, ne
900 ; CHECK-MVE-NEXT: movs r0, #0
901 ; CHECK-MVE-NEXT: cmp r1, #0
902 ; CHECK-MVE-NEXT: mov.w r1, #0
903 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
904 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
905 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
906 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
907 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
908 ; CHECK-MVE-NEXT: it mi
909 ; CHECK-MVE-NEXT: movmi r1, #1
910 ; CHECK-MVE-NEXT: it gt
911 ; CHECK-MVE-NEXT: movgt r1, #1
912 ; CHECK-MVE-NEXT: cmp r1, #0
913 ; CHECK-MVE-NEXT: cset r1, ne
914 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
915 ; CHECK-MVE-NEXT: cmp r1, #0
916 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
917 ; CHECK-MVE-NEXT: mov.w r1, #0
918 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
919 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
920 ; CHECK-MVE-NEXT: it mi
921 ; CHECK-MVE-NEXT: movmi r1, #1
922 ; CHECK-MVE-NEXT: it gt
923 ; CHECK-MVE-NEXT: movgt r1, #1
924 ; CHECK-MVE-NEXT: cmp r1, #0
925 ; CHECK-MVE-NEXT: cset r1, ne
926 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
927 ; CHECK-MVE-NEXT: cmp r1, #0
928 ; CHECK-MVE-NEXT: mov.w r1, #0
929 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
930 ; CHECK-MVE-NEXT: vins.f16 s0, s16
931 ; CHECK-MVE-NEXT: vins.f16 s1, s4
932 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
933 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
934 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
935 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
936 ; CHECK-MVE-NEXT: it mi
937 ; CHECK-MVE-NEXT: movmi r1, #1
938 ; CHECK-MVE-NEXT: it gt
939 ; CHECK-MVE-NEXT: movgt r1, #1
940 ; CHECK-MVE-NEXT: cmp r1, #0
941 ; CHECK-MVE-NEXT: cset r1, ne
942 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
943 ; CHECK-MVE-NEXT: cmp r1, #0
944 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
945 ; CHECK-MVE-NEXT: mov.w r1, #0
946 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
947 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
948 ; CHECK-MVE-NEXT: it mi
949 ; CHECK-MVE-NEXT: movmi r1, #1
950 ; CHECK-MVE-NEXT: it gt
951 ; CHECK-MVE-NEXT: movgt r1, #1
952 ; CHECK-MVE-NEXT: cmp r1, #0
953 ; CHECK-MVE-NEXT: cset r1, ne
954 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
955 ; CHECK-MVE-NEXT: cmp r1, #0
956 ; CHECK-MVE-NEXT: mov.w r1, #0
957 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
958 ; CHECK-MVE-NEXT: vins.f16 s2, s4
959 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
960 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
961 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
962 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
963 ; CHECK-MVE-NEXT: it mi
964 ; CHECK-MVE-NEXT: movmi r1, #1
965 ; CHECK-MVE-NEXT: it gt
966 ; CHECK-MVE-NEXT: movgt r1, #1
967 ; CHECK-MVE-NEXT: cmp r1, #0
968 ; CHECK-MVE-NEXT: cset r1, ne
969 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
970 ; CHECK-MVE-NEXT: cmp r1, #0
971 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
972 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
973 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
974 ; CHECK-MVE-NEXT: it mi
975 ; CHECK-MVE-NEXT: movmi r0, #1
976 ; CHECK-MVE-NEXT: it gt
977 ; CHECK-MVE-NEXT: movgt r0, #1
978 ; CHECK-MVE-NEXT: cmp r0, #0
979 ; CHECK-MVE-NEXT: cset r0, ne
980 ; CHECK-MVE-NEXT: cmp r0, #0
981 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
982 ; CHECK-MVE-NEXT: vins.f16 s3, s4
983 ; CHECK-MVE-NEXT: vpop {d8, d9}
984 ; CHECK-MVE-NEXT: bx lr
986 ; CHECK-MVEFP-LABEL: vcmp_one_v8f16:
987 ; CHECK-MVEFP: @ %bb.0: @ %entry
988 ; CHECK-MVEFP-NEXT: vpt.f16 le, q1, q0
989 ; CHECK-MVEFP-NEXT: vcmpt.f16 le, q0, q1
990 ; CHECK-MVEFP-NEXT: vpsel q0, q3, q2
991 ; CHECK-MVEFP-NEXT: bx lr
993 %c = fcmp one <8 x half> %src, %src2
994 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
998 define arm_aapcs_vfpcc <8 x half> @vcmp_ogt_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
999 ; CHECK-MVE-LABEL: vcmp_ogt_v8f16:
1000 ; CHECK-MVE: @ %bb.0: @ %entry
1001 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1002 ; CHECK-MVE-NEXT: vpush {d8, d9}
1003 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1004 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1005 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1006 ; CHECK-MVE-NEXT: movs r1, #0
1007 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1008 ; CHECK-MVE-NEXT: it gt
1009 ; CHECK-MVE-NEXT: movgt r1, #1
1010 ; CHECK-MVE-NEXT: cmp r1, #0
1011 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1012 ; CHECK-MVE-NEXT: cset r1, ne
1013 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1014 ; CHECK-MVE-NEXT: cmp r1, #0
1015 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1016 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1017 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1018 ; CHECK-MVE-NEXT: mov.w r1, #0
1019 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1020 ; CHECK-MVE-NEXT: it gt
1021 ; CHECK-MVE-NEXT: movgt r1, #1
1022 ; CHECK-MVE-NEXT: cmp r1, #0
1023 ; CHECK-MVE-NEXT: cset r1, ne
1024 ; CHECK-MVE-NEXT: movs r0, #0
1025 ; CHECK-MVE-NEXT: cmp r1, #0
1026 ; CHECK-MVE-NEXT: mov.w r1, #0
1027 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1028 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1029 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1030 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1031 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1032 ; CHECK-MVE-NEXT: it gt
1033 ; CHECK-MVE-NEXT: movgt r1, #1
1034 ; CHECK-MVE-NEXT: cmp r1, #0
1035 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1036 ; CHECK-MVE-NEXT: cset r1, ne
1037 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1038 ; CHECK-MVE-NEXT: cmp r1, #0
1039 ; CHECK-MVE-NEXT: mov.w r1, #0
1040 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1041 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1042 ; CHECK-MVE-NEXT: it gt
1043 ; CHECK-MVE-NEXT: movgt r1, #1
1044 ; CHECK-MVE-NEXT: cmp r1, #0
1045 ; CHECK-MVE-NEXT: cset r1, ne
1046 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1047 ; CHECK-MVE-NEXT: cmp r1, #0
1048 ; CHECK-MVE-NEXT: mov.w r1, #0
1049 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1050 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1051 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1052 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1053 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1054 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1055 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1056 ; CHECK-MVE-NEXT: it gt
1057 ; CHECK-MVE-NEXT: movgt r1, #1
1058 ; CHECK-MVE-NEXT: cmp r1, #0
1059 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1060 ; CHECK-MVE-NEXT: cset r1, ne
1061 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1062 ; CHECK-MVE-NEXT: cmp r1, #0
1063 ; CHECK-MVE-NEXT: mov.w r1, #0
1064 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1065 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1066 ; CHECK-MVE-NEXT: it gt
1067 ; CHECK-MVE-NEXT: movgt r1, #1
1068 ; CHECK-MVE-NEXT: cmp r1, #0
1069 ; CHECK-MVE-NEXT: cset r1, ne
1070 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1071 ; CHECK-MVE-NEXT: cmp r1, #0
1072 ; CHECK-MVE-NEXT: mov.w r1, #0
1073 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1074 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1075 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1076 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1077 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1078 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1079 ; CHECK-MVE-NEXT: it gt
1080 ; CHECK-MVE-NEXT: movgt r1, #1
1081 ; CHECK-MVE-NEXT: cmp r1, #0
1082 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1083 ; CHECK-MVE-NEXT: cset r1, ne
1084 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1085 ; CHECK-MVE-NEXT: cmp r1, #0
1086 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1087 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1088 ; CHECK-MVE-NEXT: it gt
1089 ; CHECK-MVE-NEXT: movgt r0, #1
1090 ; CHECK-MVE-NEXT: cmp r0, #0
1091 ; CHECK-MVE-NEXT: cset r0, ne
1092 ; CHECK-MVE-NEXT: cmp r0, #0
1093 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1094 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1095 ; CHECK-MVE-NEXT: vpop {d8, d9}
1096 ; CHECK-MVE-NEXT: bx lr
1098 ; CHECK-MVEFP-LABEL: vcmp_ogt_v8f16:
1099 ; CHECK-MVEFP: @ %bb.0: @ %entry
1100 ; CHECK-MVEFP-NEXT: vcmp.f16 gt, q0, q1
1101 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1102 ; CHECK-MVEFP-NEXT: bx lr
1104 %c = fcmp ogt <8 x half> %src, %src2
1105 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1109 define arm_aapcs_vfpcc <8 x half> @vcmp_oge_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1110 ; CHECK-MVE-LABEL: vcmp_oge_v8f16:
1111 ; CHECK-MVE: @ %bb.0: @ %entry
1112 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1113 ; CHECK-MVE-NEXT: vpush {d8, d9}
1114 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1115 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1116 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1117 ; CHECK-MVE-NEXT: movs r1, #0
1118 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1119 ; CHECK-MVE-NEXT: it ge
1120 ; CHECK-MVE-NEXT: movge r1, #1
1121 ; CHECK-MVE-NEXT: cmp r1, #0
1122 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1123 ; CHECK-MVE-NEXT: cset r1, ne
1124 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1125 ; CHECK-MVE-NEXT: cmp r1, #0
1126 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1127 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1128 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1129 ; CHECK-MVE-NEXT: mov.w r1, #0
1130 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1131 ; CHECK-MVE-NEXT: it ge
1132 ; CHECK-MVE-NEXT: movge r1, #1
1133 ; CHECK-MVE-NEXT: cmp r1, #0
1134 ; CHECK-MVE-NEXT: cset r1, ne
1135 ; CHECK-MVE-NEXT: movs r0, #0
1136 ; CHECK-MVE-NEXT: cmp r1, #0
1137 ; CHECK-MVE-NEXT: mov.w r1, #0
1138 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1139 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1140 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1141 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1142 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1143 ; CHECK-MVE-NEXT: it ge
1144 ; CHECK-MVE-NEXT: movge r1, #1
1145 ; CHECK-MVE-NEXT: cmp r1, #0
1146 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1147 ; CHECK-MVE-NEXT: cset r1, ne
1148 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1149 ; CHECK-MVE-NEXT: cmp r1, #0
1150 ; CHECK-MVE-NEXT: mov.w r1, #0
1151 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1152 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1153 ; CHECK-MVE-NEXT: it ge
1154 ; CHECK-MVE-NEXT: movge r1, #1
1155 ; CHECK-MVE-NEXT: cmp r1, #0
1156 ; CHECK-MVE-NEXT: cset r1, ne
1157 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1158 ; CHECK-MVE-NEXT: cmp r1, #0
1159 ; CHECK-MVE-NEXT: mov.w r1, #0
1160 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1161 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1162 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1163 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1164 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1165 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1166 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1167 ; CHECK-MVE-NEXT: it ge
1168 ; CHECK-MVE-NEXT: movge r1, #1
1169 ; CHECK-MVE-NEXT: cmp r1, #0
1170 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1171 ; CHECK-MVE-NEXT: cset r1, ne
1172 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1173 ; CHECK-MVE-NEXT: cmp r1, #0
1174 ; CHECK-MVE-NEXT: mov.w r1, #0
1175 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1176 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1177 ; CHECK-MVE-NEXT: it ge
1178 ; CHECK-MVE-NEXT: movge r1, #1
1179 ; CHECK-MVE-NEXT: cmp r1, #0
1180 ; CHECK-MVE-NEXT: cset r1, ne
1181 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1182 ; CHECK-MVE-NEXT: cmp r1, #0
1183 ; CHECK-MVE-NEXT: mov.w r1, #0
1184 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1185 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1186 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1187 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1188 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1189 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1190 ; CHECK-MVE-NEXT: it ge
1191 ; CHECK-MVE-NEXT: movge r1, #1
1192 ; CHECK-MVE-NEXT: cmp r1, #0
1193 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1194 ; CHECK-MVE-NEXT: cset r1, ne
1195 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1196 ; CHECK-MVE-NEXT: cmp r1, #0
1197 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1198 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1199 ; CHECK-MVE-NEXT: it ge
1200 ; CHECK-MVE-NEXT: movge r0, #1
1201 ; CHECK-MVE-NEXT: cmp r0, #0
1202 ; CHECK-MVE-NEXT: cset r0, ne
1203 ; CHECK-MVE-NEXT: cmp r0, #0
1204 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1205 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1206 ; CHECK-MVE-NEXT: vpop {d8, d9}
1207 ; CHECK-MVE-NEXT: bx lr
1209 ; CHECK-MVEFP-LABEL: vcmp_oge_v8f16:
1210 ; CHECK-MVEFP: @ %bb.0: @ %entry
1211 ; CHECK-MVEFP-NEXT: vcmp.f16 ge, q0, q1
1212 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1213 ; CHECK-MVEFP-NEXT: bx lr
1215 %c = fcmp oge <8 x half> %src, %src2
1216 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1220 define arm_aapcs_vfpcc <8 x half> @vcmp_olt_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1221 ; CHECK-MVE-LABEL: vcmp_olt_v8f16:
1222 ; CHECK-MVE: @ %bb.0: @ %entry
1223 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1224 ; CHECK-MVE-NEXT: vpush {d8, d9}
1225 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1226 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1227 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1228 ; CHECK-MVE-NEXT: movs r1, #0
1229 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1230 ; CHECK-MVE-NEXT: it mi
1231 ; CHECK-MVE-NEXT: movmi r1, #1
1232 ; CHECK-MVE-NEXT: cmp r1, #0
1233 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1234 ; CHECK-MVE-NEXT: cset r1, ne
1235 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1236 ; CHECK-MVE-NEXT: cmp r1, #0
1237 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1238 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1239 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1240 ; CHECK-MVE-NEXT: mov.w r1, #0
1241 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1242 ; CHECK-MVE-NEXT: it mi
1243 ; CHECK-MVE-NEXT: movmi r1, #1
1244 ; CHECK-MVE-NEXT: cmp r1, #0
1245 ; CHECK-MVE-NEXT: cset r1, ne
1246 ; CHECK-MVE-NEXT: movs r0, #0
1247 ; CHECK-MVE-NEXT: cmp r1, #0
1248 ; CHECK-MVE-NEXT: mov.w r1, #0
1249 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1250 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1251 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1252 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1253 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1254 ; CHECK-MVE-NEXT: it mi
1255 ; CHECK-MVE-NEXT: movmi r1, #1
1256 ; CHECK-MVE-NEXT: cmp r1, #0
1257 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1258 ; CHECK-MVE-NEXT: cset r1, ne
1259 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1260 ; CHECK-MVE-NEXT: cmp r1, #0
1261 ; CHECK-MVE-NEXT: mov.w r1, #0
1262 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1263 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1264 ; CHECK-MVE-NEXT: it mi
1265 ; CHECK-MVE-NEXT: movmi r1, #1
1266 ; CHECK-MVE-NEXT: cmp r1, #0
1267 ; CHECK-MVE-NEXT: cset r1, ne
1268 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1269 ; CHECK-MVE-NEXT: cmp r1, #0
1270 ; CHECK-MVE-NEXT: mov.w r1, #0
1271 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1272 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1273 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1274 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1275 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1276 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1277 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1278 ; CHECK-MVE-NEXT: it mi
1279 ; CHECK-MVE-NEXT: movmi r1, #1
1280 ; CHECK-MVE-NEXT: cmp r1, #0
1281 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1282 ; CHECK-MVE-NEXT: cset r1, ne
1283 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1284 ; CHECK-MVE-NEXT: cmp r1, #0
1285 ; CHECK-MVE-NEXT: mov.w r1, #0
1286 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1287 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1288 ; CHECK-MVE-NEXT: it mi
1289 ; CHECK-MVE-NEXT: movmi r1, #1
1290 ; CHECK-MVE-NEXT: cmp r1, #0
1291 ; CHECK-MVE-NEXT: cset r1, ne
1292 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1293 ; CHECK-MVE-NEXT: cmp r1, #0
1294 ; CHECK-MVE-NEXT: mov.w r1, #0
1295 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1296 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1297 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1298 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1299 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1300 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1301 ; CHECK-MVE-NEXT: it mi
1302 ; CHECK-MVE-NEXT: movmi r1, #1
1303 ; CHECK-MVE-NEXT: cmp r1, #0
1304 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1305 ; CHECK-MVE-NEXT: cset r1, ne
1306 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1307 ; CHECK-MVE-NEXT: cmp r1, #0
1308 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1309 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1310 ; CHECK-MVE-NEXT: it mi
1311 ; CHECK-MVE-NEXT: movmi r0, #1
1312 ; CHECK-MVE-NEXT: cmp r0, #0
1313 ; CHECK-MVE-NEXT: cset r0, ne
1314 ; CHECK-MVE-NEXT: cmp r0, #0
1315 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1316 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1317 ; CHECK-MVE-NEXT: vpop {d8, d9}
1318 ; CHECK-MVE-NEXT: bx lr
1320 ; CHECK-MVEFP-LABEL: vcmp_olt_v8f16:
1321 ; CHECK-MVEFP: @ %bb.0: @ %entry
1322 ; CHECK-MVEFP-NEXT: vcmp.f16 gt, q1, q0
1323 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1324 ; CHECK-MVEFP-NEXT: bx lr
1326 %c = fcmp olt <8 x half> %src, %src2
1327 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1331 define arm_aapcs_vfpcc <8 x half> @vcmp_ole_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1332 ; CHECK-MVE-LABEL: vcmp_ole_v8f16:
1333 ; CHECK-MVE: @ %bb.0: @ %entry
1334 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1335 ; CHECK-MVE-NEXT: vpush {d8, d9}
1336 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1337 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1338 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1339 ; CHECK-MVE-NEXT: movs r1, #0
1340 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1341 ; CHECK-MVE-NEXT: it ls
1342 ; CHECK-MVE-NEXT: movls r1, #1
1343 ; CHECK-MVE-NEXT: cmp r1, #0
1344 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1345 ; CHECK-MVE-NEXT: cset r1, ne
1346 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1347 ; CHECK-MVE-NEXT: cmp r1, #0
1348 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1349 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1350 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1351 ; CHECK-MVE-NEXT: mov.w r1, #0
1352 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1353 ; CHECK-MVE-NEXT: it ls
1354 ; CHECK-MVE-NEXT: movls r1, #1
1355 ; CHECK-MVE-NEXT: cmp r1, #0
1356 ; CHECK-MVE-NEXT: cset r1, ne
1357 ; CHECK-MVE-NEXT: movs r0, #0
1358 ; CHECK-MVE-NEXT: cmp r1, #0
1359 ; CHECK-MVE-NEXT: mov.w r1, #0
1360 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1361 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1362 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1363 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1364 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1365 ; CHECK-MVE-NEXT: it ls
1366 ; CHECK-MVE-NEXT: movls r1, #1
1367 ; CHECK-MVE-NEXT: cmp r1, #0
1368 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1369 ; CHECK-MVE-NEXT: cset r1, ne
1370 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1371 ; CHECK-MVE-NEXT: cmp r1, #0
1372 ; CHECK-MVE-NEXT: mov.w r1, #0
1373 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1374 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1375 ; CHECK-MVE-NEXT: it ls
1376 ; CHECK-MVE-NEXT: movls r1, #1
1377 ; CHECK-MVE-NEXT: cmp r1, #0
1378 ; CHECK-MVE-NEXT: cset r1, ne
1379 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1380 ; CHECK-MVE-NEXT: cmp r1, #0
1381 ; CHECK-MVE-NEXT: mov.w r1, #0
1382 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1383 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1384 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1385 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1386 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1387 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1388 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1389 ; CHECK-MVE-NEXT: it ls
1390 ; CHECK-MVE-NEXT: movls r1, #1
1391 ; CHECK-MVE-NEXT: cmp r1, #0
1392 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1393 ; CHECK-MVE-NEXT: cset r1, ne
1394 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1395 ; CHECK-MVE-NEXT: cmp r1, #0
1396 ; CHECK-MVE-NEXT: mov.w r1, #0
1397 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1398 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1399 ; CHECK-MVE-NEXT: it ls
1400 ; CHECK-MVE-NEXT: movls r1, #1
1401 ; CHECK-MVE-NEXT: cmp r1, #0
1402 ; CHECK-MVE-NEXT: cset r1, ne
1403 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1404 ; CHECK-MVE-NEXT: cmp r1, #0
1405 ; CHECK-MVE-NEXT: mov.w r1, #0
1406 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1407 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1408 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1409 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1410 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1411 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1412 ; CHECK-MVE-NEXT: it ls
1413 ; CHECK-MVE-NEXT: movls r1, #1
1414 ; CHECK-MVE-NEXT: cmp r1, #0
1415 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1416 ; CHECK-MVE-NEXT: cset r1, ne
1417 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1418 ; CHECK-MVE-NEXT: cmp r1, #0
1419 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1420 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1421 ; CHECK-MVE-NEXT: it ls
1422 ; CHECK-MVE-NEXT: movls r0, #1
1423 ; CHECK-MVE-NEXT: cmp r0, #0
1424 ; CHECK-MVE-NEXT: cset r0, ne
1425 ; CHECK-MVE-NEXT: cmp r0, #0
1426 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1427 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1428 ; CHECK-MVE-NEXT: vpop {d8, d9}
1429 ; CHECK-MVE-NEXT: bx lr
1431 ; CHECK-MVEFP-LABEL: vcmp_ole_v8f16:
1432 ; CHECK-MVEFP: @ %bb.0: @ %entry
1433 ; CHECK-MVEFP-NEXT: vcmp.f16 ge, q1, q0
1434 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1435 ; CHECK-MVEFP-NEXT: bx lr
1437 %c = fcmp ole <8 x half> %src, %src2
1438 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1442 define arm_aapcs_vfpcc <8 x half> @vcmp_ueq_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1443 ; CHECK-MVE-LABEL: vcmp_ueq_v8f16:
1444 ; CHECK-MVE: @ %bb.0: @ %entry
1445 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1446 ; CHECK-MVE-NEXT: vpush {d8, d9}
1447 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1448 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1449 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1450 ; CHECK-MVE-NEXT: movs r1, #0
1451 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1452 ; CHECK-MVE-NEXT: it eq
1453 ; CHECK-MVE-NEXT: moveq r1, #1
1454 ; CHECK-MVE-NEXT: it vs
1455 ; CHECK-MVE-NEXT: movvs r1, #1
1456 ; CHECK-MVE-NEXT: cmp r1, #0
1457 ; CHECK-MVE-NEXT: cset r1, ne
1458 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1459 ; CHECK-MVE-NEXT: cmp r1, #0
1460 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1461 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1462 ; CHECK-MVE-NEXT: mov.w r1, #0
1463 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1464 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1465 ; CHECK-MVE-NEXT: it eq
1466 ; CHECK-MVE-NEXT: moveq r1, #1
1467 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1468 ; CHECK-MVE-NEXT: it vs
1469 ; CHECK-MVE-NEXT: movvs r1, #1
1470 ; CHECK-MVE-NEXT: cmp r1, #0
1471 ; CHECK-MVE-NEXT: cset r1, ne
1472 ; CHECK-MVE-NEXT: movs r0, #0
1473 ; CHECK-MVE-NEXT: cmp r1, #0
1474 ; CHECK-MVE-NEXT: mov.w r1, #0
1475 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1476 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1477 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1478 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1479 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1480 ; CHECK-MVE-NEXT: it eq
1481 ; CHECK-MVE-NEXT: moveq r1, #1
1482 ; CHECK-MVE-NEXT: it vs
1483 ; CHECK-MVE-NEXT: movvs r1, #1
1484 ; CHECK-MVE-NEXT: cmp r1, #0
1485 ; CHECK-MVE-NEXT: cset r1, ne
1486 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1487 ; CHECK-MVE-NEXT: cmp r1, #0
1488 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1489 ; CHECK-MVE-NEXT: mov.w r1, #0
1490 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1491 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1492 ; CHECK-MVE-NEXT: it eq
1493 ; CHECK-MVE-NEXT: moveq r1, #1
1494 ; CHECK-MVE-NEXT: it vs
1495 ; CHECK-MVE-NEXT: movvs r1, #1
1496 ; CHECK-MVE-NEXT: cmp r1, #0
1497 ; CHECK-MVE-NEXT: cset r1, ne
1498 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1499 ; CHECK-MVE-NEXT: cmp r1, #0
1500 ; CHECK-MVE-NEXT: mov.w r1, #0
1501 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1502 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1503 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1504 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1505 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1506 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1507 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1508 ; CHECK-MVE-NEXT: it eq
1509 ; CHECK-MVE-NEXT: moveq r1, #1
1510 ; CHECK-MVE-NEXT: it vs
1511 ; CHECK-MVE-NEXT: movvs r1, #1
1512 ; CHECK-MVE-NEXT: cmp r1, #0
1513 ; CHECK-MVE-NEXT: cset r1, ne
1514 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1515 ; CHECK-MVE-NEXT: cmp r1, #0
1516 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1517 ; CHECK-MVE-NEXT: mov.w r1, #0
1518 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1519 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1520 ; CHECK-MVE-NEXT: it eq
1521 ; CHECK-MVE-NEXT: moveq r1, #1
1522 ; CHECK-MVE-NEXT: it vs
1523 ; CHECK-MVE-NEXT: movvs r1, #1
1524 ; CHECK-MVE-NEXT: cmp r1, #0
1525 ; CHECK-MVE-NEXT: cset r1, ne
1526 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1527 ; CHECK-MVE-NEXT: cmp r1, #0
1528 ; CHECK-MVE-NEXT: mov.w r1, #0
1529 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1530 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1531 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1532 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1533 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1534 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1535 ; CHECK-MVE-NEXT: it eq
1536 ; CHECK-MVE-NEXT: moveq r1, #1
1537 ; CHECK-MVE-NEXT: it vs
1538 ; CHECK-MVE-NEXT: movvs r1, #1
1539 ; CHECK-MVE-NEXT: cmp r1, #0
1540 ; CHECK-MVE-NEXT: cset r1, ne
1541 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1542 ; CHECK-MVE-NEXT: cmp r1, #0
1543 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1544 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1545 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1546 ; CHECK-MVE-NEXT: it eq
1547 ; CHECK-MVE-NEXT: moveq r0, #1
1548 ; CHECK-MVE-NEXT: it vs
1549 ; CHECK-MVE-NEXT: movvs r0, #1
1550 ; CHECK-MVE-NEXT: cmp r0, #0
1551 ; CHECK-MVE-NEXT: cset r0, ne
1552 ; CHECK-MVE-NEXT: cmp r0, #0
1553 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1554 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1555 ; CHECK-MVE-NEXT: vpop {d8, d9}
1556 ; CHECK-MVE-NEXT: bx lr
1558 ; CHECK-MVEFP-LABEL: vcmp_ueq_v8f16:
1559 ; CHECK-MVEFP: @ %bb.0: @ %entry
1560 ; CHECK-MVEFP-NEXT: vpt.f16 le, q1, q0
1561 ; CHECK-MVEFP-NEXT: vcmpt.f16 le, q0, q1
1562 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1563 ; CHECK-MVEFP-NEXT: bx lr
1565 %c = fcmp ueq <8 x half> %src, %src2
1566 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1570 define arm_aapcs_vfpcc <8 x half> @vcmp_une_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1571 ; CHECK-MVE-LABEL: vcmp_une_v8f16:
1572 ; CHECK-MVE: @ %bb.0: @ %entry
1573 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1574 ; CHECK-MVE-NEXT: vpush {d8, d9}
1575 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1576 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1577 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1578 ; CHECK-MVE-NEXT: movs r1, #0
1579 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1580 ; CHECK-MVE-NEXT: it ne
1581 ; CHECK-MVE-NEXT: movne r1, #1
1582 ; CHECK-MVE-NEXT: cmp r1, #0
1583 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1584 ; CHECK-MVE-NEXT: cset r1, ne
1585 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1586 ; CHECK-MVE-NEXT: cmp r1, #0
1587 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1588 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1589 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1590 ; CHECK-MVE-NEXT: mov.w r1, #0
1591 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1592 ; CHECK-MVE-NEXT: it ne
1593 ; CHECK-MVE-NEXT: movne r1, #1
1594 ; CHECK-MVE-NEXT: cmp r1, #0
1595 ; CHECK-MVE-NEXT: cset r1, ne
1596 ; CHECK-MVE-NEXT: movs r0, #0
1597 ; CHECK-MVE-NEXT: cmp r1, #0
1598 ; CHECK-MVE-NEXT: mov.w r1, #0
1599 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1600 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1601 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1602 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1603 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1604 ; CHECK-MVE-NEXT: it ne
1605 ; CHECK-MVE-NEXT: movne r1, #1
1606 ; CHECK-MVE-NEXT: cmp r1, #0
1607 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1608 ; CHECK-MVE-NEXT: cset r1, ne
1609 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1610 ; CHECK-MVE-NEXT: cmp r1, #0
1611 ; CHECK-MVE-NEXT: mov.w r1, #0
1612 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1613 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1614 ; CHECK-MVE-NEXT: it ne
1615 ; CHECK-MVE-NEXT: movne r1, #1
1616 ; CHECK-MVE-NEXT: cmp r1, #0
1617 ; CHECK-MVE-NEXT: cset r1, ne
1618 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1619 ; CHECK-MVE-NEXT: cmp r1, #0
1620 ; CHECK-MVE-NEXT: mov.w r1, #0
1621 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1622 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1623 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1624 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1625 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1626 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1627 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1628 ; CHECK-MVE-NEXT: it ne
1629 ; CHECK-MVE-NEXT: movne r1, #1
1630 ; CHECK-MVE-NEXT: cmp r1, #0
1631 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1632 ; CHECK-MVE-NEXT: cset r1, ne
1633 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1634 ; CHECK-MVE-NEXT: cmp r1, #0
1635 ; CHECK-MVE-NEXT: mov.w r1, #0
1636 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1637 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1638 ; CHECK-MVE-NEXT: it ne
1639 ; CHECK-MVE-NEXT: movne r1, #1
1640 ; CHECK-MVE-NEXT: cmp r1, #0
1641 ; CHECK-MVE-NEXT: cset r1, ne
1642 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1643 ; CHECK-MVE-NEXT: cmp r1, #0
1644 ; CHECK-MVE-NEXT: mov.w r1, #0
1645 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1646 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1647 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1648 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1649 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1650 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1651 ; CHECK-MVE-NEXT: it ne
1652 ; CHECK-MVE-NEXT: movne r1, #1
1653 ; CHECK-MVE-NEXT: cmp r1, #0
1654 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1655 ; CHECK-MVE-NEXT: cset r1, ne
1656 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1657 ; CHECK-MVE-NEXT: cmp r1, #0
1658 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1659 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1660 ; CHECK-MVE-NEXT: it ne
1661 ; CHECK-MVE-NEXT: movne r0, #1
1662 ; CHECK-MVE-NEXT: cmp r0, #0
1663 ; CHECK-MVE-NEXT: cset r0, ne
1664 ; CHECK-MVE-NEXT: cmp r0, #0
1665 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1666 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1667 ; CHECK-MVE-NEXT: vpop {d8, d9}
1668 ; CHECK-MVE-NEXT: bx lr
1670 ; CHECK-MVEFP-LABEL: vcmp_une_v8f16:
1671 ; CHECK-MVEFP: @ %bb.0: @ %entry
1672 ; CHECK-MVEFP-NEXT: vcmp.f16 ne, q0, q1
1673 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1674 ; CHECK-MVEFP-NEXT: bx lr
1676 %c = fcmp une <8 x half> %src, %src2
1677 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1681 define arm_aapcs_vfpcc <8 x half> @vcmp_ugt_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1682 ; CHECK-MVE-LABEL: vcmp_ugt_v8f16:
1683 ; CHECK-MVE: @ %bb.0: @ %entry
1684 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1685 ; CHECK-MVE-NEXT: vpush {d8, d9}
1686 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1687 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1688 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1689 ; CHECK-MVE-NEXT: movs r1, #0
1690 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1691 ; CHECK-MVE-NEXT: it hi
1692 ; CHECK-MVE-NEXT: movhi r1, #1
1693 ; CHECK-MVE-NEXT: cmp r1, #0
1694 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1695 ; CHECK-MVE-NEXT: cset r1, ne
1696 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1697 ; CHECK-MVE-NEXT: cmp r1, #0
1698 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1699 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1700 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1701 ; CHECK-MVE-NEXT: mov.w r1, #0
1702 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1703 ; CHECK-MVE-NEXT: it hi
1704 ; CHECK-MVE-NEXT: movhi r1, #1
1705 ; CHECK-MVE-NEXT: cmp r1, #0
1706 ; CHECK-MVE-NEXT: cset r1, ne
1707 ; CHECK-MVE-NEXT: movs r0, #0
1708 ; CHECK-MVE-NEXT: cmp r1, #0
1709 ; CHECK-MVE-NEXT: mov.w r1, #0
1710 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1711 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1712 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1713 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1714 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1715 ; CHECK-MVE-NEXT: it hi
1716 ; CHECK-MVE-NEXT: movhi r1, #1
1717 ; CHECK-MVE-NEXT: cmp r1, #0
1718 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1719 ; CHECK-MVE-NEXT: cset r1, ne
1720 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1721 ; CHECK-MVE-NEXT: cmp r1, #0
1722 ; CHECK-MVE-NEXT: mov.w r1, #0
1723 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1724 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1725 ; CHECK-MVE-NEXT: it hi
1726 ; CHECK-MVE-NEXT: movhi r1, #1
1727 ; CHECK-MVE-NEXT: cmp r1, #0
1728 ; CHECK-MVE-NEXT: cset r1, ne
1729 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1730 ; CHECK-MVE-NEXT: cmp r1, #0
1731 ; CHECK-MVE-NEXT: mov.w r1, #0
1732 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1733 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1734 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1735 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1736 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1737 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1738 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1739 ; CHECK-MVE-NEXT: it hi
1740 ; CHECK-MVE-NEXT: movhi r1, #1
1741 ; CHECK-MVE-NEXT: cmp r1, #0
1742 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1743 ; CHECK-MVE-NEXT: cset r1, ne
1744 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1745 ; CHECK-MVE-NEXT: cmp r1, #0
1746 ; CHECK-MVE-NEXT: mov.w r1, #0
1747 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1748 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1749 ; CHECK-MVE-NEXT: it hi
1750 ; CHECK-MVE-NEXT: movhi r1, #1
1751 ; CHECK-MVE-NEXT: cmp r1, #0
1752 ; CHECK-MVE-NEXT: cset r1, ne
1753 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1754 ; CHECK-MVE-NEXT: cmp r1, #0
1755 ; CHECK-MVE-NEXT: mov.w r1, #0
1756 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1757 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1758 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1759 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1760 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1761 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1762 ; CHECK-MVE-NEXT: it hi
1763 ; CHECK-MVE-NEXT: movhi r1, #1
1764 ; CHECK-MVE-NEXT: cmp r1, #0
1765 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1766 ; CHECK-MVE-NEXT: cset r1, ne
1767 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1768 ; CHECK-MVE-NEXT: cmp r1, #0
1769 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1770 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1771 ; CHECK-MVE-NEXT: it hi
1772 ; CHECK-MVE-NEXT: movhi r0, #1
1773 ; CHECK-MVE-NEXT: cmp r0, #0
1774 ; CHECK-MVE-NEXT: cset r0, ne
1775 ; CHECK-MVE-NEXT: cmp r0, #0
1776 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1777 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1778 ; CHECK-MVE-NEXT: vpop {d8, d9}
1779 ; CHECK-MVE-NEXT: bx lr
1781 ; CHECK-MVEFP-LABEL: vcmp_ugt_v8f16:
1782 ; CHECK-MVEFP: @ %bb.0: @ %entry
1783 ; CHECK-MVEFP-NEXT: vcmp.f16 lt, q1, q0
1784 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1785 ; CHECK-MVEFP-NEXT: bx lr
1787 %c = fcmp ugt <8 x half> %src, %src2
1788 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1792 define arm_aapcs_vfpcc <8 x half> @vcmp_uge_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1793 ; CHECK-MVE-LABEL: vcmp_uge_v8f16:
1794 ; CHECK-MVE: @ %bb.0: @ %entry
1795 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1796 ; CHECK-MVE-NEXT: vpush {d8, d9}
1797 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1798 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1799 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1800 ; CHECK-MVE-NEXT: movs r1, #0
1801 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1802 ; CHECK-MVE-NEXT: it pl
1803 ; CHECK-MVE-NEXT: movpl r1, #1
1804 ; CHECK-MVE-NEXT: cmp r1, #0
1805 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1806 ; CHECK-MVE-NEXT: cset r1, ne
1807 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1808 ; CHECK-MVE-NEXT: cmp r1, #0
1809 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1810 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1811 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1812 ; CHECK-MVE-NEXT: mov.w r1, #0
1813 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1814 ; CHECK-MVE-NEXT: it pl
1815 ; CHECK-MVE-NEXT: movpl r1, #1
1816 ; CHECK-MVE-NEXT: cmp r1, #0
1817 ; CHECK-MVE-NEXT: cset r1, ne
1818 ; CHECK-MVE-NEXT: movs r0, #0
1819 ; CHECK-MVE-NEXT: cmp r1, #0
1820 ; CHECK-MVE-NEXT: mov.w r1, #0
1821 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1822 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1823 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1824 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1825 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1826 ; CHECK-MVE-NEXT: it pl
1827 ; CHECK-MVE-NEXT: movpl r1, #1
1828 ; CHECK-MVE-NEXT: cmp r1, #0
1829 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1830 ; CHECK-MVE-NEXT: cset r1, ne
1831 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1832 ; CHECK-MVE-NEXT: cmp r1, #0
1833 ; CHECK-MVE-NEXT: mov.w r1, #0
1834 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1835 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1836 ; CHECK-MVE-NEXT: it pl
1837 ; CHECK-MVE-NEXT: movpl r1, #1
1838 ; CHECK-MVE-NEXT: cmp r1, #0
1839 ; CHECK-MVE-NEXT: cset r1, ne
1840 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1841 ; CHECK-MVE-NEXT: cmp r1, #0
1842 ; CHECK-MVE-NEXT: mov.w r1, #0
1843 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1844 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1845 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1846 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1847 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1848 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1849 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1850 ; CHECK-MVE-NEXT: it pl
1851 ; CHECK-MVE-NEXT: movpl r1, #1
1852 ; CHECK-MVE-NEXT: cmp r1, #0
1853 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1854 ; CHECK-MVE-NEXT: cset r1, ne
1855 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1856 ; CHECK-MVE-NEXT: cmp r1, #0
1857 ; CHECK-MVE-NEXT: mov.w r1, #0
1858 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1859 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1860 ; CHECK-MVE-NEXT: it pl
1861 ; CHECK-MVE-NEXT: movpl r1, #1
1862 ; CHECK-MVE-NEXT: cmp r1, #0
1863 ; CHECK-MVE-NEXT: cset r1, ne
1864 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1865 ; CHECK-MVE-NEXT: cmp r1, #0
1866 ; CHECK-MVE-NEXT: mov.w r1, #0
1867 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1868 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1869 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1870 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1871 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1872 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1873 ; CHECK-MVE-NEXT: it pl
1874 ; CHECK-MVE-NEXT: movpl r1, #1
1875 ; CHECK-MVE-NEXT: cmp r1, #0
1876 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1877 ; CHECK-MVE-NEXT: cset r1, ne
1878 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1879 ; CHECK-MVE-NEXT: cmp r1, #0
1880 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1881 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1882 ; CHECK-MVE-NEXT: it pl
1883 ; CHECK-MVE-NEXT: movpl r0, #1
1884 ; CHECK-MVE-NEXT: cmp r0, #0
1885 ; CHECK-MVE-NEXT: cset r0, ne
1886 ; CHECK-MVE-NEXT: cmp r0, #0
1887 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1888 ; CHECK-MVE-NEXT: vins.f16 s3, s4
1889 ; CHECK-MVE-NEXT: vpop {d8, d9}
1890 ; CHECK-MVE-NEXT: bx lr
1892 ; CHECK-MVEFP-LABEL: vcmp_uge_v8f16:
1893 ; CHECK-MVEFP: @ %bb.0: @ %entry
1894 ; CHECK-MVEFP-NEXT: vcmp.f16 le, q1, q0
1895 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
1896 ; CHECK-MVEFP-NEXT: bx lr
1898 %c = fcmp uge <8 x half> %src, %src2
1899 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
1903 define arm_aapcs_vfpcc <8 x half> @vcmp_ult_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
1904 ; CHECK-MVE-LABEL: vcmp_ult_v8f16:
1905 ; CHECK-MVE: @ %bb.0: @ %entry
1906 ; CHECK-MVE-NEXT: .vsave {d8, d9}
1907 ; CHECK-MVE-NEXT: vpush {d8, d9}
1908 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
1909 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
1910 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
1911 ; CHECK-MVE-NEXT: movs r1, #0
1912 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1913 ; CHECK-MVE-NEXT: it lt
1914 ; CHECK-MVE-NEXT: movlt r1, #1
1915 ; CHECK-MVE-NEXT: cmp r1, #0
1916 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
1917 ; CHECK-MVE-NEXT: cset r1, ne
1918 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
1919 ; CHECK-MVE-NEXT: cmp r1, #0
1920 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
1921 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
1922 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1923 ; CHECK-MVE-NEXT: mov.w r1, #0
1924 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
1925 ; CHECK-MVE-NEXT: it lt
1926 ; CHECK-MVE-NEXT: movlt r1, #1
1927 ; CHECK-MVE-NEXT: cmp r1, #0
1928 ; CHECK-MVE-NEXT: cset r1, ne
1929 ; CHECK-MVE-NEXT: movs r0, #0
1930 ; CHECK-MVE-NEXT: cmp r1, #0
1931 ; CHECK-MVE-NEXT: mov.w r1, #0
1932 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
1933 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
1934 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1935 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
1936 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1937 ; CHECK-MVE-NEXT: it lt
1938 ; CHECK-MVE-NEXT: movlt r1, #1
1939 ; CHECK-MVE-NEXT: cmp r1, #0
1940 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
1941 ; CHECK-MVE-NEXT: cset r1, ne
1942 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
1943 ; CHECK-MVE-NEXT: cmp r1, #0
1944 ; CHECK-MVE-NEXT: mov.w r1, #0
1945 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1946 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1947 ; CHECK-MVE-NEXT: it lt
1948 ; CHECK-MVE-NEXT: movlt r1, #1
1949 ; CHECK-MVE-NEXT: cmp r1, #0
1950 ; CHECK-MVE-NEXT: cset r1, ne
1951 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
1952 ; CHECK-MVE-NEXT: cmp r1, #0
1953 ; CHECK-MVE-NEXT: mov.w r1, #0
1954 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
1955 ; CHECK-MVE-NEXT: vins.f16 s0, s16
1956 ; CHECK-MVE-NEXT: vins.f16 s1, s4
1957 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
1958 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
1959 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
1960 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1961 ; CHECK-MVE-NEXT: it lt
1962 ; CHECK-MVE-NEXT: movlt r1, #1
1963 ; CHECK-MVE-NEXT: cmp r1, #0
1964 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
1965 ; CHECK-MVE-NEXT: cset r1, ne
1966 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
1967 ; CHECK-MVE-NEXT: cmp r1, #0
1968 ; CHECK-MVE-NEXT: mov.w r1, #0
1969 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
1970 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1971 ; CHECK-MVE-NEXT: it lt
1972 ; CHECK-MVE-NEXT: movlt r1, #1
1973 ; CHECK-MVE-NEXT: cmp r1, #0
1974 ; CHECK-MVE-NEXT: cset r1, ne
1975 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
1976 ; CHECK-MVE-NEXT: cmp r1, #0
1977 ; CHECK-MVE-NEXT: mov.w r1, #0
1978 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
1979 ; CHECK-MVE-NEXT: vins.f16 s2, s4
1980 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
1981 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
1982 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
1983 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1984 ; CHECK-MVE-NEXT: it lt
1985 ; CHECK-MVE-NEXT: movlt r1, #1
1986 ; CHECK-MVE-NEXT: cmp r1, #0
1987 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
1988 ; CHECK-MVE-NEXT: cset r1, ne
1989 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
1990 ; CHECK-MVE-NEXT: cmp r1, #0
1991 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
1992 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
1993 ; CHECK-MVE-NEXT: it lt
1994 ; CHECK-MVE-NEXT: movlt r0, #1
1995 ; CHECK-MVE-NEXT: cmp r0, #0
1996 ; CHECK-MVE-NEXT: cset r0, ne
1997 ; CHECK-MVE-NEXT: cmp r0, #0
1998 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
1999 ; CHECK-MVE-NEXT: vins.f16 s3, s4
2000 ; CHECK-MVE-NEXT: vpop {d8, d9}
2001 ; CHECK-MVE-NEXT: bx lr
2003 ; CHECK-MVEFP-LABEL: vcmp_ult_v8f16:
2004 ; CHECK-MVEFP: @ %bb.0: @ %entry
2005 ; CHECK-MVEFP-NEXT: vcmp.f16 lt, q0, q1
2006 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
2007 ; CHECK-MVEFP-NEXT: bx lr
2009 %c = fcmp ult <8 x half> %src, %src2
2010 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
2014 define arm_aapcs_vfpcc <8 x half> @vcmp_ule_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
2015 ; CHECK-MVE-LABEL: vcmp_ule_v8f16:
2016 ; CHECK-MVE: @ %bb.0: @ %entry
2017 ; CHECK-MVE-NEXT: .vsave {d8, d9}
2018 ; CHECK-MVE-NEXT: vpush {d8, d9}
2019 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
2020 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
2021 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
2022 ; CHECK-MVE-NEXT: movs r1, #0
2023 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2024 ; CHECK-MVE-NEXT: it le
2025 ; CHECK-MVE-NEXT: movle r1, #1
2026 ; CHECK-MVE-NEXT: cmp r1, #0
2027 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
2028 ; CHECK-MVE-NEXT: cset r1, ne
2029 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
2030 ; CHECK-MVE-NEXT: cmp r1, #0
2031 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
2032 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
2033 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2034 ; CHECK-MVE-NEXT: mov.w r1, #0
2035 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
2036 ; CHECK-MVE-NEXT: it le
2037 ; CHECK-MVE-NEXT: movle r1, #1
2038 ; CHECK-MVE-NEXT: cmp r1, #0
2039 ; CHECK-MVE-NEXT: cset r1, ne
2040 ; CHECK-MVE-NEXT: movs r0, #0
2041 ; CHECK-MVE-NEXT: cmp r1, #0
2042 ; CHECK-MVE-NEXT: mov.w r1, #0
2043 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
2044 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
2045 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
2046 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
2047 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2048 ; CHECK-MVE-NEXT: it le
2049 ; CHECK-MVE-NEXT: movle r1, #1
2050 ; CHECK-MVE-NEXT: cmp r1, #0
2051 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
2052 ; CHECK-MVE-NEXT: cset r1, ne
2053 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
2054 ; CHECK-MVE-NEXT: cmp r1, #0
2055 ; CHECK-MVE-NEXT: mov.w r1, #0
2056 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
2057 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2058 ; CHECK-MVE-NEXT: it le
2059 ; CHECK-MVE-NEXT: movle r1, #1
2060 ; CHECK-MVE-NEXT: cmp r1, #0
2061 ; CHECK-MVE-NEXT: cset r1, ne
2062 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
2063 ; CHECK-MVE-NEXT: cmp r1, #0
2064 ; CHECK-MVE-NEXT: mov.w r1, #0
2065 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
2066 ; CHECK-MVE-NEXT: vins.f16 s0, s16
2067 ; CHECK-MVE-NEXT: vins.f16 s1, s4
2068 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
2069 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
2070 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
2071 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2072 ; CHECK-MVE-NEXT: it le
2073 ; CHECK-MVE-NEXT: movle r1, #1
2074 ; CHECK-MVE-NEXT: cmp r1, #0
2075 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
2076 ; CHECK-MVE-NEXT: cset r1, ne
2077 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
2078 ; CHECK-MVE-NEXT: cmp r1, #0
2079 ; CHECK-MVE-NEXT: mov.w r1, #0
2080 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
2081 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2082 ; CHECK-MVE-NEXT: it le
2083 ; CHECK-MVE-NEXT: movle r1, #1
2084 ; CHECK-MVE-NEXT: cmp r1, #0
2085 ; CHECK-MVE-NEXT: cset r1, ne
2086 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
2087 ; CHECK-MVE-NEXT: cmp r1, #0
2088 ; CHECK-MVE-NEXT: mov.w r1, #0
2089 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
2090 ; CHECK-MVE-NEXT: vins.f16 s2, s4
2091 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
2092 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
2093 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
2094 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2095 ; CHECK-MVE-NEXT: it le
2096 ; CHECK-MVE-NEXT: movle r1, #1
2097 ; CHECK-MVE-NEXT: cmp r1, #0
2098 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
2099 ; CHECK-MVE-NEXT: cset r1, ne
2100 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
2101 ; CHECK-MVE-NEXT: cmp r1, #0
2102 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
2103 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2104 ; CHECK-MVE-NEXT: it le
2105 ; CHECK-MVE-NEXT: movle r0, #1
2106 ; CHECK-MVE-NEXT: cmp r0, #0
2107 ; CHECK-MVE-NEXT: cset r0, ne
2108 ; CHECK-MVE-NEXT: cmp r0, #0
2109 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
2110 ; CHECK-MVE-NEXT: vins.f16 s3, s4
2111 ; CHECK-MVE-NEXT: vpop {d8, d9}
2112 ; CHECK-MVE-NEXT: bx lr
2114 ; CHECK-MVEFP-LABEL: vcmp_ule_v8f16:
2115 ; CHECK-MVEFP: @ %bb.0: @ %entry
2116 ; CHECK-MVEFP-NEXT: vcmp.f16 le, q0, q1
2117 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
2118 ; CHECK-MVEFP-NEXT: bx lr
2120 %c = fcmp ule <8 x half> %src, %src2
2121 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
2125 define arm_aapcs_vfpcc <8 x half> @vcmp_ord_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
2126 ; CHECK-MVE-LABEL: vcmp_ord_v8f16:
2127 ; CHECK-MVE: @ %bb.0: @ %entry
2128 ; CHECK-MVE-NEXT: .vsave {d8, d9}
2129 ; CHECK-MVE-NEXT: vpush {d8, d9}
2130 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
2131 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
2132 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
2133 ; CHECK-MVE-NEXT: movs r1, #0
2134 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2135 ; CHECK-MVE-NEXT: it vc
2136 ; CHECK-MVE-NEXT: movvc r1, #1
2137 ; CHECK-MVE-NEXT: cmp r1, #0
2138 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
2139 ; CHECK-MVE-NEXT: cset r1, ne
2140 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
2141 ; CHECK-MVE-NEXT: cmp r1, #0
2142 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
2143 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
2144 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2145 ; CHECK-MVE-NEXT: mov.w r1, #0
2146 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
2147 ; CHECK-MVE-NEXT: it vc
2148 ; CHECK-MVE-NEXT: movvc r1, #1
2149 ; CHECK-MVE-NEXT: cmp r1, #0
2150 ; CHECK-MVE-NEXT: cset r1, ne
2151 ; CHECK-MVE-NEXT: movs r0, #0
2152 ; CHECK-MVE-NEXT: cmp r1, #0
2153 ; CHECK-MVE-NEXT: mov.w r1, #0
2154 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
2155 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
2156 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
2157 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
2158 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2159 ; CHECK-MVE-NEXT: it vc
2160 ; CHECK-MVE-NEXT: movvc r1, #1
2161 ; CHECK-MVE-NEXT: cmp r1, #0
2162 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
2163 ; CHECK-MVE-NEXT: cset r1, ne
2164 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
2165 ; CHECK-MVE-NEXT: cmp r1, #0
2166 ; CHECK-MVE-NEXT: mov.w r1, #0
2167 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
2168 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2169 ; CHECK-MVE-NEXT: it vc
2170 ; CHECK-MVE-NEXT: movvc r1, #1
2171 ; CHECK-MVE-NEXT: cmp r1, #0
2172 ; CHECK-MVE-NEXT: cset r1, ne
2173 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
2174 ; CHECK-MVE-NEXT: cmp r1, #0
2175 ; CHECK-MVE-NEXT: mov.w r1, #0
2176 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
2177 ; CHECK-MVE-NEXT: vins.f16 s0, s16
2178 ; CHECK-MVE-NEXT: vins.f16 s1, s4
2179 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
2180 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
2181 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
2182 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2183 ; CHECK-MVE-NEXT: it vc
2184 ; CHECK-MVE-NEXT: movvc r1, #1
2185 ; CHECK-MVE-NEXT: cmp r1, #0
2186 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
2187 ; CHECK-MVE-NEXT: cset r1, ne
2188 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
2189 ; CHECK-MVE-NEXT: cmp r1, #0
2190 ; CHECK-MVE-NEXT: mov.w r1, #0
2191 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
2192 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2193 ; CHECK-MVE-NEXT: it vc
2194 ; CHECK-MVE-NEXT: movvc r1, #1
2195 ; CHECK-MVE-NEXT: cmp r1, #0
2196 ; CHECK-MVE-NEXT: cset r1, ne
2197 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
2198 ; CHECK-MVE-NEXT: cmp r1, #0
2199 ; CHECK-MVE-NEXT: mov.w r1, #0
2200 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
2201 ; CHECK-MVE-NEXT: vins.f16 s2, s4
2202 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
2203 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
2204 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
2205 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2206 ; CHECK-MVE-NEXT: it vc
2207 ; CHECK-MVE-NEXT: movvc r1, #1
2208 ; CHECK-MVE-NEXT: cmp r1, #0
2209 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
2210 ; CHECK-MVE-NEXT: cset r1, ne
2211 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
2212 ; CHECK-MVE-NEXT: cmp r1, #0
2213 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
2214 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2215 ; CHECK-MVE-NEXT: it vc
2216 ; CHECK-MVE-NEXT: movvc r0, #1
2217 ; CHECK-MVE-NEXT: cmp r0, #0
2218 ; CHECK-MVE-NEXT: cset r0, ne
2219 ; CHECK-MVE-NEXT: cmp r0, #0
2220 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
2221 ; CHECK-MVE-NEXT: vins.f16 s3, s4
2222 ; CHECK-MVE-NEXT: vpop {d8, d9}
2223 ; CHECK-MVE-NEXT: bx lr
2225 ; CHECK-MVEFP-LABEL: vcmp_ord_v8f16:
2226 ; CHECK-MVEFP: @ %bb.0: @ %entry
2227 ; CHECK-MVEFP-NEXT: vpt.f16 le, q1, q0
2228 ; CHECK-MVEFP-NEXT: vcmpt.f16 lt, q0, q1
2229 ; CHECK-MVEFP-NEXT: vpsel q0, q3, q2
2230 ; CHECK-MVEFP-NEXT: bx lr
2232 %c = fcmp ord <8 x half> %src, %src2
2233 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b
2237 define arm_aapcs_vfpcc <8 x half> @vcmp_uno_v8f16(<8 x half> %src, <8 x half> %src2, <8 x half> %a, <8 x half> %b) {
2238 ; CHECK-MVE-LABEL: vcmp_uno_v8f16:
2239 ; CHECK-MVE: @ %bb.0: @ %entry
2240 ; CHECK-MVE-NEXT: .vsave {d8, d9}
2241 ; CHECK-MVE-NEXT: vpush {d8, d9}
2242 ; CHECK-MVE-NEXT: vmovx.f16 s16, s4
2243 ; CHECK-MVE-NEXT: vmovx.f16 s18, s0
2244 ; CHECK-MVE-NEXT: vcmp.f16 s18, s16
2245 ; CHECK-MVE-NEXT: movs r1, #0
2246 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2247 ; CHECK-MVE-NEXT: it vs
2248 ; CHECK-MVE-NEXT: movvs r1, #1
2249 ; CHECK-MVE-NEXT: cmp r1, #0
2250 ; CHECK-MVE-NEXT: vcmp.f16 s0, s4
2251 ; CHECK-MVE-NEXT: cset r1, ne
2252 ; CHECK-MVE-NEXT: vmovx.f16 s16, s8
2253 ; CHECK-MVE-NEXT: cmp r1, #0
2254 ; CHECK-MVE-NEXT: vmovx.f16 s18, s12
2255 ; CHECK-MVE-NEXT: vseleq.f16 s16, s18, s16
2256 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2257 ; CHECK-MVE-NEXT: mov.w r1, #0
2258 ; CHECK-MVE-NEXT: vmovx.f16 s4, s5
2259 ; CHECK-MVE-NEXT: it vs
2260 ; CHECK-MVE-NEXT: movvs r1, #1
2261 ; CHECK-MVE-NEXT: cmp r1, #0
2262 ; CHECK-MVE-NEXT: cset r1, ne
2263 ; CHECK-MVE-NEXT: movs r0, #0
2264 ; CHECK-MVE-NEXT: cmp r1, #0
2265 ; CHECK-MVE-NEXT: mov.w r1, #0
2266 ; CHECK-MVE-NEXT: vseleq.f16 s0, s12, s8
2267 ; CHECK-MVE-NEXT: vmovx.f16 s8, s1
2268 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
2269 ; CHECK-MVE-NEXT: vmovx.f16 s4, s9
2270 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2271 ; CHECK-MVE-NEXT: it vs
2272 ; CHECK-MVE-NEXT: movvs r1, #1
2273 ; CHECK-MVE-NEXT: cmp r1, #0
2274 ; CHECK-MVE-NEXT: vmovx.f16 s8, s13
2275 ; CHECK-MVE-NEXT: cset r1, ne
2276 ; CHECK-MVE-NEXT: vcmp.f16 s1, s5
2277 ; CHECK-MVE-NEXT: cmp r1, #0
2278 ; CHECK-MVE-NEXT: mov.w r1, #0
2279 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
2280 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2281 ; CHECK-MVE-NEXT: it vs
2282 ; CHECK-MVE-NEXT: movvs r1, #1
2283 ; CHECK-MVE-NEXT: cmp r1, #0
2284 ; CHECK-MVE-NEXT: cset r1, ne
2285 ; CHECK-MVE-NEXT: vmovx.f16 s8, s2
2286 ; CHECK-MVE-NEXT: cmp r1, #0
2287 ; CHECK-MVE-NEXT: mov.w r1, #0
2288 ; CHECK-MVE-NEXT: vseleq.f16 s1, s13, s9
2289 ; CHECK-MVE-NEXT: vins.f16 s0, s16
2290 ; CHECK-MVE-NEXT: vins.f16 s1, s4
2291 ; CHECK-MVE-NEXT: vmovx.f16 s4, s6
2292 ; CHECK-MVE-NEXT: vcmp.f16 s8, s4
2293 ; CHECK-MVE-NEXT: vmovx.f16 s4, s10
2294 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2295 ; CHECK-MVE-NEXT: it vs
2296 ; CHECK-MVE-NEXT: movvs r1, #1
2297 ; CHECK-MVE-NEXT: cmp r1, #0
2298 ; CHECK-MVE-NEXT: vcmp.f16 s2, s6
2299 ; CHECK-MVE-NEXT: cset r1, ne
2300 ; CHECK-MVE-NEXT: vmovx.f16 s8, s14
2301 ; CHECK-MVE-NEXT: cmp r1, #0
2302 ; CHECK-MVE-NEXT: mov.w r1, #0
2303 ; CHECK-MVE-NEXT: vseleq.f16 s4, s8, s4
2304 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2305 ; CHECK-MVE-NEXT: it vs
2306 ; CHECK-MVE-NEXT: movvs r1, #1
2307 ; CHECK-MVE-NEXT: cmp r1, #0
2308 ; CHECK-MVE-NEXT: cset r1, ne
2309 ; CHECK-MVE-NEXT: vmovx.f16 s6, s3
2310 ; CHECK-MVE-NEXT: cmp r1, #0
2311 ; CHECK-MVE-NEXT: mov.w r1, #0
2312 ; CHECK-MVE-NEXT: vseleq.f16 s2, s14, s10
2313 ; CHECK-MVE-NEXT: vins.f16 s2, s4
2314 ; CHECK-MVE-NEXT: vmovx.f16 s4, s7
2315 ; CHECK-MVE-NEXT: vcmp.f16 s6, s4
2316 ; CHECK-MVE-NEXT: vmovx.f16 s4, s11
2317 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2318 ; CHECK-MVE-NEXT: it vs
2319 ; CHECK-MVE-NEXT: movvs r1, #1
2320 ; CHECK-MVE-NEXT: cmp r1, #0
2321 ; CHECK-MVE-NEXT: vmovx.f16 s6, s15
2322 ; CHECK-MVE-NEXT: cset r1, ne
2323 ; CHECK-MVE-NEXT: vcmp.f16 s3, s7
2324 ; CHECK-MVE-NEXT: cmp r1, #0
2325 ; CHECK-MVE-NEXT: vseleq.f16 s4, s6, s4
2326 ; CHECK-MVE-NEXT: vmrs APSR_nzcv, fpscr
2327 ; CHECK-MVE-NEXT: it vs
2328 ; CHECK-MVE-NEXT: movvs r0, #1
2329 ; CHECK-MVE-NEXT: cmp r0, #0
2330 ; CHECK-MVE-NEXT: cset r0, ne
2331 ; CHECK-MVE-NEXT: cmp r0, #0
2332 ; CHECK-MVE-NEXT: vseleq.f16 s3, s15, s11
2333 ; CHECK-MVE-NEXT: vins.f16 s3, s4
2334 ; CHECK-MVE-NEXT: vpop {d8, d9}
2335 ; CHECK-MVE-NEXT: bx lr
2337 ; CHECK-MVEFP-LABEL: vcmp_uno_v8f16:
2338 ; CHECK-MVEFP: @ %bb.0: @ %entry
2339 ; CHECK-MVEFP-NEXT: vpt.f16 le, q1, q0
2340 ; CHECK-MVEFP-NEXT: vcmpt.f16 lt, q0, q1
2341 ; CHECK-MVEFP-NEXT: vpsel q0, q2, q3
2342 ; CHECK-MVEFP-NEXT: bx lr
2344 %c = fcmp uno <8 x half> %src, %src2
2345 %s = select <8 x i1> %c, <8 x half> %a, <8 x half> %b