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-prefixes=CHECK,CHECK-MVE
3 ; RUN: llc -mtriple=thumbv8.1m.main-none-none-eabi -mattr=+mve.fp -verify-machineinstrs %s -o - | FileCheck %s --check-prefixes=CHECK,CHECK-MVEFP
6 ; Float to signed 32-bit -- Vector size variation
9 declare <1 x i32> @llvm.fptoui.sat.v1f32.v1i32 (<1 x float>)
10 declare <2 x i32> @llvm.fptoui.sat.v2f32.v2i32 (<2 x float>)
11 declare <3 x i32> @llvm.fptoui.sat.v3f32.v3i32 (<3 x float>)
12 declare <4 x i32> @llvm.fptoui.sat.v4f32.v4i32 (<4 x float>)
13 declare <5 x i32> @llvm.fptoui.sat.v5f32.v5i32 (<5 x float>)
14 declare <6 x i32> @llvm.fptoui.sat.v6f32.v6i32 (<6 x float>)
15 declare <7 x i32> @llvm.fptoui.sat.v7f32.v7i32 (<7 x float>)
16 declare <8 x i32> @llvm.fptoui.sat.v8f32.v8i32 (<8 x float>)
18 define arm_aapcs_vfpcc <1 x i32> @test_unsigned_v1f32_v1i32(<1 x float> %f) {
19 ; CHECK-LABEL: test_unsigned_v1f32_v1i32:
21 ; CHECK-NEXT: vcvt.u32.f32 s0, s0
22 ; CHECK-NEXT: vmov r0, s0
24 %x = call <1 x i32> @llvm.fptoui.sat.v1f32.v1i32(<1 x float> %f)
28 define arm_aapcs_vfpcc <2 x i32> @test_unsigned_v2f32_v2i32(<2 x float> %f) {
29 ; CHECK-LABEL: test_unsigned_v2f32_v2i32:
31 ; CHECK-NEXT: .save {r4, r5, r7, lr}
32 ; CHECK-NEXT: push {r4, r5, r7, lr}
33 ; CHECK-NEXT: .vsave {d8, d9}
34 ; CHECK-NEXT: vpush {d8, d9}
35 ; CHECK-NEXT: vmov q4, q0
36 ; CHECK-NEXT: vmov r0, s17
37 ; CHECK-NEXT: bl __aeabi_f2ulz
38 ; CHECK-NEXT: mov r5, r0
39 ; CHECK-NEXT: vmov r0, s16
40 ; CHECK-NEXT: vldr s18, .LCPI1_0
41 ; CHECK-NEXT: vcmp.f32 s17, #0
42 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
44 ; CHECK-NEXT: movlt r5, #0
45 ; CHECK-NEXT: vcmp.f32 s17, s18
46 ; CHECK-NEXT: mov r4, r1
47 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
49 ; CHECK-NEXT: movgt.w r5, #-1
50 ; CHECK-NEXT: bl __aeabi_f2ulz
51 ; CHECK-NEXT: vcmp.f32 s16, #0
52 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
53 ; CHECK-NEXT: vcmp.f32 s16, s18
55 ; CHECK-NEXT: movlt r0, #0
56 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
57 ; CHECK-NEXT: vcmp.f32 s17, #0
59 ; CHECK-NEXT: movgt.w r0, #-1
60 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
61 ; CHECK-NEXT: vcmp.f32 s17, s18
63 ; CHECK-NEXT: movlt r4, #0
64 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
65 ; CHECK-NEXT: vcmp.f32 s16, #0
67 ; CHECK-NEXT: movgt r4, #0
68 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
70 ; CHECK-NEXT: movlt r1, #0
71 ; CHECK-NEXT: vcmp.f32 s16, s18
72 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
73 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
75 ; CHECK-NEXT: movgt r1, #0
76 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r4
77 ; CHECK-NEXT: vpop {d8, d9}
78 ; CHECK-NEXT: pop {r4, r5, r7, pc}
79 ; CHECK-NEXT: .p2align 2
80 ; CHECK-NEXT: @ %bb.1:
81 ; CHECK-NEXT: .LCPI1_0:
82 ; CHECK-NEXT: .long 0x4f7fffff @ float 4.29496704E+9
83 %x = call <2 x i32> @llvm.fptoui.sat.v2f32.v2i32(<2 x float> %f)
87 define arm_aapcs_vfpcc <3 x i32> @test_unsigned_v3f32_v3i32(<3 x float> %f) {
88 ; CHECK-MVE-LABEL: test_unsigned_v3f32_v3i32:
90 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
91 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
92 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s3
93 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s1
94 ; CHECK-MVE-NEXT: vmov r0, s2
95 ; CHECK-MVE-NEXT: vmov r1, s0
96 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
97 ; CHECK-MVE-NEXT: vmov r0, s4
98 ; CHECK-MVE-NEXT: vmov r1, s6
99 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
100 ; CHECK-MVE-NEXT: bx lr
102 ; CHECK-MVEFP-LABEL: test_unsigned_v3f32_v3i32:
103 ; CHECK-MVEFP: @ %bb.0:
104 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
105 ; CHECK-MVEFP-NEXT: bx lr
106 %x = call <3 x i32> @llvm.fptoui.sat.v3f32.v3i32(<3 x float> %f)
110 define arm_aapcs_vfpcc <4 x i32> @test_unsigned_v4f32_v4i32(<4 x float> %f) {
111 ; CHECK-MVE-LABEL: test_unsigned_v4f32_v4i32:
112 ; CHECK-MVE: @ %bb.0:
113 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
114 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
115 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s3
116 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s1
117 ; CHECK-MVE-NEXT: vmov r0, s2
118 ; CHECK-MVE-NEXT: vmov r1, s0
119 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
120 ; CHECK-MVE-NEXT: vmov r0, s4
121 ; CHECK-MVE-NEXT: vmov r1, s6
122 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
123 ; CHECK-MVE-NEXT: bx lr
125 ; CHECK-MVEFP-LABEL: test_unsigned_v4f32_v4i32:
126 ; CHECK-MVEFP: @ %bb.0:
127 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
128 ; CHECK-MVEFP-NEXT: bx lr
129 %x = call <4 x i32> @llvm.fptoui.sat.v4f32.v4i32(<4 x float> %f)
133 define arm_aapcs_vfpcc <5 x i32> @test_unsigned_v5f32_v5i32(<5 x float> %f) {
134 ; CHECK-MVE-LABEL: test_unsigned_v5f32_v5i32:
135 ; CHECK-MVE: @ %bb.0:
136 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
137 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
138 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s3
139 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s1
140 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
141 ; CHECK-MVE-NEXT: vmov r1, s2
142 ; CHECK-MVE-NEXT: vmov r2, s0
143 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r2, r1
144 ; CHECK-MVE-NEXT: vmov r1, s6
145 ; CHECK-MVE-NEXT: vmov r2, s8
146 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r2, r1
147 ; CHECK-MVE-NEXT: vstrw.32 q0, [r0]
148 ; CHECK-MVE-NEXT: vstr s4, [r0, #16]
149 ; CHECK-MVE-NEXT: bx lr
151 ; CHECK-MVEFP-LABEL: test_unsigned_v5f32_v5i32:
152 ; CHECK-MVEFP: @ %bb.0:
153 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q1, q1
154 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
155 ; CHECK-MVEFP-NEXT: vmov r1, s4
156 ; CHECK-MVEFP-NEXT: str r1, [r0, #16]
157 ; CHECK-MVEFP-NEXT: vstrw.32 q0, [r0]
158 ; CHECK-MVEFP-NEXT: bx lr
159 %x = call <5 x i32> @llvm.fptoui.sat.v5f32.v5i32(<5 x float> %f)
163 define arm_aapcs_vfpcc <6 x i32> @test_unsigned_v6f32_v6i32(<6 x float> %f) {
164 ; CHECK-MVE-LABEL: test_unsigned_v6f32_v6i32:
165 ; CHECK-MVE: @ %bb.0:
166 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
167 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
168 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s3
169 ; CHECK-MVE-NEXT: vcvt.u32.f32 s10, s1
170 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s5
171 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
172 ; CHECK-MVE-NEXT: vmov r1, s2
173 ; CHECK-MVE-NEXT: vmov r2, s0
174 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r2, r1
175 ; CHECK-MVE-NEXT: vmov r1, s8
176 ; CHECK-MVE-NEXT: vmov r2, s10
177 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r2, r1
178 ; CHECK-MVE-NEXT: vstr s6, [r0, #20]
179 ; CHECK-MVE-NEXT: vstrw.32 q0, [r0]
180 ; CHECK-MVE-NEXT: vstr s4, [r0, #16]
181 ; CHECK-MVE-NEXT: bx lr
183 ; CHECK-MVEFP-LABEL: test_unsigned_v6f32_v6i32:
184 ; CHECK-MVEFP: @ %bb.0:
185 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q1, q1
186 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
187 ; CHECK-MVEFP-NEXT: vmov.f32 s6, s5
188 ; CHECK-MVEFP-NEXT: vmov r2, s4
189 ; CHECK-MVEFP-NEXT: vmov r1, s6
190 ; CHECK-MVEFP-NEXT: strd r2, r1, [r0, #16]
191 ; CHECK-MVEFP-NEXT: vstrw.32 q0, [r0]
192 ; CHECK-MVEFP-NEXT: bx lr
193 %x = call <6 x i32> @llvm.fptoui.sat.v6f32.v6i32(<6 x float> %f)
197 define arm_aapcs_vfpcc <7 x i32> @test_unsigned_v7f32_v7i32(<7 x float> %f) {
198 ; CHECK-MVE-LABEL: test_unsigned_v7f32_v7i32:
199 ; CHECK-MVE: @ %bb.0:
200 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
201 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
202 ; CHECK-MVE-NEXT: vcvt.u32.f32 s10, s3
203 ; CHECK-MVE-NEXT: vcvt.u32.f32 s12, s1
204 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s5
205 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
206 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s6
207 ; CHECK-MVE-NEXT: vmov r1, s2
208 ; CHECK-MVE-NEXT: vmov r2, s0
209 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r2, r1
210 ; CHECK-MVE-NEXT: vmov r1, s10
211 ; CHECK-MVE-NEXT: vmov r2, s12
212 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r2, r1
213 ; CHECK-MVE-NEXT: vstr s8, [r0, #20]
214 ; CHECK-MVE-NEXT: vstr s4, [r0, #16]
215 ; CHECK-MVE-NEXT: vstrw.32 q0, [r0]
216 ; CHECK-MVE-NEXT: vstr s6, [r0, #24]
217 ; CHECK-MVE-NEXT: bx lr
219 ; CHECK-MVEFP-LABEL: test_unsigned_v7f32_v7i32:
220 ; CHECK-MVEFP: @ %bb.0:
221 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q1, q1
222 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
223 ; CHECK-MVEFP-NEXT: vmov.f32 s10, s5
224 ; CHECK-MVEFP-NEXT: vmov r2, s4
225 ; CHECK-MVEFP-NEXT: vmov r3, s6
226 ; CHECK-MVEFP-NEXT: vmov r1, s10
227 ; CHECK-MVEFP-NEXT: strd r2, r1, [r0, #16]
228 ; CHECK-MVEFP-NEXT: str r3, [r0, #24]
229 ; CHECK-MVEFP-NEXT: vstrw.32 q0, [r0]
230 ; CHECK-MVEFP-NEXT: bx lr
231 %x = call <7 x i32> @llvm.fptoui.sat.v7f32.v7i32(<7 x float> %f)
235 define arm_aapcs_vfpcc <8 x i32> @test_unsigned_v8f32_v8i32(<8 x float> %f) {
236 ; CHECK-MVE-LABEL: test_unsigned_v8f32_v8i32:
237 ; CHECK-MVE: @ %bb.0:
238 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
239 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
240 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s3
241 ; CHECK-MVE-NEXT: vcvt.u32.f32 s10, s1
242 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s6
243 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
244 ; CHECK-MVE-NEXT: vcvt.u32.f32 s12, s7
245 ; CHECK-MVE-NEXT: vcvt.u32.f32 s14, s5
246 ; CHECK-MVE-NEXT: vmov r0, s2
247 ; CHECK-MVE-NEXT: vmov r1, s0
248 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
249 ; CHECK-MVE-NEXT: vmov r0, s8
250 ; CHECK-MVE-NEXT: vmov r1, s10
251 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
252 ; CHECK-MVE-NEXT: vmov r0, s6
253 ; CHECK-MVE-NEXT: vmov r1, s4
254 ; CHECK-MVE-NEXT: vmov q1[2], q1[0], r1, r0
255 ; CHECK-MVE-NEXT: vmov r0, s12
256 ; CHECK-MVE-NEXT: vmov r1, s14
257 ; CHECK-MVE-NEXT: vmov q1[3], q1[1], r1, r0
258 ; CHECK-MVE-NEXT: bx lr
260 ; CHECK-MVEFP-LABEL: test_unsigned_v8f32_v8i32:
261 ; CHECK-MVEFP: @ %bb.0:
262 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
263 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q1, q1
264 ; CHECK-MVEFP-NEXT: bx lr
265 %x = call <8 x i32> @llvm.fptoui.sat.v8f32.v8i32(<8 x float> %f)
270 ; Double to signed 32-bit -- Vector size variation
273 declare <1 x i32> @llvm.fptoui.sat.v1f64.v1i32 (<1 x double>)
274 declare <2 x i32> @llvm.fptoui.sat.v2f64.v2i32 (<2 x double>)
275 declare <3 x i32> @llvm.fptoui.sat.v3f64.v3i32 (<3 x double>)
276 declare <4 x i32> @llvm.fptoui.sat.v4f64.v4i32 (<4 x double>)
277 declare <5 x i32> @llvm.fptoui.sat.v5f64.v5i32 (<5 x double>)
278 declare <6 x i32> @llvm.fptoui.sat.v6f64.v6i32 (<6 x double>)
280 define arm_aapcs_vfpcc <1 x i32> @test_unsigned_v1f64_v1i32(<1 x double> %f) {
281 ; CHECK-LABEL: test_unsigned_v1f64_v1i32:
283 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
284 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
285 ; CHECK-NEXT: .pad #4
286 ; CHECK-NEXT: sub sp, #4
287 ; CHECK-NEXT: vldr d1, .LCPI8_0
288 ; CHECK-NEXT: vmov r4, r5, d0
289 ; CHECK-NEXT: vmov r2, r3, d1
290 ; CHECK-NEXT: mov r0, r4
291 ; CHECK-NEXT: mov r1, r5
292 ; CHECK-NEXT: bl __aeabi_dcmpgt
293 ; CHECK-NEXT: vldr d0, .LCPI8_1
294 ; CHECK-NEXT: mov r6, r0
295 ; CHECK-NEXT: mov r0, r4
296 ; CHECK-NEXT: mov r1, r5
297 ; CHECK-NEXT: vmov r2, r3, d0
298 ; CHECK-NEXT: bl __aeabi_dcmpge
299 ; CHECK-NEXT: mov r7, r0
300 ; CHECK-NEXT: mov r0, r4
301 ; CHECK-NEXT: mov r1, r5
302 ; CHECK-NEXT: bl __aeabi_d2uiz
303 ; CHECK-NEXT: cmp r7, #0
304 ; CHECK-NEXT: csel r0, r0, r7, ne
305 ; CHECK-NEXT: cmp r6, #0
307 ; CHECK-NEXT: movne.w r0, #-1
308 ; CHECK-NEXT: add sp, #4
309 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
310 ; CHECK-NEXT: .p2align 3
311 ; CHECK-NEXT: @ %bb.1:
312 ; CHECK-NEXT: .LCPI8_0:
313 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
314 ; CHECK-NEXT: .long 1106247679
315 ; CHECK-NEXT: .LCPI8_1:
316 ; CHECK-NEXT: .long 0 @ double 0
317 ; CHECK-NEXT: .long 0
318 %x = call <1 x i32> @llvm.fptoui.sat.v1f64.v1i32(<1 x double> %f)
322 define arm_aapcs_vfpcc <2 x i32> @test_unsigned_v2f64_v2i32(<2 x double> %f) {
323 ; CHECK-LABEL: test_unsigned_v2f64_v2i32:
325 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
326 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
327 ; CHECK-NEXT: .pad #4
328 ; CHECK-NEXT: sub sp, #4
329 ; CHECK-NEXT: .vsave {d8, d9}
330 ; CHECK-NEXT: vpush {d8, d9}
331 ; CHECK-NEXT: .pad #16
332 ; CHECK-NEXT: sub sp, #16
333 ; CHECK-NEXT: vmov q4, q0
334 ; CHECK-NEXT: vldr d0, .LCPI9_0
335 ; CHECK-NEXT: vmov r6, r7, d9
336 ; CHECK-NEXT: vmov r2, r3, d0
337 ; CHECK-NEXT: mov r0, r6
338 ; CHECK-NEXT: mov r1, r7
339 ; CHECK-NEXT: strd r3, r2, [sp, #4] @ 8-byte Folded Spill
340 ; CHECK-NEXT: bl __aeabi_dcmpge
341 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
342 ; CHECK-NEXT: mov r0, r6
343 ; CHECK-NEXT: mov r1, r7
344 ; CHECK-NEXT: bl __aeabi_d2ulz
345 ; CHECK-NEXT: vldr d0, .LCPI9_1
346 ; CHECK-NEXT: mov r5, r0
347 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
348 ; CHECK-NEXT: mov r10, r1
349 ; CHECK-NEXT: vmov r9, r8, d0
350 ; CHECK-NEXT: mov r1, r7
351 ; CHECK-NEXT: clz r0, r0
352 ; CHECK-NEXT: vmov r11, r4, d8
353 ; CHECK-NEXT: lsrs r0, r0, #5
354 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
355 ; CHECK-NEXT: mov r0, r6
357 ; CHECK-NEXT: movne r5, #0
358 ; CHECK-NEXT: mov r2, r9
359 ; CHECK-NEXT: mov r3, r8
360 ; CHECK-NEXT: bl __aeabi_dcmpgt
361 ; CHECK-NEXT: mov r6, r0
362 ; CHECK-NEXT: cmp r0, #0
363 ; CHECK-NEXT: mov r0, r11
364 ; CHECK-NEXT: mov r1, r4
365 ; CHECK-NEXT: mov r2, r9
366 ; CHECK-NEXT: mov r3, r8
368 ; CHECK-NEXT: movne r6, #1
369 ; CHECK-NEXT: cmp r6, #0
371 ; CHECK-NEXT: movne.w r5, #-1
372 ; CHECK-NEXT: bl __aeabi_dcmpgt
373 ; CHECK-NEXT: mov r7, r0
374 ; CHECK-NEXT: cmp r0, #0
376 ; CHECK-NEXT: movne r7, #1
377 ; CHECK-NEXT: ldrd r3, r2, [sp, #4] @ 8-byte Folded Reload
378 ; CHECK-NEXT: mov r0, r11
379 ; CHECK-NEXT: mov r1, r4
380 ; CHECK-NEXT: mov r8, r4
381 ; CHECK-NEXT: bl __aeabi_dcmpge
382 ; CHECK-NEXT: clz r0, r0
383 ; CHECK-NEXT: mov r1, r8
384 ; CHECK-NEXT: lsrs r4, r0, #5
385 ; CHECK-NEXT: mov r0, r11
386 ; CHECK-NEXT: bl __aeabi_d2ulz
387 ; CHECK-NEXT: cmp r4, #0
389 ; CHECK-NEXT: movne r0, #0
390 ; CHECK-NEXT: cmp r7, #0
392 ; CHECK-NEXT: movne.w r0, #-1
393 ; CHECK-NEXT: ldr r2, [sp, #12] @ 4-byte Reload
394 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
395 ; CHECK-NEXT: cmp r2, #0
397 ; CHECK-NEXT: movne.w r10, #0
398 ; CHECK-NEXT: cmp r6, #0
400 ; CHECK-NEXT: movne.w r10, #0
401 ; CHECK-NEXT: cmp r4, #0
403 ; CHECK-NEXT: movne r1, #0
404 ; CHECK-NEXT: cmp r7, #0
406 ; CHECK-NEXT: movne r1, #0
407 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r10
408 ; CHECK-NEXT: add sp, #16
409 ; CHECK-NEXT: vpop {d8, d9}
410 ; CHECK-NEXT: add sp, #4
411 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
412 ; CHECK-NEXT: .p2align 3
413 ; CHECK-NEXT: @ %bb.1:
414 ; CHECK-NEXT: .LCPI9_0:
415 ; CHECK-NEXT: .long 0 @ double 0
416 ; CHECK-NEXT: .long 0
417 ; CHECK-NEXT: .LCPI9_1:
418 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
419 ; CHECK-NEXT: .long 1106247679
420 %x = call <2 x i32> @llvm.fptoui.sat.v2f64.v2i32(<2 x double> %f)
424 define arm_aapcs_vfpcc <3 x i32> @test_unsigned_v3f64_v3i32(<3 x double> %f) {
425 ; CHECK-LABEL: test_unsigned_v3f64_v3i32:
427 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
428 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
429 ; CHECK-NEXT: .pad #4
430 ; CHECK-NEXT: sub sp, #4
431 ; CHECK-NEXT: .vsave {d8, d9}
432 ; CHECK-NEXT: vpush {d8, d9}
433 ; CHECK-NEXT: .pad #24
434 ; CHECK-NEXT: sub sp, #24
435 ; CHECK-NEXT: vmov.f32 s18, s0
436 ; CHECK-NEXT: vmov.f32 s19, s1
437 ; CHECK-NEXT: vldr d0, .LCPI10_0
438 ; CHECK-NEXT: vmov r4, r5, d1
439 ; CHECK-NEXT: vmov r9, r7, d0
440 ; CHECK-NEXT: vmov.f32 s16, s4
441 ; CHECK-NEXT: vmov.f32 s17, s5
442 ; CHECK-NEXT: str.w r9, [sp, #8] @ 4-byte Spill
443 ; CHECK-NEXT: mov r0, r4
444 ; CHECK-NEXT: mov r1, r5
445 ; CHECK-NEXT: mov r2, r9
446 ; CHECK-NEXT: mov r3, r7
447 ; CHECK-NEXT: str r7, [sp, #12] @ 4-byte Spill
448 ; CHECK-NEXT: bl __aeabi_dcmpgt
449 ; CHECK-NEXT: vldr d0, .LCPI10_1
450 ; CHECK-NEXT: mov r1, r5
451 ; CHECK-NEXT: str r0, [sp, #20] @ 4-byte Spill
452 ; CHECK-NEXT: mov r0, r4
453 ; CHECK-NEXT: vmov r11, r3, d0
454 ; CHECK-NEXT: str r3, [sp, #16] @ 4-byte Spill
455 ; CHECK-NEXT: mov r2, r11
456 ; CHECK-NEXT: bl __aeabi_dcmpge
457 ; CHECK-NEXT: mov r6, r0
458 ; CHECK-NEXT: mov r0, r4
459 ; CHECK-NEXT: mov r1, r5
460 ; CHECK-NEXT: bl __aeabi_d2ulz
461 ; CHECK-NEXT: vmov r10, r8, d8
462 ; CHECK-NEXT: cmp r6, #0
463 ; CHECK-NEXT: ldr r1, [sp, #20] @ 4-byte Reload
464 ; CHECK-NEXT: csel r0, r0, r6, ne
465 ; CHECK-NEXT: mov r2, r9
466 ; CHECK-NEXT: mov r3, r7
467 ; CHECK-NEXT: cmp r1, #0
469 ; CHECK-NEXT: movne.w r0, #-1
470 ; CHECK-NEXT: str r0, [sp, #20] @ 4-byte Spill
471 ; CHECK-NEXT: vmov r5, r4, d9
472 ; CHECK-NEXT: mov r0, r10
473 ; CHECK-NEXT: mov r1, r8
474 ; CHECK-NEXT: bl __aeabi_dcmpgt
475 ; CHECK-NEXT: ldr r7, [sp, #16] @ 4-byte Reload
476 ; CHECK-NEXT: mov r1, r8
477 ; CHECK-NEXT: str r0, [sp, #4] @ 4-byte Spill
478 ; CHECK-NEXT: mov r0, r10
479 ; CHECK-NEXT: mov r2, r11
480 ; CHECK-NEXT: mov r3, r7
481 ; CHECK-NEXT: bl __aeabi_dcmpge
482 ; CHECK-NEXT: mov r9, r0
483 ; CHECK-NEXT: mov r0, r10
484 ; CHECK-NEXT: mov r1, r8
485 ; CHECK-NEXT: bl __aeabi_d2ulz
486 ; CHECK-NEXT: cmp.w r9, #0
487 ; CHECK-NEXT: mov r1, r4
488 ; CHECK-NEXT: csel r6, r0, r9, ne
489 ; CHECK-NEXT: ldr r0, [sp, #4] @ 4-byte Reload
490 ; CHECK-NEXT: cmp r0, #0
492 ; CHECK-NEXT: movne.w r6, #-1
493 ; CHECK-NEXT: ldrd r2, r3, [sp, #8] @ 8-byte Folded Reload
494 ; CHECK-NEXT: mov r0, r5
495 ; CHECK-NEXT: bl __aeabi_dcmpgt
496 ; CHECK-NEXT: mov r8, r0
497 ; CHECK-NEXT: mov r0, r5
498 ; CHECK-NEXT: mov r1, r4
499 ; CHECK-NEXT: mov r2, r11
500 ; CHECK-NEXT: mov r3, r7
501 ; CHECK-NEXT: bl __aeabi_dcmpge
502 ; CHECK-NEXT: mov r7, r0
503 ; CHECK-NEXT: mov r0, r5
504 ; CHECK-NEXT: mov r1, r4
505 ; CHECK-NEXT: bl __aeabi_d2ulz
506 ; CHECK-NEXT: cmp r7, #0
507 ; CHECK-NEXT: csel r0, r0, r7, ne
508 ; CHECK-NEXT: cmp.w r8, #0
510 ; CHECK-NEXT: movne.w r0, #-1
511 ; CHECK-NEXT: ldr r1, [sp, #20] @ 4-byte Reload
512 ; CHECK-NEXT: vmov.32 q0[1], r1
513 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r6
514 ; CHECK-NEXT: add sp, #24
515 ; CHECK-NEXT: vpop {d8, d9}
516 ; CHECK-NEXT: add sp, #4
517 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
518 ; CHECK-NEXT: .p2align 3
519 ; CHECK-NEXT: @ %bb.1:
520 ; CHECK-NEXT: .LCPI10_0:
521 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
522 ; CHECK-NEXT: .long 1106247679
523 ; CHECK-NEXT: .LCPI10_1:
524 ; CHECK-NEXT: .long 0 @ double 0
525 ; CHECK-NEXT: .long 0
526 %x = call <3 x i32> @llvm.fptoui.sat.v3f64.v3i32(<3 x double> %f)
530 define arm_aapcs_vfpcc <4 x i32> @test_unsigned_v4f64_v4i32(<4 x double> %f) {
531 ; CHECK-LABEL: test_unsigned_v4f64_v4i32:
533 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
534 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
535 ; CHECK-NEXT: .pad #4
536 ; CHECK-NEXT: sub sp, #4
537 ; CHECK-NEXT: .vsave {d8, d9, d10, d11}
538 ; CHECK-NEXT: vpush {d8, d9, d10, d11}
539 ; CHECK-NEXT: .pad #24
540 ; CHECK-NEXT: sub sp, #24
541 ; CHECK-NEXT: vmov q4, q0
542 ; CHECK-NEXT: vldr d0, .LCPI11_0
543 ; CHECK-NEXT: vmov q5, q1
544 ; CHECK-NEXT: vmov r7, r9, d0
545 ; CHECK-NEXT: vmov r4, r5, d10
546 ; CHECK-NEXT: str.w r9, [sp, #4] @ 4-byte Spill
547 ; CHECK-NEXT: mov r2, r7
548 ; CHECK-NEXT: mov r3, r9
549 ; CHECK-NEXT: mov r0, r4
550 ; CHECK-NEXT: mov r1, r5
551 ; CHECK-NEXT: bl __aeabi_dcmpgt
552 ; CHECK-NEXT: vldr d0, .LCPI11_1
553 ; CHECK-NEXT: mov r1, r5
554 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
555 ; CHECK-NEXT: mov r0, r4
556 ; CHECK-NEXT: vmov r2, r3, d0
557 ; CHECK-NEXT: strd r2, r3, [sp, #16] @ 8-byte Folded Spill
558 ; CHECK-NEXT: bl __aeabi_dcmpge
559 ; CHECK-NEXT: mov r6, r0
560 ; CHECK-NEXT: mov r0, r4
561 ; CHECK-NEXT: mov r1, r5
562 ; CHECK-NEXT: bl __aeabi_d2ulz
563 ; CHECK-NEXT: vmov r10, r8, d8
564 ; CHECK-NEXT: cmp r6, #0
565 ; CHECK-NEXT: ldr r1, [sp, #12] @ 4-byte Reload
566 ; CHECK-NEXT: csel r0, r0, r6, ne
567 ; CHECK-NEXT: mov r2, r7
568 ; CHECK-NEXT: mov r3, r9
569 ; CHECK-NEXT: cmp r1, #0
571 ; CHECK-NEXT: movne.w r0, #-1
572 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
573 ; CHECK-NEXT: vmov r11, r5, d11
574 ; CHECK-NEXT: mov r4, r7
575 ; CHECK-NEXT: str r7, [sp, #8] @ 4-byte Spill
576 ; CHECK-NEXT: mov r0, r10
577 ; CHECK-NEXT: mov r1, r8
578 ; CHECK-NEXT: bl __aeabi_dcmpgt
579 ; CHECK-NEXT: ldr r6, [sp, #16] @ 4-byte Reload
580 ; CHECK-NEXT: mov r1, r8
581 ; CHECK-NEXT: ldr r7, [sp, #20] @ 4-byte Reload
582 ; CHECK-NEXT: str r0, [sp] @ 4-byte Spill
583 ; CHECK-NEXT: mov r0, r10
584 ; CHECK-NEXT: mov r2, r6
585 ; CHECK-NEXT: mov r3, r7
586 ; CHECK-NEXT: bl __aeabi_dcmpge
587 ; CHECK-NEXT: mov r9, r0
588 ; CHECK-NEXT: mov r0, r10
589 ; CHECK-NEXT: mov r1, r8
590 ; CHECK-NEXT: bl __aeabi_d2ulz
591 ; CHECK-NEXT: cmp.w r9, #0
592 ; CHECK-NEXT: mov r1, r5
593 ; CHECK-NEXT: csel r8, r0, r9, ne
594 ; CHECK-NEXT: ldr r0, [sp] @ 4-byte Reload
595 ; CHECK-NEXT: mov r2, r4
596 ; CHECK-NEXT: cmp r0, #0
598 ; CHECK-NEXT: movne.w r8, #-1
599 ; CHECK-NEXT: ldr.w r10, [sp, #4] @ 4-byte Reload
600 ; CHECK-NEXT: mov r0, r11
601 ; CHECK-NEXT: mov r3, r10
602 ; CHECK-NEXT: bl __aeabi_dcmpgt
603 ; CHECK-NEXT: mov r9, r0
604 ; CHECK-NEXT: mov r0, r11
605 ; CHECK-NEXT: mov r1, r5
606 ; CHECK-NEXT: mov r2, r6
607 ; CHECK-NEXT: mov r3, r7
608 ; CHECK-NEXT: bl __aeabi_dcmpge
609 ; CHECK-NEXT: mov r7, r0
610 ; CHECK-NEXT: mov r0, r11
611 ; CHECK-NEXT: mov r1, r5
612 ; CHECK-NEXT: bl __aeabi_d2ulz
613 ; CHECK-NEXT: vmov r4, r5, d9
614 ; CHECK-NEXT: cmp r7, #0
615 ; CHECK-NEXT: csel r6, r0, r7, ne
616 ; CHECK-NEXT: cmp.w r9, #0
618 ; CHECK-NEXT: movne.w r6, #-1
619 ; CHECK-NEXT: ldr r2, [sp, #8] @ 4-byte Reload
620 ; CHECK-NEXT: mov r3, r10
621 ; CHECK-NEXT: mov r0, r4
622 ; CHECK-NEXT: mov r1, r5
623 ; CHECK-NEXT: bl __aeabi_dcmpgt
624 ; CHECK-NEXT: ldrd r2, r3, [sp, #16] @ 8-byte Folded Reload
625 ; CHECK-NEXT: mov r9, r0
626 ; CHECK-NEXT: mov r0, r4
627 ; CHECK-NEXT: mov r1, r5
628 ; CHECK-NEXT: bl __aeabi_dcmpge
629 ; CHECK-NEXT: mov r7, r0
630 ; CHECK-NEXT: mov r0, r4
631 ; CHECK-NEXT: mov r1, r5
632 ; CHECK-NEXT: bl __aeabi_d2ulz
633 ; CHECK-NEXT: cmp r7, #0
634 ; CHECK-NEXT: csel r0, r0, r7, ne
635 ; CHECK-NEXT: cmp.w r9, #0
637 ; CHECK-NEXT: movne.w r0, #-1
638 ; CHECK-NEXT: ldr r1, [sp, #12] @ 4-byte Reload
639 ; CHECK-NEXT: vmov q0[2], q0[0], r8, r1
640 ; CHECK-NEXT: vmov q0[3], q0[1], r0, r6
641 ; CHECK-NEXT: add sp, #24
642 ; CHECK-NEXT: vpop {d8, d9, d10, d11}
643 ; CHECK-NEXT: add sp, #4
644 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
645 ; CHECK-NEXT: .p2align 3
646 ; CHECK-NEXT: @ %bb.1:
647 ; CHECK-NEXT: .LCPI11_0:
648 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
649 ; CHECK-NEXT: .long 1106247679
650 ; CHECK-NEXT: .LCPI11_1:
651 ; CHECK-NEXT: .long 0 @ double 0
652 ; CHECK-NEXT: .long 0
653 %x = call <4 x i32> @llvm.fptoui.sat.v4f64.v4i32(<4 x double> %f)
657 define arm_aapcs_vfpcc <5 x i32> @test_unsigned_v5f64_v5i32(<5 x double> %f) {
658 ; CHECK-LABEL: test_unsigned_v5f64_v5i32:
660 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
661 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
662 ; CHECK-NEXT: .pad #4
663 ; CHECK-NEXT: sub sp, #4
664 ; CHECK-NEXT: .vsave {d8, d9, d10, d11}
665 ; CHECK-NEXT: vpush {d8, d9, d10, d11}
666 ; CHECK-NEXT: .pad #40
667 ; CHECK-NEXT: sub sp, #40
668 ; CHECK-NEXT: vmov.f32 s16, s0
669 ; CHECK-NEXT: mov r4, r0
670 ; CHECK-NEXT: vmov.f32 s17, s1
671 ; CHECK-NEXT: vldr d0, .LCPI12_0
672 ; CHECK-NEXT: vmov r5, r6, d4
673 ; CHECK-NEXT: str r0, [sp, #28] @ 4-byte Spill
674 ; CHECK-NEXT: vmov r2, r3, d0
675 ; CHECK-NEXT: vmov.f32 s20, s6
676 ; CHECK-NEXT: vmov.f32 s18, s4
677 ; CHECK-NEXT: vmov.f32 s22, s2
678 ; CHECK-NEXT: vmov.f32 s21, s7
679 ; CHECK-NEXT: vmov.f32 s19, s5
680 ; CHECK-NEXT: vmov.f32 s23, s3
681 ; CHECK-NEXT: mov r0, r5
682 ; CHECK-NEXT: mov r1, r6
683 ; CHECK-NEXT: strd r2, r3, [sp, #32] @ 8-byte Folded Spill
684 ; CHECK-NEXT: bl __aeabi_dcmpgt
685 ; CHECK-NEXT: vldr d0, .LCPI12_1
686 ; CHECK-NEXT: mov r10, r0
687 ; CHECK-NEXT: mov r0, r5
688 ; CHECK-NEXT: mov r1, r6
689 ; CHECK-NEXT: vmov r7, r3, d0
690 ; CHECK-NEXT: str r3, [sp, #8] @ 4-byte Spill
691 ; CHECK-NEXT: str r7, [sp, #4] @ 4-byte Spill
692 ; CHECK-NEXT: mov r2, r7
693 ; CHECK-NEXT: bl __aeabi_dcmpge
694 ; CHECK-NEXT: mov r11, r0
695 ; CHECK-NEXT: mov r0, r5
696 ; CHECK-NEXT: mov r1, r6
697 ; CHECK-NEXT: bl __aeabi_d2ulz
698 ; CHECK-NEXT: vmov r8, r1, d11
699 ; CHECK-NEXT: cmp.w r11, #0
700 ; CHECK-NEXT: vmov r6, r9, d10
701 ; CHECK-NEXT: csel r0, r0, r11, ne
702 ; CHECK-NEXT: cmp.w r10, #0
703 ; CHECK-NEXT: str r1, [sp, #12] @ 4-byte Spill
704 ; CHECK-NEXT: vmov r2, r1, d9
705 ; CHECK-NEXT: strd r2, r1, [sp, #16] @ 8-byte Folded Spill
707 ; CHECK-NEXT: movne.w r0, #-1
708 ; CHECK-NEXT: str r0, [r4, #16]
709 ; CHECK-NEXT: mov r0, r6
710 ; CHECK-NEXT: ldr r5, [sp, #32] @ 4-byte Reload
711 ; CHECK-NEXT: mov r1, r9
712 ; CHECK-NEXT: ldr.w r10, [sp, #36] @ 4-byte Reload
713 ; CHECK-NEXT: mov r2, r5
714 ; CHECK-NEXT: mov r3, r10
715 ; CHECK-NEXT: bl __aeabi_dcmpgt
716 ; CHECK-NEXT: mov r2, r7
717 ; CHECK-NEXT: ldr r7, [sp, #8] @ 4-byte Reload
718 ; CHECK-NEXT: mov r11, r0
719 ; CHECK-NEXT: mov r0, r6
720 ; CHECK-NEXT: mov r1, r9
721 ; CHECK-NEXT: mov r3, r7
722 ; CHECK-NEXT: bl __aeabi_dcmpge
723 ; CHECK-NEXT: mov r4, r0
724 ; CHECK-NEXT: mov r0, r6
725 ; CHECK-NEXT: mov r1, r9
726 ; CHECK-NEXT: bl __aeabi_d2ulz
727 ; CHECK-NEXT: cmp r4, #0
728 ; CHECK-NEXT: mov r2, r5
729 ; CHECK-NEXT: csel r0, r0, r4, ne
730 ; CHECK-NEXT: cmp.w r11, #0
732 ; CHECK-NEXT: movne.w r0, #-1
733 ; CHECK-NEXT: ldr r6, [sp, #12] @ 4-byte Reload
734 ; CHECK-NEXT: str r0, [sp, #24] @ 4-byte Spill
735 ; CHECK-NEXT: mov r0, r8
736 ; CHECK-NEXT: mov r3, r10
737 ; CHECK-NEXT: mov r11, r10
738 ; CHECK-NEXT: mov r1, r6
739 ; CHECK-NEXT: bl __aeabi_dcmpgt
740 ; CHECK-NEXT: ldr.w r10, [sp, #4] @ 4-byte Reload
741 ; CHECK-NEXT: mov r4, r0
742 ; CHECK-NEXT: mov r0, r8
743 ; CHECK-NEXT: mov r1, r6
744 ; CHECK-NEXT: mov r3, r7
745 ; CHECK-NEXT: mov r5, r6
746 ; CHECK-NEXT: mov r2, r10
747 ; CHECK-NEXT: mov r9, r7
748 ; CHECK-NEXT: bl __aeabi_dcmpge
749 ; CHECK-NEXT: mov r6, r0
750 ; CHECK-NEXT: mov r0, r8
751 ; CHECK-NEXT: mov r1, r5
752 ; CHECK-NEXT: bl __aeabi_d2ulz
753 ; CHECK-NEXT: cmp r6, #0
754 ; CHECK-NEXT: mov r3, r11
755 ; CHECK-NEXT: csel r0, r0, r6, ne
756 ; CHECK-NEXT: cmp r4, #0
758 ; CHECK-NEXT: movne.w r0, #-1
759 ; CHECK-NEXT: ldr r4, [sp, #20] @ 4-byte Reload
760 ; CHECK-NEXT: ldr.w r8, [sp, #32] @ 4-byte Reload
761 ; CHECK-NEXT: ldr r6, [sp, #16] @ 4-byte Reload
762 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
763 ; CHECK-NEXT: mov r1, r4
764 ; CHECK-NEXT: mov r2, r8
765 ; CHECK-NEXT: mov r0, r6
766 ; CHECK-NEXT: bl __aeabi_dcmpgt
767 ; CHECK-NEXT: mov r7, r0
768 ; CHECK-NEXT: mov r0, r6
769 ; CHECK-NEXT: mov r1, r4
770 ; CHECK-NEXT: mov r2, r10
771 ; CHECK-NEXT: mov r3, r9
772 ; CHECK-NEXT: mov r11, r10
773 ; CHECK-NEXT: bl __aeabi_dcmpge
774 ; CHECK-NEXT: mov r5, r0
775 ; CHECK-NEXT: mov r0, r6
776 ; CHECK-NEXT: mov r1, r4
777 ; CHECK-NEXT: bl __aeabi_d2ulz
778 ; CHECK-NEXT: cmp r5, #0
779 ; CHECK-NEXT: mov r2, r8
780 ; CHECK-NEXT: csel r4, r0, r5, ne
781 ; CHECK-NEXT: vmov r5, r6, d8
782 ; CHECK-NEXT: cmp r7, #0
784 ; CHECK-NEXT: movne.w r4, #-1
785 ; CHECK-NEXT: ldr r3, [sp, #36] @ 4-byte Reload
786 ; CHECK-NEXT: mov r0, r5
787 ; CHECK-NEXT: mov r1, r6
788 ; CHECK-NEXT: bl __aeabi_dcmpgt
789 ; CHECK-NEXT: mov r10, r0
790 ; CHECK-NEXT: mov r0, r5
791 ; CHECK-NEXT: mov r1, r6
792 ; CHECK-NEXT: mov r2, r11
793 ; CHECK-NEXT: mov r3, r9
794 ; CHECK-NEXT: bl __aeabi_dcmpge
795 ; CHECK-NEXT: mov r7, r0
796 ; CHECK-NEXT: mov r0, r5
797 ; CHECK-NEXT: mov r1, r6
798 ; CHECK-NEXT: bl __aeabi_d2ulz
799 ; CHECK-NEXT: cmp r7, #0
800 ; CHECK-NEXT: csel r0, r0, r7, ne
801 ; CHECK-NEXT: cmp.w r10, #0
803 ; CHECK-NEXT: movne.w r0, #-1
804 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r4
805 ; CHECK-NEXT: ldr r0, [sp, #24] @ 4-byte Reload
806 ; CHECK-NEXT: ldr r1, [sp, #12] @ 4-byte Reload
807 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r0
808 ; CHECK-NEXT: ldr r0, [sp, #28] @ 4-byte Reload
809 ; CHECK-NEXT: vstrw.32 q0, [r0]
810 ; CHECK-NEXT: add sp, #40
811 ; CHECK-NEXT: vpop {d8, d9, d10, d11}
812 ; CHECK-NEXT: add sp, #4
813 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
814 ; CHECK-NEXT: .p2align 3
815 ; CHECK-NEXT: @ %bb.1:
816 ; CHECK-NEXT: .LCPI12_0:
817 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
818 ; CHECK-NEXT: .long 1106247679
819 ; CHECK-NEXT: .LCPI12_1:
820 ; CHECK-NEXT: .long 0 @ double 0
821 ; CHECK-NEXT: .long 0
822 %x = call <5 x i32> @llvm.fptoui.sat.v5f64.v5i32(<5 x double> %f)
826 define arm_aapcs_vfpcc <6 x i32> @test_unsigned_v6f64_v6i32(<6 x double> %f) {
827 ; CHECK-LABEL: test_unsigned_v6f64_v6i32:
829 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
830 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
831 ; CHECK-NEXT: .pad #4
832 ; CHECK-NEXT: sub sp, #4
833 ; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12}
834 ; CHECK-NEXT: vpush {d8, d9, d10, d11, d12}
835 ; CHECK-NEXT: .pad #40
836 ; CHECK-NEXT: sub sp, #40
837 ; CHECK-NEXT: vmov.f32 s16, s0
838 ; CHECK-NEXT: str r0, [sp, #32] @ 4-byte Spill
839 ; CHECK-NEXT: vmov.f32 s17, s1
840 ; CHECK-NEXT: vldr d0, .LCPI13_0
841 ; CHECK-NEXT: vmov r5, r6, d5
842 ; CHECK-NEXT: vmov r11, r3, d0
843 ; CHECK-NEXT: vmov.f32 s22, s8
844 ; CHECK-NEXT: vmov.f32 s20, s6
845 ; CHECK-NEXT: vmov.f32 s18, s4
846 ; CHECK-NEXT: vmov.f32 s24, s2
847 ; CHECK-NEXT: vmov.f32 s23, s9
848 ; CHECK-NEXT: vmov.f32 s21, s7
849 ; CHECK-NEXT: vmov.f32 s19, s5
850 ; CHECK-NEXT: vmov.f32 s25, s3
851 ; CHECK-NEXT: str r3, [sp, #36] @ 4-byte Spill
852 ; CHECK-NEXT: mov r0, r5
853 ; CHECK-NEXT: mov r1, r6
854 ; CHECK-NEXT: mov r2, r11
855 ; CHECK-NEXT: str.w r11, [sp, #28] @ 4-byte Spill
856 ; CHECK-NEXT: bl __aeabi_dcmpgt
857 ; CHECK-NEXT: vldr d0, .LCPI13_1
858 ; CHECK-NEXT: mov r7, r0
859 ; CHECK-NEXT: mov r0, r5
860 ; CHECK-NEXT: mov r1, r6
861 ; CHECK-NEXT: vmov r4, r9, d0
862 ; CHECK-NEXT: str r4, [sp, #24] @ 4-byte Spill
863 ; CHECK-NEXT: mov r2, r4
864 ; CHECK-NEXT: mov r3, r9
865 ; CHECK-NEXT: bl __aeabi_dcmpge
866 ; CHECK-NEXT: mov r8, r0
867 ; CHECK-NEXT: mov r0, r5
868 ; CHECK-NEXT: mov r1, r6
869 ; CHECK-NEXT: bl __aeabi_d2ulz
870 ; CHECK-NEXT: vmov r10, r1, d10
871 ; CHECK-NEXT: cmp.w r8, #0
872 ; CHECK-NEXT: vmov r5, r6, d11
873 ; CHECK-NEXT: csel r0, r0, r8, ne
874 ; CHECK-NEXT: cmp r7, #0
875 ; CHECK-NEXT: str r1, [sp, #20] @ 4-byte Spill
876 ; CHECK-NEXT: vmov r2, r1, d12
877 ; CHECK-NEXT: strd r2, r1, [sp, #12] @ 8-byte Folded Spill
879 ; CHECK-NEXT: movne.w r0, #-1
880 ; CHECK-NEXT: ldr r7, [sp, #32] @ 4-byte Reload
881 ; CHECK-NEXT: mov r1, r6
882 ; CHECK-NEXT: mov r2, r11
883 ; CHECK-NEXT: str r0, [r7, #20]
884 ; CHECK-NEXT: mov r0, r5
885 ; CHECK-NEXT: ldr.w r8, [sp, #36] @ 4-byte Reload
886 ; CHECK-NEXT: mov r3, r8
887 ; CHECK-NEXT: bl __aeabi_dcmpgt
888 ; CHECK-NEXT: mov r11, r0
889 ; CHECK-NEXT: mov r0, r5
890 ; CHECK-NEXT: mov r1, r6
891 ; CHECK-NEXT: mov r2, r4
892 ; CHECK-NEXT: mov r3, r9
893 ; CHECK-NEXT: bl __aeabi_dcmpge
894 ; CHECK-NEXT: mov r4, r0
895 ; CHECK-NEXT: mov r0, r5
896 ; CHECK-NEXT: mov r1, r6
897 ; CHECK-NEXT: bl __aeabi_d2ulz
898 ; CHECK-NEXT: vmov r2, r1, d9
899 ; CHECK-NEXT: cmp r4, #0
900 ; CHECK-NEXT: csel r0, r0, r4, ne
901 ; CHECK-NEXT: cmp.w r11, #0
902 ; CHECK-NEXT: mov r3, r8
903 ; CHECK-NEXT: strd r2, r1, [sp, #4] @ 8-byte Folded Spill
905 ; CHECK-NEXT: movne.w r0, #-1
906 ; CHECK-NEXT: str r0, [r7, #16]
907 ; CHECK-NEXT: mov r0, r10
908 ; CHECK-NEXT: ldr r6, [sp, #20] @ 4-byte Reload
909 ; CHECK-NEXT: ldr.w r11, [sp, #28] @ 4-byte Reload
910 ; CHECK-NEXT: mov r1, r6
911 ; CHECK-NEXT: mov r2, r11
912 ; CHECK-NEXT: bl __aeabi_dcmpgt
913 ; CHECK-NEXT: ldr r5, [sp, #24] @ 4-byte Reload
914 ; CHECK-NEXT: mov r4, r0
915 ; CHECK-NEXT: mov r0, r10
916 ; CHECK-NEXT: mov r1, r6
917 ; CHECK-NEXT: mov r3, r9
918 ; CHECK-NEXT: mov r8, r9
919 ; CHECK-NEXT: mov r2, r5
920 ; CHECK-NEXT: bl __aeabi_dcmpge
921 ; CHECK-NEXT: mov r7, r0
922 ; CHECK-NEXT: mov r0, r10
923 ; CHECK-NEXT: mov r1, r6
924 ; CHECK-NEXT: bl __aeabi_d2ulz
925 ; CHECK-NEXT: cmp r7, #0
926 ; CHECK-NEXT: mov r2, r11
927 ; CHECK-NEXT: csel r0, r0, r7, ne
928 ; CHECK-NEXT: cmp r4, #0
930 ; CHECK-NEXT: movne.w r0, #-1
931 ; CHECK-NEXT: ldr r7, [sp, #16] @ 4-byte Reload
932 ; CHECK-NEXT: ldr r4, [sp, #36] @ 4-byte Reload
933 ; CHECK-NEXT: ldr.w r9, [sp, #12] @ 4-byte Reload
934 ; CHECK-NEXT: str r0, [sp, #20] @ 4-byte Spill
935 ; CHECK-NEXT: mov r1, r7
936 ; CHECK-NEXT: mov r3, r4
937 ; CHECK-NEXT: mov r0, r9
938 ; CHECK-NEXT: bl __aeabi_dcmpgt
939 ; CHECK-NEXT: str r0, [sp] @ 4-byte Spill
940 ; CHECK-NEXT: mov r0, r9
941 ; CHECK-NEXT: mov r1, r7
942 ; CHECK-NEXT: mov r2, r5
943 ; CHECK-NEXT: mov r3, r8
944 ; CHECK-NEXT: mov r6, r7
945 ; CHECK-NEXT: mov r10, r5
946 ; CHECK-NEXT: bl __aeabi_dcmpge
947 ; CHECK-NEXT: mov r7, r0
948 ; CHECK-NEXT: mov r0, r9
949 ; CHECK-NEXT: mov r1, r6
950 ; CHECK-NEXT: bl __aeabi_d2ulz
951 ; CHECK-NEXT: cmp r7, #0
952 ; CHECK-NEXT: mov r2, r11
953 ; CHECK-NEXT: csel r9, r0, r7, ne
954 ; CHECK-NEXT: ldr r0, [sp] @ 4-byte Reload
955 ; CHECK-NEXT: mov r3, r4
956 ; CHECK-NEXT: cmp r0, #0
958 ; CHECK-NEXT: movne.w r9, #-1
959 ; CHECK-NEXT: ldr r6, [sp, #4] @ 4-byte Reload
960 ; CHECK-NEXT: ldr r5, [sp, #8] @ 4-byte Reload
961 ; CHECK-NEXT: mov r0, r6
962 ; CHECK-NEXT: mov r1, r5
963 ; CHECK-NEXT: bl __aeabi_dcmpgt
964 ; CHECK-NEXT: mov r11, r0
965 ; CHECK-NEXT: mov r0, r6
966 ; CHECK-NEXT: mov r1, r5
967 ; CHECK-NEXT: mov r2, r10
968 ; CHECK-NEXT: mov r3, r8
969 ; CHECK-NEXT: bl __aeabi_dcmpge
970 ; CHECK-NEXT: mov r7, r0
971 ; CHECK-NEXT: mov r0, r6
972 ; CHECK-NEXT: mov r1, r5
973 ; CHECK-NEXT: bl __aeabi_d2ulz
974 ; CHECK-NEXT: vmov r5, r6, d8
975 ; CHECK-NEXT: cmp r7, #0
976 ; CHECK-NEXT: csel r4, r0, r7, ne
977 ; CHECK-NEXT: cmp.w r11, #0
979 ; CHECK-NEXT: movne.w r4, #-1
980 ; CHECK-NEXT: ldr r2, [sp, #28] @ 4-byte Reload
981 ; CHECK-NEXT: ldr r3, [sp, #36] @ 4-byte Reload
982 ; CHECK-NEXT: mov r0, r5
983 ; CHECK-NEXT: mov r1, r6
984 ; CHECK-NEXT: bl __aeabi_dcmpgt
985 ; CHECK-NEXT: ldr r2, [sp, #24] @ 4-byte Reload
986 ; CHECK-NEXT: mov r10, r0
987 ; CHECK-NEXT: mov r0, r5
988 ; CHECK-NEXT: mov r1, r6
989 ; CHECK-NEXT: mov r3, r8
990 ; CHECK-NEXT: bl __aeabi_dcmpge
991 ; CHECK-NEXT: mov r7, r0
992 ; CHECK-NEXT: mov r0, r5
993 ; CHECK-NEXT: mov r1, r6
994 ; CHECK-NEXT: bl __aeabi_d2ulz
995 ; CHECK-NEXT: cmp r7, #0
996 ; CHECK-NEXT: csel r0, r0, r7, ne
997 ; CHECK-NEXT: cmp.w r10, #0
999 ; CHECK-NEXT: movne.w r0, #-1
1000 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r4
1001 ; CHECK-NEXT: ldr r0, [sp, #20] @ 4-byte Reload
1002 ; CHECK-NEXT: vmov q0[3], q0[1], r9, r0
1003 ; CHECK-NEXT: ldr r0, [sp, #32] @ 4-byte Reload
1004 ; CHECK-NEXT: vstrw.32 q0, [r0]
1005 ; CHECK-NEXT: add sp, #40
1006 ; CHECK-NEXT: vpop {d8, d9, d10, d11, d12}
1007 ; CHECK-NEXT: add sp, #4
1008 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
1009 ; CHECK-NEXT: .p2align 3
1010 ; CHECK-NEXT: @ %bb.1:
1011 ; CHECK-NEXT: .LCPI13_0:
1012 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
1013 ; CHECK-NEXT: .long 1106247679
1014 ; CHECK-NEXT: .LCPI13_1:
1015 ; CHECK-NEXT: .long 0 @ double 0
1016 ; CHECK-NEXT: .long 0
1017 %x = call <6 x i32> @llvm.fptoui.sat.v6f64.v6i32(<6 x double> %f)
1022 ; FP16 to signed 32-bit -- Vector size variation
1025 declare <1 x i32> @llvm.fptoui.sat.v1f16.v1i32 (<1 x half>)
1026 declare <2 x i32> @llvm.fptoui.sat.v2f16.v2i32 (<2 x half>)
1027 declare <3 x i32> @llvm.fptoui.sat.v3f16.v3i32 (<3 x half>)
1028 declare <4 x i32> @llvm.fptoui.sat.v4f16.v4i32 (<4 x half>)
1029 declare <5 x i32> @llvm.fptoui.sat.v5f16.v5i32 (<5 x half>)
1030 declare <6 x i32> @llvm.fptoui.sat.v6f16.v6i32 (<6 x half>)
1031 declare <7 x i32> @llvm.fptoui.sat.v7f16.v7i32 (<7 x half>)
1032 declare <8 x i32> @llvm.fptoui.sat.v8f16.v8i32 (<8 x half>)
1034 define arm_aapcs_vfpcc <1 x i32> @test_unsigned_v1f16_v1i32(<1 x half> %f) {
1035 ; CHECK-LABEL: test_unsigned_v1f16_v1i32:
1037 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
1038 ; CHECK-NEXT: vmov r0, s0
1040 %x = call <1 x i32> @llvm.fptoui.sat.v1f16.v1i32(<1 x half> %f)
1044 define arm_aapcs_vfpcc <2 x i32> @test_unsigned_v2f16_v2i32(<2 x half> %f) {
1045 ; CHECK-LABEL: test_unsigned_v2f16_v2i32:
1047 ; CHECK-NEXT: .save {r4, r5, r7, lr}
1048 ; CHECK-NEXT: push {r4, r5, r7, lr}
1049 ; CHECK-NEXT: .vsave {d8, d9, d10}
1050 ; CHECK-NEXT: vpush {d8, d9, d10}
1051 ; CHECK-NEXT: vmov q4, q0
1052 ; CHECK-NEXT: vcvtt.f32.f16 s18, s16
1053 ; CHECK-NEXT: vmov r0, s18
1054 ; CHECK-NEXT: bl __aeabi_f2ulz
1055 ; CHECK-NEXT: vcvtb.f32.f16 s16, s16
1056 ; CHECK-NEXT: mov r5, r0
1057 ; CHECK-NEXT: vmov r0, s16
1058 ; CHECK-NEXT: vldr s20, .LCPI15_0
1059 ; CHECK-NEXT: vcmp.f32 s18, #0
1060 ; CHECK-NEXT: mov r4, r1
1061 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1063 ; CHECK-NEXT: movlt r5, #0
1064 ; CHECK-NEXT: vcmp.f32 s18, s20
1065 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1067 ; CHECK-NEXT: movgt.w r5, #-1
1068 ; CHECK-NEXT: bl __aeabi_f2ulz
1069 ; CHECK-NEXT: vcmp.f32 s16, #0
1070 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1071 ; CHECK-NEXT: vcmp.f32 s16, s20
1073 ; CHECK-NEXT: movlt r0, #0
1074 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1075 ; CHECK-NEXT: vcmp.f32 s18, #0
1077 ; CHECK-NEXT: movgt.w r0, #-1
1078 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1079 ; CHECK-NEXT: vcmp.f32 s18, s20
1081 ; CHECK-NEXT: movlt r4, #0
1082 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1083 ; CHECK-NEXT: vcmp.f32 s16, #0
1085 ; CHECK-NEXT: movgt r4, #0
1086 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1088 ; CHECK-NEXT: movlt r1, #0
1089 ; CHECK-NEXT: vcmp.f32 s16, s20
1090 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
1091 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1093 ; CHECK-NEXT: movgt r1, #0
1094 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r4
1095 ; CHECK-NEXT: vpop {d8, d9, d10}
1096 ; CHECK-NEXT: pop {r4, r5, r7, pc}
1097 ; CHECK-NEXT: .p2align 2
1098 ; CHECK-NEXT: @ %bb.1:
1099 ; CHECK-NEXT: .LCPI15_0:
1100 ; CHECK-NEXT: .long 0x4f7fffff @ float 4.29496704E+9
1101 %x = call <2 x i32> @llvm.fptoui.sat.v2f16.v2i32(<2 x half> %f)
1105 define arm_aapcs_vfpcc <3 x i32> @test_unsigned_v3f16_v3i32(<3 x half> %f) {
1106 ; CHECK-LABEL: test_unsigned_v3f16_v3i32:
1108 ; CHECK-NEXT: vcvt.u32.f16 s6, s0
1109 ; CHECK-NEXT: vcvt.u32.f16 s0, s1
1110 ; CHECK-NEXT: vcvt.u32.f16 s4, s2
1111 ; CHECK-NEXT: vmov r0, s0
1112 ; CHECK-NEXT: vmov.32 q0[1], r0
1113 ; CHECK-NEXT: vmov r0, s4
1114 ; CHECK-NEXT: vmov r1, s6
1115 ; CHECK-NEXT: vmov q0[2], q0[0], r1, r0
1117 %x = call <3 x i32> @llvm.fptoui.sat.v3f16.v3i32(<3 x half> %f)
1121 define arm_aapcs_vfpcc <4 x i32> @test_unsigned_v4f16_v4i32(<4 x half> %f) {
1122 ; CHECK-LABEL: test_unsigned_v4f16_v4i32:
1124 ; CHECK-NEXT: vmovx.f16 s2, s1
1125 ; CHECK-NEXT: vcvt.u32.f16 s4, s2
1126 ; CHECK-NEXT: vmovx.f16 s2, s0
1127 ; CHECK-NEXT: vcvt.u32.f16 s6, s2
1128 ; CHECK-NEXT: vcvt.u32.f16 s2, s1
1129 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
1130 ; CHECK-NEXT: vmov r0, s2
1131 ; CHECK-NEXT: vmov r1, s0
1132 ; CHECK-NEXT: vmov q0[2], q0[0], r1, r0
1133 ; CHECK-NEXT: vmov r0, s4
1134 ; CHECK-NEXT: vmov r1, s6
1135 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r0
1137 %x = call <4 x i32> @llvm.fptoui.sat.v4f16.v4i32(<4 x half> %f)
1141 define arm_aapcs_vfpcc <5 x i32> @test_unsigned_v5f16_v5i32(<5 x half> %f) {
1142 ; CHECK-LABEL: test_unsigned_v5f16_v5i32:
1144 ; CHECK-NEXT: vmovx.f16 s6, s0
1145 ; CHECK-NEXT: vmovx.f16 s4, s1
1146 ; CHECK-NEXT: vcvt.u32.f16 s8, s1
1147 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
1148 ; CHECK-NEXT: vcvt.u32.f16 s4, s4
1149 ; CHECK-NEXT: vcvt.u32.f16 s6, s6
1150 ; CHECK-NEXT: vmov r1, s8
1151 ; CHECK-NEXT: vcvt.u32.f16 s2, s2
1152 ; CHECK-NEXT: vmov r2, s0
1153 ; CHECK-NEXT: vmov q2[2], q2[0], r2, r1
1154 ; CHECK-NEXT: vmov r1, s4
1155 ; CHECK-NEXT: vmov r2, s6
1156 ; CHECK-NEXT: vmov q2[3], q2[1], r2, r1
1157 ; CHECK-NEXT: vmov r1, s2
1158 ; CHECK-NEXT: str r1, [r0, #16]
1159 ; CHECK-NEXT: vstrw.32 q2, [r0]
1161 %x = call <5 x i32> @llvm.fptoui.sat.v5f16.v5i32(<5 x half> %f)
1165 define arm_aapcs_vfpcc <6 x i32> @test_unsigned_v6f16_v6i32(<6 x half> %f) {
1166 ; CHECK-LABEL: test_unsigned_v6f16_v6i32:
1168 ; CHECK-NEXT: vmovx.f16 s8, s0
1169 ; CHECK-NEXT: vmovx.f16 s6, s1
1170 ; CHECK-NEXT: vcvt.u32.f16 s10, s1
1171 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
1172 ; CHECK-NEXT: vcvt.u32.f16 s4, s2
1173 ; CHECK-NEXT: vmovx.f16 s2, s2
1174 ; CHECK-NEXT: vcvt.u32.f16 s6, s6
1175 ; CHECK-NEXT: vcvt.u32.f16 s8, s8
1176 ; CHECK-NEXT: vmov r1, s10
1177 ; CHECK-NEXT: vcvt.u32.f16 s2, s2
1178 ; CHECK-NEXT: vmov r2, s0
1179 ; CHECK-NEXT: vmov q3[2], q3[0], r2, r1
1180 ; CHECK-NEXT: vmov r1, s6
1181 ; CHECK-NEXT: vmov r2, s8
1182 ; CHECK-NEXT: vmov q3[3], q3[1], r2, r1
1183 ; CHECK-NEXT: vmov r1, s2
1184 ; CHECK-NEXT: vmov r2, s4
1185 ; CHECK-NEXT: strd r2, r1, [r0, #16]
1186 ; CHECK-NEXT: vstrw.32 q3, [r0]
1188 %x = call <6 x i32> @llvm.fptoui.sat.v6f16.v6i32(<6 x half> %f)
1192 define arm_aapcs_vfpcc <7 x i32> @test_unsigned_v7f16_v7i32(<7 x half> %f) {
1193 ; CHECK-LABEL: test_unsigned_v7f16_v7i32:
1195 ; CHECK-NEXT: vmovx.f16 s10, s0
1196 ; CHECK-NEXT: vmovx.f16 s8, s1
1197 ; CHECK-NEXT: vcvt.u32.f16 s12, s1
1198 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
1199 ; CHECK-NEXT: vcvt.u32.f16 s4, s2
1200 ; CHECK-NEXT: vmovx.f16 s2, s2
1201 ; CHECK-NEXT: vcvt.u32.f16 s8, s8
1202 ; CHECK-NEXT: vcvt.u32.f16 s10, s10
1203 ; CHECK-NEXT: vmov r1, s12
1204 ; CHECK-NEXT: vcvt.u32.f16 s2, s2
1205 ; CHECK-NEXT: vmov r2, s0
1206 ; CHECK-NEXT: vcvt.u32.f16 s6, s3
1207 ; CHECK-NEXT: vmov q3[2], q3[0], r2, r1
1208 ; CHECK-NEXT: vmov r1, s8
1209 ; CHECK-NEXT: vmov r2, s10
1210 ; CHECK-NEXT: vmov q3[3], q3[1], r2, r1
1211 ; CHECK-NEXT: vmov r1, s2
1212 ; CHECK-NEXT: vmov r2, s4
1213 ; CHECK-NEXT: vmov r3, s6
1214 ; CHECK-NEXT: strd r2, r1, [r0, #16]
1215 ; CHECK-NEXT: str r3, [r0, #24]
1216 ; CHECK-NEXT: vstrw.32 q3, [r0]
1218 %x = call <7 x i32> @llvm.fptoui.sat.v7f16.v7i32(<7 x half> %f)
1222 define arm_aapcs_vfpcc <8 x i32> @test_unsigned_v8f16_v8i32(<8 x half> %f) {
1223 ; CHECK-LABEL: test_unsigned_v8f16_v8i32:
1225 ; CHECK-NEXT: vmovx.f16 s4, s3
1226 ; CHECK-NEXT: vmovx.f16 s6, s0
1227 ; CHECK-NEXT: vcvt.u32.f16 s8, s4
1228 ; CHECK-NEXT: vmovx.f16 s4, s2
1229 ; CHECK-NEXT: vcvt.u32.f16 s10, s4
1230 ; CHECK-NEXT: vmovx.f16 s4, s1
1231 ; CHECK-NEXT: vcvt.u32.f16 s14, s2
1232 ; CHECK-NEXT: vcvt.u32.f16 s2, s1
1233 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
1234 ; CHECK-NEXT: vcvt.u32.f16 s4, s4
1235 ; CHECK-NEXT: vcvt.u32.f16 s6, s6
1236 ; CHECK-NEXT: vmov r0, s2
1237 ; CHECK-NEXT: vmov r1, s0
1238 ; CHECK-NEXT: vcvt.u32.f16 s12, s3
1239 ; CHECK-NEXT: vmov q0[2], q0[0], r1, r0
1240 ; CHECK-NEXT: vmov r0, s4
1241 ; CHECK-NEXT: vmov r1, s6
1242 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r0
1243 ; CHECK-NEXT: vmov r0, s12
1244 ; CHECK-NEXT: vmov r1, s14
1245 ; CHECK-NEXT: vmov q1[2], q1[0], r1, r0
1246 ; CHECK-NEXT: vmov r0, s8
1247 ; CHECK-NEXT: vmov r1, s10
1248 ; CHECK-NEXT: vmov q1[3], q1[1], r1, r0
1250 %x = call <8 x i32> @llvm.fptoui.sat.v8f16.v8i32(<8 x half> %f)
1255 ; 2-Vector float to signed integer -- result size variation
1258 declare <4 x i1> @llvm.fptoui.sat.v4f32.v4i1 (<4 x float>)
1259 declare <4 x i8> @llvm.fptoui.sat.v4f32.v4i8 (<4 x float>)
1260 declare <4 x i13> @llvm.fptoui.sat.v4f32.v4i13 (<4 x float>)
1261 declare <4 x i16> @llvm.fptoui.sat.v4f32.v4i16 (<4 x float>)
1262 declare <4 x i19> @llvm.fptoui.sat.v4f32.v4i19 (<4 x float>)
1263 declare <4 x i50> @llvm.fptoui.sat.v4f32.v4i50 (<4 x float>)
1264 declare <4 x i64> @llvm.fptoui.sat.v4f32.v4i64 (<4 x float>)
1265 declare <4 x i100> @llvm.fptoui.sat.v4f32.v4i100(<4 x float>)
1266 declare <4 x i128> @llvm.fptoui.sat.v4f32.v4i128(<4 x float>)
1268 define arm_aapcs_vfpcc <4 x i1> @test_unsigned_v4f32_v4i1(<4 x float> %f) {
1269 ; CHECK-LABEL: test_unsigned_v4f32_v4i1:
1271 ; CHECK-NEXT: vldr s4, .LCPI22_0
1272 ; CHECK-NEXT: vmov.f32 s6, #1.000000e+00
1273 ; CHECK-NEXT: movs r1, #0
1274 ; CHECK-NEXT: vmaxnm.f32 s0, s0, s4
1275 ; CHECK-NEXT: vmaxnm.f32 s8, s3, s4
1276 ; CHECK-NEXT: vminnm.f32 s0, s0, s6
1277 ; CHECK-NEXT: vmaxnm.f32 s2, s2, s4
1278 ; CHECK-NEXT: vcvt.u32.f32 s0, s0
1279 ; CHECK-NEXT: vmaxnm.f32 s4, s1, s4
1280 ; CHECK-NEXT: vminnm.f32 s4, s4, s6
1281 ; CHECK-NEXT: vminnm.f32 s2, s2, s6
1282 ; CHECK-NEXT: vcvt.u32.f32 s4, s4
1283 ; CHECK-NEXT: vminnm.f32 s8, s8, s6
1284 ; CHECK-NEXT: vcvt.u32.f32 s2, s2
1285 ; CHECK-NEXT: vcvt.u32.f32 s8, s8
1286 ; CHECK-NEXT: vmov r2, s0
1287 ; CHECK-NEXT: and r2, r2, #1
1288 ; CHECK-NEXT: rsbs r2, r2, #0
1289 ; CHECK-NEXT: bfi r1, r2, #0, #1
1290 ; CHECK-NEXT: vmov r2, s4
1291 ; CHECK-NEXT: and r2, r2, #1
1292 ; CHECK-NEXT: rsbs r2, r2, #0
1293 ; CHECK-NEXT: bfi r1, r2, #1, #1
1294 ; CHECK-NEXT: vmov r2, s2
1295 ; CHECK-NEXT: and r2, r2, #1
1296 ; CHECK-NEXT: rsbs r2, r2, #0
1297 ; CHECK-NEXT: bfi r1, r2, #2, #1
1298 ; CHECK-NEXT: vmov r2, s8
1299 ; CHECK-NEXT: and r2, r2, #1
1300 ; CHECK-NEXT: rsbs r2, r2, #0
1301 ; CHECK-NEXT: bfi r1, r2, #3, #1
1302 ; CHECK-NEXT: strb r1, [r0]
1304 ; CHECK-NEXT: .p2align 2
1305 ; CHECK-NEXT: @ %bb.1:
1306 ; CHECK-NEXT: .LCPI22_0:
1307 ; CHECK-NEXT: .long 0x00000000 @ float 0
1308 %x = call <4 x i1> @llvm.fptoui.sat.v4f32.v4i1(<4 x float> %f)
1312 define arm_aapcs_vfpcc <4 x i8> @test_unsigned_v4f32_v4i8(<4 x float> %f) {
1313 ; CHECK-MVE-LABEL: test_unsigned_v4f32_v4i8:
1314 ; CHECK-MVE: @ %bb.0:
1315 ; CHECK-MVE-NEXT: vldr s4, .LCPI23_0
1316 ; CHECK-MVE-NEXT: vldr s6, .LCPI23_1
1317 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s4
1318 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s4
1319 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s3, s4
1320 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s6
1321 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s6
1322 ; CHECK-MVE-NEXT: vmaxnm.f32 s4, s1, s4
1323 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s6
1324 ; CHECK-MVE-NEXT: vminnm.f32 s4, s4, s6
1325 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
1326 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
1327 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
1328 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
1329 ; CHECK-MVE-NEXT: vmov r0, s2
1330 ; CHECK-MVE-NEXT: vmov r1, s0
1331 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
1332 ; CHECK-MVE-NEXT: vmov r0, s8
1333 ; CHECK-MVE-NEXT: vmov r1, s4
1334 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
1335 ; CHECK-MVE-NEXT: bx lr
1336 ; CHECK-MVE-NEXT: .p2align 2
1337 ; CHECK-MVE-NEXT: @ %bb.1:
1338 ; CHECK-MVE-NEXT: .LCPI23_0:
1339 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
1340 ; CHECK-MVE-NEXT: .LCPI23_1:
1341 ; CHECK-MVE-NEXT: .long 0x437f0000 @ float 255
1343 ; CHECK-MVEFP-LABEL: test_unsigned_v4f32_v4i8:
1344 ; CHECK-MVEFP: @ %bb.0:
1345 ; CHECK-MVEFP-NEXT: vmov.i32 q1, #0xff
1346 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
1347 ; CHECK-MVEFP-NEXT: vmin.u32 q0, q0, q1
1348 ; CHECK-MVEFP-NEXT: bx lr
1349 %x = call <4 x i8> @llvm.fptoui.sat.v4f32.v4i8(<4 x float> %f)
1353 define arm_aapcs_vfpcc <4 x i13> @test_unsigned_v4f32_v4i13(<4 x float> %f) {
1354 ; CHECK-MVE-LABEL: test_unsigned_v4f32_v4i13:
1355 ; CHECK-MVE: @ %bb.0:
1356 ; CHECK-MVE-NEXT: vldr s4, .LCPI24_0
1357 ; CHECK-MVE-NEXT: vldr s6, .LCPI24_1
1358 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s4
1359 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s4
1360 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s3, s4
1361 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s6
1362 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s6
1363 ; CHECK-MVE-NEXT: vmaxnm.f32 s4, s1, s4
1364 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s6
1365 ; CHECK-MVE-NEXT: vminnm.f32 s4, s4, s6
1366 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
1367 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
1368 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
1369 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
1370 ; CHECK-MVE-NEXT: vmov r0, s2
1371 ; CHECK-MVE-NEXT: vmov r1, s0
1372 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
1373 ; CHECK-MVE-NEXT: vmov r0, s8
1374 ; CHECK-MVE-NEXT: vmov r1, s4
1375 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
1376 ; CHECK-MVE-NEXT: bx lr
1377 ; CHECK-MVE-NEXT: .p2align 2
1378 ; CHECK-MVE-NEXT: @ %bb.1:
1379 ; CHECK-MVE-NEXT: .LCPI24_0:
1380 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
1381 ; CHECK-MVE-NEXT: .LCPI24_1:
1382 ; CHECK-MVE-NEXT: .long 0x45fff800 @ float 8191
1384 ; CHECK-MVEFP-LABEL: test_unsigned_v4f32_v4i13:
1385 ; CHECK-MVEFP: @ %bb.0:
1386 ; CHECK-MVEFP-NEXT: vmov.i32 q1, #0x1fff
1387 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
1388 ; CHECK-MVEFP-NEXT: vmin.u32 q0, q0, q1
1389 ; CHECK-MVEFP-NEXT: bx lr
1390 %x = call <4 x i13> @llvm.fptoui.sat.v4f32.v4i13(<4 x float> %f)
1394 define arm_aapcs_vfpcc <4 x i16> @test_unsigned_v4f32_v4i16(<4 x float> %f) {
1395 ; CHECK-MVE-LABEL: test_unsigned_v4f32_v4i16:
1396 ; CHECK-MVE: @ %bb.0:
1397 ; CHECK-MVE-NEXT: vldr s4, .LCPI25_0
1398 ; CHECK-MVE-NEXT: vldr s6, .LCPI25_1
1399 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s4
1400 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s4
1401 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s3, s4
1402 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s6
1403 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s6
1404 ; CHECK-MVE-NEXT: vmaxnm.f32 s4, s1, s4
1405 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s6
1406 ; CHECK-MVE-NEXT: vminnm.f32 s4, s4, s6
1407 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
1408 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
1409 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
1410 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
1411 ; CHECK-MVE-NEXT: vmov r0, s2
1412 ; CHECK-MVE-NEXT: vmov r1, s0
1413 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
1414 ; CHECK-MVE-NEXT: vmov r0, s8
1415 ; CHECK-MVE-NEXT: vmov r1, s4
1416 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
1417 ; CHECK-MVE-NEXT: bx lr
1418 ; CHECK-MVE-NEXT: .p2align 2
1419 ; CHECK-MVE-NEXT: @ %bb.1:
1420 ; CHECK-MVE-NEXT: .LCPI25_0:
1421 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
1422 ; CHECK-MVE-NEXT: .LCPI25_1:
1423 ; CHECK-MVE-NEXT: .long 0x477fff00 @ float 65535
1425 ; CHECK-MVEFP-LABEL: test_unsigned_v4f32_v4i16:
1426 ; CHECK-MVEFP: @ %bb.0:
1427 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
1428 ; CHECK-MVEFP-NEXT: vqmovnb.u32 q0, q0
1429 ; CHECK-MVEFP-NEXT: vmovlb.u16 q0, q0
1430 ; CHECK-MVEFP-NEXT: bx lr
1431 %x = call <4 x i16> @llvm.fptoui.sat.v4f32.v4i16(<4 x float> %f)
1435 define arm_aapcs_vfpcc <4 x i19> @test_unsigned_v4f32_v4i19(<4 x float> %f) {
1436 ; CHECK-MVE-LABEL: test_unsigned_v4f32_v4i19:
1437 ; CHECK-MVE: @ %bb.0:
1438 ; CHECK-MVE-NEXT: vldr s4, .LCPI26_0
1439 ; CHECK-MVE-NEXT: vldr s6, .LCPI26_1
1440 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s4
1441 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s4
1442 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s3, s4
1443 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s6
1444 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s6
1445 ; CHECK-MVE-NEXT: vmaxnm.f32 s4, s1, s4
1446 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s6
1447 ; CHECK-MVE-NEXT: vminnm.f32 s4, s4, s6
1448 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
1449 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
1450 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
1451 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s4
1452 ; CHECK-MVE-NEXT: vmov r0, s2
1453 ; CHECK-MVE-NEXT: vmov r1, s0
1454 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
1455 ; CHECK-MVE-NEXT: vmov r0, s8
1456 ; CHECK-MVE-NEXT: vmov r1, s4
1457 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
1458 ; CHECK-MVE-NEXT: bx lr
1459 ; CHECK-MVE-NEXT: .p2align 2
1460 ; CHECK-MVE-NEXT: @ %bb.1:
1461 ; CHECK-MVE-NEXT: .LCPI26_0:
1462 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
1463 ; CHECK-MVE-NEXT: .LCPI26_1:
1464 ; CHECK-MVE-NEXT: .long 0x48ffffe0 @ float 524287
1466 ; CHECK-MVEFP-LABEL: test_unsigned_v4f32_v4i19:
1467 ; CHECK-MVEFP: @ %bb.0:
1468 ; CHECK-MVEFP-NEXT: vmov.i32 q1, #0x7ffff
1469 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
1470 ; CHECK-MVEFP-NEXT: vmin.u32 q0, q0, q1
1471 ; CHECK-MVEFP-NEXT: bx lr
1472 %x = call <4 x i19> @llvm.fptoui.sat.v4f32.v4i19(<4 x float> %f)
1476 define arm_aapcs_vfpcc <4 x i32> @test_unsigned_v4f32_v4i32_duplicate(<4 x float> %f) {
1477 ; CHECK-MVE-LABEL: test_unsigned_v4f32_v4i32_duplicate:
1478 ; CHECK-MVE: @ %bb.0:
1479 ; CHECK-MVE-NEXT: vcvt.u32.f32 s2, s2
1480 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
1481 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s3
1482 ; CHECK-MVE-NEXT: vcvt.u32.f32 s6, s1
1483 ; CHECK-MVE-NEXT: vmov r0, s2
1484 ; CHECK-MVE-NEXT: vmov r1, s0
1485 ; CHECK-MVE-NEXT: vmov q0[2], q0[0], r1, r0
1486 ; CHECK-MVE-NEXT: vmov r0, s4
1487 ; CHECK-MVE-NEXT: vmov r1, s6
1488 ; CHECK-MVE-NEXT: vmov q0[3], q0[1], r1, r0
1489 ; CHECK-MVE-NEXT: bx lr
1491 ; CHECK-MVEFP-LABEL: test_unsigned_v4f32_v4i32_duplicate:
1492 ; CHECK-MVEFP: @ %bb.0:
1493 ; CHECK-MVEFP-NEXT: vcvt.u32.f32 q0, q0
1494 ; CHECK-MVEFP-NEXT: bx lr
1495 %x = call <4 x i32> @llvm.fptoui.sat.v4f32.v4i32(<4 x float> %f)
1499 define arm_aapcs_vfpcc <4 x i50> @test_unsigned_v4f32_v4i50(<4 x float> %f) {
1500 ; CHECK-LABEL: test_unsigned_v4f32_v4i50:
1502 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, lr}
1503 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, lr}
1504 ; CHECK-NEXT: .vsave {d8, d9, d10}
1505 ; CHECK-NEXT: vpush {d8, d9, d10}
1506 ; CHECK-NEXT: vmov q4, q0
1507 ; CHECK-NEXT: mov r8, r0
1508 ; CHECK-NEXT: vmov r0, s16
1509 ; CHECK-NEXT: bl __aeabi_f2ulz
1510 ; CHECK-NEXT: mov r6, r0
1511 ; CHECK-NEXT: vmov r0, s18
1512 ; CHECK-NEXT: vcmp.f32 s16, #0
1513 ; CHECK-NEXT: mov r9, r1
1514 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1515 ; CHECK-NEXT: vmov r4, s19
1516 ; CHECK-NEXT: vldr s20, .LCPI28_0
1518 ; CHECK-NEXT: movlt r6, #0
1519 ; CHECK-NEXT: bl __aeabi_f2ulz
1520 ; CHECK-NEXT: vcmp.f32 s18, #0
1521 ; CHECK-NEXT: mov r5, r1
1522 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1523 ; CHECK-NEXT: mov r10, r0
1524 ; CHECK-NEXT: mov r0, r4
1526 ; CHECK-NEXT: movlt r5, #0
1527 ; CHECK-NEXT: vcmp.f32 s18, s20
1528 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1529 ; CHECK-NEXT: itt gt
1530 ; CHECK-NEXT: movwgt r5, #65535
1531 ; CHECK-NEXT: movtgt r5, #3
1532 ; CHECK-NEXT: bl __aeabi_f2ulz
1533 ; CHECK-NEXT: mov r4, r0
1534 ; CHECK-NEXT: vmov r0, s17
1535 ; CHECK-NEXT: vcmp.f32 s19, #0
1536 ; CHECK-NEXT: mov r7, r1
1537 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1538 ; CHECK-NEXT: vcmp.f32 s19, s20
1540 ; CHECK-NEXT: movlt r7, #0
1541 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1542 ; CHECK-NEXT: vcmp.f32 s16, s20
1543 ; CHECK-NEXT: itt gt
1544 ; CHECK-NEXT: movwgt r7, #65535
1545 ; CHECK-NEXT: movtgt r7, #3
1546 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1547 ; CHECK-NEXT: vcmp.f32 s19, #0
1549 ; CHECK-NEXT: movgt.w r6, #-1
1550 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1551 ; CHECK-NEXT: vcmp.f32 s19, s20
1552 ; CHECK-NEXT: str.w r6, [r8]
1554 ; CHECK-NEXT: movlt r4, #0
1555 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1556 ; CHECK-NEXT: vcmp.f32 s18, #0
1557 ; CHECK-NEXT: mov r1, r7
1559 ; CHECK-NEXT: movgt.w r4, #-1
1560 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1562 ; CHECK-NEXT: movlt.w r10, #0
1563 ; CHECK-NEXT: vcmp.f32 s18, s20
1564 ; CHECK-NEXT: bfc r1, #18, #14
1565 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1567 ; CHECK-NEXT: movgt.w r10, #-1
1568 ; CHECK-NEXT: vcmp.f32 s16, #0
1569 ; CHECK-NEXT: bfc r5, #18, #14
1570 ; CHECK-NEXT: mov r6, r10
1571 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1572 ; CHECK-NEXT: lsll r4, r1, #22
1573 ; CHECK-NEXT: lsrl r6, r5, #28
1575 ; CHECK-NEXT: movlt.w r9, #0
1576 ; CHECK-NEXT: vcmp.f32 s16, s20
1577 ; CHECK-NEXT: orrs r1, r5
1578 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1579 ; CHECK-NEXT: itt gt
1580 ; CHECK-NEXT: movwgt r9, #65535
1581 ; CHECK-NEXT: movtgt r9, #3
1582 ; CHECK-NEXT: str.w r1, [r8, #20]
1583 ; CHECK-NEXT: bl __aeabi_f2ulz
1584 ; CHECK-NEXT: vcmp.f32 s17, #0
1585 ; CHECK-NEXT: orr.w r2, r6, r4
1586 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1588 ; CHECK-NEXT: movlt r1, #0
1589 ; CHECK-NEXT: vcmp.f32 s17, s20
1590 ; CHECK-NEXT: bfc r9, #18, #14
1591 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1592 ; CHECK-NEXT: itt gt
1593 ; CHECK-NEXT: movwgt r1, #65535
1594 ; CHECK-NEXT: movtgt r1, #3
1595 ; CHECK-NEXT: str.w r2, [r8, #16]
1596 ; CHECK-NEXT: lsrs r2, r7, #10
1597 ; CHECK-NEXT: vcmp.f32 s17, #0
1598 ; CHECK-NEXT: strb.w r2, [r8, #24]
1599 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1601 ; CHECK-NEXT: movlt r0, #0
1602 ; CHECK-NEXT: vcmp.f32 s17, s20
1603 ; CHECK-NEXT: bfc r1, #18, #14
1604 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1606 ; CHECK-NEXT: movgt.w r0, #-1
1607 ; CHECK-NEXT: mov r2, r0
1608 ; CHECK-NEXT: orr.w r0, r9, r0, lsl #18
1609 ; CHECK-NEXT: lsrl r2, r1, #14
1610 ; CHECK-NEXT: orr.w r1, r1, r10, lsl #4
1611 ; CHECK-NEXT: strd r2, r1, [r8, #8]
1612 ; CHECK-NEXT: str.w r0, [r8, #4]
1613 ; CHECK-NEXT: vpop {d8, d9, d10}
1614 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, pc}
1615 ; CHECK-NEXT: .p2align 2
1616 ; CHECK-NEXT: @ %bb.1:
1617 ; CHECK-NEXT: .LCPI28_0:
1618 ; CHECK-NEXT: .long 0x587fffff @ float 1.12589984E+15
1619 %x = call <4 x i50> @llvm.fptoui.sat.v4f32.v4i50(<4 x float> %f)
1623 define arm_aapcs_vfpcc <4 x i64> @test_unsigned_v4f32_v4i64(<4 x float> %f) {
1624 ; CHECK-LABEL: test_unsigned_v4f32_v4i64:
1626 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
1627 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
1628 ; CHECK-NEXT: .pad #4
1629 ; CHECK-NEXT: sub sp, #4
1630 ; CHECK-NEXT: .vsave {d8, d9, d10}
1631 ; CHECK-NEXT: vpush {d8, d9, d10}
1632 ; CHECK-NEXT: vmov q4, q0
1633 ; CHECK-NEXT: vmov r0, s19
1634 ; CHECK-NEXT: bl __aeabi_f2ulz
1635 ; CHECK-NEXT: mov r11, r0
1636 ; CHECK-NEXT: vmov r0, s18
1637 ; CHECK-NEXT: vldr s20, .LCPI29_0
1638 ; CHECK-NEXT: vcmp.f32 s19, #0
1639 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1641 ; CHECK-NEXT: movlt.w r11, #0
1642 ; CHECK-NEXT: vcmp.f32 s19, s20
1643 ; CHECK-NEXT: mov r10, r1
1644 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1645 ; CHECK-NEXT: vmov r9, s17
1646 ; CHECK-NEXT: vmov r8, s16
1648 ; CHECK-NEXT: movgt.w r11, #-1
1649 ; CHECK-NEXT: bl __aeabi_f2ulz
1650 ; CHECK-NEXT: vcmp.f32 s18, #0
1651 ; CHECK-NEXT: mov r7, r0
1652 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1653 ; CHECK-NEXT: vcmp.f32 s18, s20
1655 ; CHECK-NEXT: movlt r7, #0
1656 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1657 ; CHECK-NEXT: vcmp.f32 s19, #0
1659 ; CHECK-NEXT: movgt.w r7, #-1
1660 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1661 ; CHECK-NEXT: vcmp.f32 s19, s20
1663 ; CHECK-NEXT: movlt.w r10, #0
1664 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1665 ; CHECK-NEXT: mov r6, r1
1666 ; CHECK-NEXT: vcmp.f32 s18, #0
1668 ; CHECK-NEXT: movgt.w r10, #-1
1669 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1670 ; CHECK-NEXT: mov r0, r9
1672 ; CHECK-NEXT: movlt r6, #0
1673 ; CHECK-NEXT: vcmp.f32 s18, s20
1674 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1676 ; CHECK-NEXT: movgt.w r6, #-1
1677 ; CHECK-NEXT: bl __aeabi_f2ulz
1678 ; CHECK-NEXT: mov r5, r0
1679 ; CHECK-NEXT: vcmp.f32 s17, #0
1680 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1681 ; CHECK-NEXT: mov r0, r8
1683 ; CHECK-NEXT: movlt r5, #0
1684 ; CHECK-NEXT: vcmp.f32 s17, s20
1685 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1686 ; CHECK-NEXT: mov r4, r1
1688 ; CHECK-NEXT: movgt.w r5, #-1
1689 ; CHECK-NEXT: bl __aeabi_f2ulz
1690 ; CHECK-NEXT: vcmp.f32 s16, #0
1691 ; CHECK-NEXT: vmov q1[2], q1[0], r7, r11
1692 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1693 ; CHECK-NEXT: vcmp.f32 s16, s20
1695 ; CHECK-NEXT: movlt r0, #0
1696 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1697 ; CHECK-NEXT: vcmp.f32 s17, #0
1699 ; CHECK-NEXT: movgt.w r0, #-1
1700 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1701 ; CHECK-NEXT: vcmp.f32 s17, s20
1703 ; CHECK-NEXT: movlt r4, #0
1704 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1705 ; CHECK-NEXT: vcmp.f32 s16, #0
1707 ; CHECK-NEXT: movgt.w r4, #-1
1708 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1710 ; CHECK-NEXT: movlt r1, #0
1711 ; CHECK-NEXT: vcmp.f32 s16, s20
1712 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
1713 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1715 ; CHECK-NEXT: movgt.w r1, #-1
1716 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r4
1717 ; CHECK-NEXT: vmov q1[3], q1[1], r6, r10
1718 ; CHECK-NEXT: vpop {d8, d9, d10}
1719 ; CHECK-NEXT: add sp, #4
1720 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
1721 ; CHECK-NEXT: .p2align 2
1722 ; CHECK-NEXT: @ %bb.1:
1723 ; CHECK-NEXT: .LCPI29_0:
1724 ; CHECK-NEXT: .long 0x5f7fffff @ float 1.8446743E+19
1725 %x = call <4 x i64> @llvm.fptoui.sat.v4f32.v4i64(<4 x float> %f)
1729 define arm_aapcs_vfpcc <4 x i100> @test_unsigned_v4f32_v4i100(<4 x float> %f) {
1730 ; CHECK-LABEL: test_unsigned_v4f32_v4i100:
1732 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
1733 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
1734 ; CHECK-NEXT: .pad #4
1735 ; CHECK-NEXT: sub sp, #4
1736 ; CHECK-NEXT: .vsave {d8, d9, d10}
1737 ; CHECK-NEXT: vpush {d8, d9, d10}
1738 ; CHECK-NEXT: vmov q4, q0
1739 ; CHECK-NEXT: mov r8, r0
1740 ; CHECK-NEXT: vmov r0, s18
1741 ; CHECK-NEXT: bl __fixunssfti
1742 ; CHECK-NEXT: mov r9, r3
1743 ; CHECK-NEXT: vmov r3, s16
1744 ; CHECK-NEXT: vldr s20, .LCPI30_0
1745 ; CHECK-NEXT: vcmp.f32 s18, #0
1746 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1748 ; CHECK-NEXT: movlt r2, #0
1749 ; CHECK-NEXT: vcmp.f32 s18, s20
1750 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1751 ; CHECK-NEXT: vcmp.f32 s18, #0
1753 ; CHECK-NEXT: movgt.w r2, #-1
1754 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1755 ; CHECK-NEXT: vcmp.f32 s18, s20
1756 ; CHECK-NEXT: str.w r2, [r8, #33]
1758 ; CHECK-NEXT: movlt r1, #0
1759 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1760 ; CHECK-NEXT: vcmp.f32 s18, #0
1762 ; CHECK-NEXT: movgt.w r1, #-1
1763 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1764 ; CHECK-NEXT: str.w r1, [r8, #29]
1766 ; CHECK-NEXT: movlt r0, #0
1767 ; CHECK-NEXT: vcmp.f32 s18, s20
1768 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1770 ; CHECK-NEXT: movgt.w r0, #-1
1771 ; CHECK-NEXT: str.w r0, [r8, #25]
1772 ; CHECK-NEXT: vmov r7, s17
1773 ; CHECK-NEXT: vmov r4, s19
1774 ; CHECK-NEXT: mov r0, r3
1775 ; CHECK-NEXT: bl __fixunssfti
1776 ; CHECK-NEXT: vcmp.f32 s16, #0
1777 ; CHECK-NEXT: mov r10, r3
1778 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1779 ; CHECK-NEXT: vcmp.f32 s16, s20
1781 ; CHECK-NEXT: movlt r2, #0
1782 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1783 ; CHECK-NEXT: vcmp.f32 s16, #0
1785 ; CHECK-NEXT: movgt.w r2, #-1
1786 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1787 ; CHECK-NEXT: vcmp.f32 s16, s20
1788 ; CHECK-NEXT: str.w r2, [r8, #8]
1790 ; CHECK-NEXT: movlt r1, #0
1791 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1792 ; CHECK-NEXT: vcmp.f32 s16, #0
1794 ; CHECK-NEXT: movgt.w r1, #-1
1795 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1796 ; CHECK-NEXT: str.w r1, [r8, #4]
1798 ; CHECK-NEXT: movlt r0, #0
1799 ; CHECK-NEXT: vcmp.f32 s16, s20
1800 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1802 ; CHECK-NEXT: movgt.w r0, #-1
1803 ; CHECK-NEXT: str.w r0, [r8]
1804 ; CHECK-NEXT: mov r0, r4
1805 ; CHECK-NEXT: bl __fixunssfti
1806 ; CHECK-NEXT: vcmp.f32 s19, #0
1807 ; CHECK-NEXT: mov r4, r0
1808 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1809 ; CHECK-NEXT: vcmp.f32 s19, s20
1811 ; CHECK-NEXT: movlt r4, #0
1812 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1813 ; CHECK-NEXT: vcmp.f32 s18, #0
1815 ; CHECK-NEXT: movgt.w r4, #-1
1816 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1818 ; CHECK-NEXT: movlt.w r9, #0
1819 ; CHECK-NEXT: vcmp.f32 s18, s20
1820 ; CHECK-NEXT: mov r5, r1
1821 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1823 ; CHECK-NEXT: movgt.w r9, #15
1824 ; CHECK-NEXT: and r0, r9, #15
1825 ; CHECK-NEXT: mov r6, r2
1826 ; CHECK-NEXT: orr.w r0, r0, r4, lsl #4
1827 ; CHECK-NEXT: str.w r0, [r8, #37]
1828 ; CHECK-NEXT: mov r0, r7
1829 ; CHECK-NEXT: mov r11, r3
1830 ; CHECK-NEXT: bl __fixunssfti
1831 ; CHECK-NEXT: vcmp.f32 s17, #0
1832 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1833 ; CHECK-NEXT: vcmp.f32 s17, s20
1835 ; CHECK-NEXT: movlt r0, #0
1836 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1837 ; CHECK-NEXT: vcmp.f32 s16, #0
1839 ; CHECK-NEXT: movgt.w r0, #-1
1840 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1841 ; CHECK-NEXT: vcmp.f32 s16, s20
1843 ; CHECK-NEXT: movlt.w r10, #0
1844 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1845 ; CHECK-NEXT: vcmp.f32 s19, #0
1847 ; CHECK-NEXT: movgt.w r10, #15
1848 ; CHECK-NEXT: and r7, r10, #15
1849 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1850 ; CHECK-NEXT: vcmp.f32 s19, s20
1851 ; CHECK-NEXT: orr.w r7, r7, r0, lsl #4
1852 ; CHECK-NEXT: str.w r7, [r8, #12]
1854 ; CHECK-NEXT: movlt r5, #0
1855 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1856 ; CHECK-NEXT: vcmp.f32 s19, #0
1858 ; CHECK-NEXT: movgt.w r5, #-1
1859 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1860 ; CHECK-NEXT: vcmp.f32 s19, s20
1862 ; CHECK-NEXT: movlt r6, #0
1863 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1864 ; CHECK-NEXT: lsrl r4, r5, #28
1865 ; CHECK-NEXT: vcmp.f32 s19, #0
1867 ; CHECK-NEXT: movgt.w r6, #-1
1868 ; CHECK-NEXT: orr.w r7, r5, r6, lsl #4
1869 ; CHECK-NEXT: str.w r7, [r8, #45]
1870 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1871 ; CHECK-NEXT: str.w r4, [r8, #41]
1873 ; CHECK-NEXT: movlt.w r11, #0
1874 ; CHECK-NEXT: vcmp.f32 s19, s20
1875 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1877 ; CHECK-NEXT: movgt.w r11, #15
1878 ; CHECK-NEXT: and r5, r11, #15
1879 ; CHECK-NEXT: vcmp.f32 s17, #0
1880 ; CHECK-NEXT: lsrl r6, r5, #28
1881 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1882 ; CHECK-NEXT: vcmp.f32 s17, s20
1883 ; CHECK-NEXT: strb.w r6, [r8, #49]
1885 ; CHECK-NEXT: movlt r3, #0
1886 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1887 ; CHECK-NEXT: vcmp.f32 s17, #0
1889 ; CHECK-NEXT: movgt r3, #15
1890 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1892 ; CHECK-NEXT: movlt r1, #0
1893 ; CHECK-NEXT: vcmp.f32 s17, s20
1894 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1896 ; CHECK-NEXT: movgt.w r1, #-1
1897 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r3
1898 ; CHECK-NEXT: vcmp.f32 s17, #0
1899 ; CHECK-NEXT: vmov r1, s1
1900 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1901 ; CHECK-NEXT: lsrl r0, r1, #28
1903 ; CHECK-NEXT: movlt r2, #0
1904 ; CHECK-NEXT: vcmp.f32 s17, s20
1905 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1907 ; CHECK-NEXT: movgt.w r2, #-1
1908 ; CHECK-NEXT: orr.w r1, r1, r2, lsl #4
1909 ; CHECK-NEXT: strd r0, r1, [r8, #16]
1910 ; CHECK-NEXT: and r1, r3, #15
1911 ; CHECK-NEXT: lsrl r2, r1, #28
1912 ; CHECK-NEXT: strb.w r2, [r8, #24]
1913 ; CHECK-NEXT: vpop {d8, d9, d10}
1914 ; CHECK-NEXT: add sp, #4
1915 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
1916 ; CHECK-NEXT: .p2align 2
1917 ; CHECK-NEXT: @ %bb.1:
1918 ; CHECK-NEXT: .LCPI30_0:
1919 ; CHECK-NEXT: .long 0x717fffff @ float 1.26765052E+30
1920 %x = call <4 x i100> @llvm.fptoui.sat.v4f32.v4i100(<4 x float> %f)
1924 define arm_aapcs_vfpcc <4 x i128> @test_unsigned_v4f32_v4i128(<4 x float> %f) {
1925 ; CHECK-LABEL: test_unsigned_v4f32_v4i128:
1927 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
1928 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
1929 ; CHECK-NEXT: .pad #4
1930 ; CHECK-NEXT: sub sp, #4
1931 ; CHECK-NEXT: .vsave {d8, d9, d10}
1932 ; CHECK-NEXT: vpush {d8, d9, d10}
1933 ; CHECK-NEXT: vmov q4, q0
1934 ; CHECK-NEXT: mov r4, r0
1935 ; CHECK-NEXT: vmov r0, s19
1936 ; CHECK-NEXT: bl __fixunssfti
1937 ; CHECK-NEXT: vmov r5, s18
1938 ; CHECK-NEXT: vldr s20, .LCPI31_0
1939 ; CHECK-NEXT: vcmp.f32 s19, #0
1940 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1941 ; CHECK-NEXT: vcmp.f32 s19, s20
1943 ; CHECK-NEXT: movlt r3, #0
1944 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1945 ; CHECK-NEXT: vcmp.f32 s19, #0
1947 ; CHECK-NEXT: movgt.w r3, #-1
1948 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1949 ; CHECK-NEXT: vcmp.f32 s19, s20
1950 ; CHECK-NEXT: str r3, [r4, #60]
1952 ; CHECK-NEXT: movlt r2, #0
1953 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1954 ; CHECK-NEXT: vcmp.f32 s19, #0
1956 ; CHECK-NEXT: movgt.w r2, #-1
1957 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1958 ; CHECK-NEXT: vcmp.f32 s19, s20
1959 ; CHECK-NEXT: str r2, [r4, #56]
1961 ; CHECK-NEXT: movlt r1, #0
1962 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1963 ; CHECK-NEXT: vcmp.f32 s19, #0
1965 ; CHECK-NEXT: movgt.w r1, #-1
1966 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1967 ; CHECK-NEXT: str r1, [r4, #52]
1969 ; CHECK-NEXT: movlt r0, #0
1970 ; CHECK-NEXT: vcmp.f32 s19, s20
1971 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1973 ; CHECK-NEXT: movgt.w r0, #-1
1974 ; CHECK-NEXT: str r0, [r4, #48]
1975 ; CHECK-NEXT: vmov r7, s16
1976 ; CHECK-NEXT: vmov r6, s17
1977 ; CHECK-NEXT: mov r0, r5
1978 ; CHECK-NEXT: bl __fixunssfti
1979 ; CHECK-NEXT: vcmp.f32 s18, #0
1980 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1981 ; CHECK-NEXT: vcmp.f32 s18, s20
1983 ; CHECK-NEXT: movlt r3, #0
1984 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1985 ; CHECK-NEXT: vcmp.f32 s18, #0
1987 ; CHECK-NEXT: movgt.w r3, #-1
1988 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1989 ; CHECK-NEXT: vcmp.f32 s18, s20
1990 ; CHECK-NEXT: str r3, [r4, #44]
1992 ; CHECK-NEXT: movlt r2, #0
1993 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1994 ; CHECK-NEXT: vcmp.f32 s18, #0
1996 ; CHECK-NEXT: movgt.w r2, #-1
1997 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
1998 ; CHECK-NEXT: vcmp.f32 s18, s20
1999 ; CHECK-NEXT: str r2, [r4, #40]
2001 ; CHECK-NEXT: movlt r1, #0
2002 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2003 ; CHECK-NEXT: vcmp.f32 s18, #0
2005 ; CHECK-NEXT: movgt.w r1, #-1
2006 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2007 ; CHECK-NEXT: str r1, [r4, #36]
2009 ; CHECK-NEXT: movlt r0, #0
2010 ; CHECK-NEXT: vcmp.f32 s18, s20
2011 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2013 ; CHECK-NEXT: movgt.w r0, #-1
2014 ; CHECK-NEXT: str r0, [r4, #32]
2015 ; CHECK-NEXT: mov r0, r6
2016 ; CHECK-NEXT: bl __fixunssfti
2017 ; CHECK-NEXT: vcmp.f32 s17, #0
2018 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2019 ; CHECK-NEXT: vcmp.f32 s17, s20
2021 ; CHECK-NEXT: movlt r3, #0
2022 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2023 ; CHECK-NEXT: vcmp.f32 s17, #0
2025 ; CHECK-NEXT: movgt.w r3, #-1
2026 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2027 ; CHECK-NEXT: vcmp.f32 s17, s20
2028 ; CHECK-NEXT: str r3, [r4, #28]
2030 ; CHECK-NEXT: movlt r2, #0
2031 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2032 ; CHECK-NEXT: vcmp.f32 s17, #0
2034 ; CHECK-NEXT: movgt.w r2, #-1
2035 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2036 ; CHECK-NEXT: vcmp.f32 s17, s20
2037 ; CHECK-NEXT: str r2, [r4, #24]
2039 ; CHECK-NEXT: movlt r1, #0
2040 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2041 ; CHECK-NEXT: vcmp.f32 s17, #0
2043 ; CHECK-NEXT: movgt.w r1, #-1
2044 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2045 ; CHECK-NEXT: str r1, [r4, #20]
2047 ; CHECK-NEXT: movlt r0, #0
2048 ; CHECK-NEXT: vcmp.f32 s17, s20
2049 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2051 ; CHECK-NEXT: movgt.w r0, #-1
2052 ; CHECK-NEXT: str r0, [r4, #16]
2053 ; CHECK-NEXT: mov r0, r7
2054 ; CHECK-NEXT: bl __fixunssfti
2055 ; CHECK-NEXT: vcmp.f32 s16, #0
2056 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2057 ; CHECK-NEXT: vcmp.f32 s16, s20
2059 ; CHECK-NEXT: movlt r3, #0
2060 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2061 ; CHECK-NEXT: vcmp.f32 s16, #0
2063 ; CHECK-NEXT: movgt.w r3, #-1
2064 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2065 ; CHECK-NEXT: vcmp.f32 s16, s20
2066 ; CHECK-NEXT: str r3, [r4, #12]
2068 ; CHECK-NEXT: movlt r2, #0
2069 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2070 ; CHECK-NEXT: vcmp.f32 s16, #0
2072 ; CHECK-NEXT: movgt.w r2, #-1
2073 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2074 ; CHECK-NEXT: vcmp.f32 s16, s20
2075 ; CHECK-NEXT: str r2, [r4, #8]
2077 ; CHECK-NEXT: movlt r1, #0
2078 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2079 ; CHECK-NEXT: vcmp.f32 s16, #0
2081 ; CHECK-NEXT: movgt.w r1, #-1
2082 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2083 ; CHECK-NEXT: str r1, [r4, #4]
2085 ; CHECK-NEXT: movlt r0, #0
2086 ; CHECK-NEXT: vcmp.f32 s16, s20
2087 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
2089 ; CHECK-NEXT: movgt.w r0, #-1
2090 ; CHECK-NEXT: str r0, [r4]
2091 ; CHECK-NEXT: vpop {d8, d9, d10}
2092 ; CHECK-NEXT: add sp, #4
2093 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
2094 ; CHECK-NEXT: .p2align 2
2095 ; CHECK-NEXT: @ %bb.1:
2096 ; CHECK-NEXT: .LCPI31_0:
2097 ; CHECK-NEXT: .long 0x7f7fffff @ float 3.40282347E+38
2098 %x = call <4 x i128> @llvm.fptoui.sat.v4f32.v4i128(<4 x float> %f)
2103 ; 2-Vector double to signed integer -- result size variation
2106 declare <2 x i1> @llvm.fptoui.sat.v2f64.v2i1 (<2 x double>)
2107 declare <2 x i8> @llvm.fptoui.sat.v2f64.v2i8 (<2 x double>)
2108 declare <2 x i13> @llvm.fptoui.sat.v2f64.v2i13 (<2 x double>)
2109 declare <2 x i16> @llvm.fptoui.sat.v2f64.v2i16 (<2 x double>)
2110 declare <2 x i19> @llvm.fptoui.sat.v2f64.v2i19 (<2 x double>)
2111 declare <2 x i50> @llvm.fptoui.sat.v2f64.v2i50 (<2 x double>)
2112 declare <2 x i64> @llvm.fptoui.sat.v2f64.v2i64 (<2 x double>)
2113 declare <2 x i100> @llvm.fptoui.sat.v2f64.v2i100(<2 x double>)
2114 declare <2 x i128> @llvm.fptoui.sat.v2f64.v2i128(<2 x double>)
2116 define arm_aapcs_vfpcc <2 x i1> @test_unsigned_v2f64_v2i1(<2 x double> %f) {
2117 ; CHECK-LABEL: test_unsigned_v2f64_v2i1:
2119 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2120 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2121 ; CHECK-NEXT: .pad #4
2122 ; CHECK-NEXT: sub sp, #4
2123 ; CHECK-NEXT: .vsave {d8, d9}
2124 ; CHECK-NEXT: vpush {d8, d9}
2125 ; CHECK-NEXT: .pad #8
2126 ; CHECK-NEXT: sub sp, #8
2127 ; CHECK-NEXT: vmov q4, q0
2128 ; CHECK-NEXT: vldr d0, .LCPI32_0
2129 ; CHECK-NEXT: vmov r5, r6, d8
2130 ; CHECK-NEXT: str r0, [sp, #4] @ 4-byte Spill
2131 ; CHECK-NEXT: vmov r10, r9, d0
2132 ; CHECK-NEXT: mov r0, r5
2133 ; CHECK-NEXT: mov r1, r6
2134 ; CHECK-NEXT: mov r2, r10
2135 ; CHECK-NEXT: mov r3, r9
2136 ; CHECK-NEXT: bl __aeabi_dcmpgt
2137 ; CHECK-NEXT: vldr d0, .LCPI32_1
2138 ; CHECK-NEXT: mov r7, r0
2139 ; CHECK-NEXT: mov r0, r5
2140 ; CHECK-NEXT: mov r1, r6
2141 ; CHECK-NEXT: vmov r4, r11, d0
2142 ; CHECK-NEXT: mov r2, r4
2143 ; CHECK-NEXT: mov r3, r11
2144 ; CHECK-NEXT: bl __aeabi_dcmpge
2145 ; CHECK-NEXT: mov r8, r0
2146 ; CHECK-NEXT: mov r0, r5
2147 ; CHECK-NEXT: mov r1, r6
2148 ; CHECK-NEXT: bl __aeabi_d2uiz
2149 ; CHECK-NEXT: vmov r6, r5, d9
2150 ; CHECK-NEXT: cmp.w r8, #0
2151 ; CHECK-NEXT: csel r0, r0, r8, ne
2152 ; CHECK-NEXT: cmp r7, #0
2154 ; CHECK-NEXT: movne r0, #1
2155 ; CHECK-NEXT: movs r7, #0
2156 ; CHECK-NEXT: and r0, r0, #1
2157 ; CHECK-NEXT: mov r2, r10
2158 ; CHECK-NEXT: rsbs r0, r0, #0
2159 ; CHECK-NEXT: mov r3, r9
2160 ; CHECK-NEXT: bfi r7, r0, #0, #1
2161 ; CHECK-NEXT: mov r0, r6
2162 ; CHECK-NEXT: mov r1, r5
2163 ; CHECK-NEXT: bl __aeabi_dcmpgt
2164 ; CHECK-NEXT: mov r8, r0
2165 ; CHECK-NEXT: mov r0, r6
2166 ; CHECK-NEXT: mov r1, r5
2167 ; CHECK-NEXT: mov r2, r4
2168 ; CHECK-NEXT: mov r3, r11
2169 ; CHECK-NEXT: bl __aeabi_dcmpge
2170 ; CHECK-NEXT: mov r4, r0
2171 ; CHECK-NEXT: mov r0, r6
2172 ; CHECK-NEXT: mov r1, r5
2173 ; CHECK-NEXT: bl __aeabi_d2uiz
2174 ; CHECK-NEXT: cmp r4, #0
2175 ; CHECK-NEXT: csel r0, r0, r4, ne
2176 ; CHECK-NEXT: cmp.w r8, #0
2178 ; CHECK-NEXT: movne r0, #1
2179 ; CHECK-NEXT: and r0, r0, #1
2180 ; CHECK-NEXT: rsbs r0, r0, #0
2181 ; CHECK-NEXT: bfi r7, r0, #1, #1
2182 ; CHECK-NEXT: ldr r0, [sp, #4] @ 4-byte Reload
2183 ; CHECK-NEXT: strb r7, [r0]
2184 ; CHECK-NEXT: add sp, #8
2185 ; CHECK-NEXT: vpop {d8, d9}
2186 ; CHECK-NEXT: add sp, #4
2187 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2188 ; CHECK-NEXT: .p2align 3
2189 ; CHECK-NEXT: @ %bb.1:
2190 ; CHECK-NEXT: .LCPI32_0:
2191 ; CHECK-NEXT: .long 0 @ double 1
2192 ; CHECK-NEXT: .long 1072693248
2193 ; CHECK-NEXT: .LCPI32_1:
2194 ; CHECK-NEXT: .long 0 @ double 0
2195 ; CHECK-NEXT: .long 0
2196 %x = call <2 x i1> @llvm.fptoui.sat.v2f64.v2i1(<2 x double> %f)
2200 define arm_aapcs_vfpcc <2 x i8> @test_unsigned_v2f64_v2i8(<2 x double> %f) {
2201 ; CHECK-LABEL: test_unsigned_v2f64_v2i8:
2203 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2204 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2205 ; CHECK-NEXT: .pad #4
2206 ; CHECK-NEXT: sub sp, #4
2207 ; CHECK-NEXT: .vsave {d8, d9}
2208 ; CHECK-NEXT: vpush {d8, d9}
2209 ; CHECK-NEXT: .pad #16
2210 ; CHECK-NEXT: sub sp, #16
2211 ; CHECK-NEXT: vmov q4, q0
2212 ; CHECK-NEXT: vldr d0, .LCPI33_0
2213 ; CHECK-NEXT: vmov r6, r7, d9
2214 ; CHECK-NEXT: vmov r2, r3, d0
2215 ; CHECK-NEXT: mov r0, r6
2216 ; CHECK-NEXT: mov r1, r7
2217 ; CHECK-NEXT: strd r3, r2, [sp, #4] @ 8-byte Folded Spill
2218 ; CHECK-NEXT: bl __aeabi_dcmpge
2219 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2220 ; CHECK-NEXT: mov r0, r6
2221 ; CHECK-NEXT: mov r1, r7
2222 ; CHECK-NEXT: bl __aeabi_d2ulz
2223 ; CHECK-NEXT: vldr d0, .LCPI33_1
2224 ; CHECK-NEXT: mov r5, r0
2225 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
2226 ; CHECK-NEXT: mov r10, r1
2227 ; CHECK-NEXT: vmov r9, r8, d0
2228 ; CHECK-NEXT: mov r1, r7
2229 ; CHECK-NEXT: clz r0, r0
2230 ; CHECK-NEXT: vmov r11, r4, d8
2231 ; CHECK-NEXT: lsrs r0, r0, #5
2232 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2233 ; CHECK-NEXT: mov r0, r6
2235 ; CHECK-NEXT: movne r5, #0
2236 ; CHECK-NEXT: mov r2, r9
2237 ; CHECK-NEXT: mov r3, r8
2238 ; CHECK-NEXT: bl __aeabi_dcmpgt
2239 ; CHECK-NEXT: mov r6, r0
2240 ; CHECK-NEXT: cmp r0, #0
2241 ; CHECK-NEXT: mov r0, r11
2242 ; CHECK-NEXT: mov r1, r4
2243 ; CHECK-NEXT: mov r2, r9
2244 ; CHECK-NEXT: mov r3, r8
2246 ; CHECK-NEXT: movne r6, #1
2247 ; CHECK-NEXT: cmp r6, #0
2249 ; CHECK-NEXT: movne r5, #255
2250 ; CHECK-NEXT: bl __aeabi_dcmpgt
2251 ; CHECK-NEXT: mov r7, r0
2252 ; CHECK-NEXT: cmp r0, #0
2254 ; CHECK-NEXT: movne r7, #1
2255 ; CHECK-NEXT: ldrd r3, r2, [sp, #4] @ 8-byte Folded Reload
2256 ; CHECK-NEXT: mov r0, r11
2257 ; CHECK-NEXT: mov r1, r4
2258 ; CHECK-NEXT: mov r8, r4
2259 ; CHECK-NEXT: bl __aeabi_dcmpge
2260 ; CHECK-NEXT: clz r0, r0
2261 ; CHECK-NEXT: mov r1, r8
2262 ; CHECK-NEXT: lsrs r4, r0, #5
2263 ; CHECK-NEXT: mov r0, r11
2264 ; CHECK-NEXT: bl __aeabi_d2ulz
2265 ; CHECK-NEXT: cmp r4, #0
2267 ; CHECK-NEXT: movne r0, #0
2268 ; CHECK-NEXT: cmp r7, #0
2270 ; CHECK-NEXT: movne r0, #255
2271 ; CHECK-NEXT: ldr r2, [sp, #12] @ 4-byte Reload
2272 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2273 ; CHECK-NEXT: cmp r2, #0
2275 ; CHECK-NEXT: movne.w r10, #0
2276 ; CHECK-NEXT: cmp r6, #0
2278 ; CHECK-NEXT: movne.w r10, #0
2279 ; CHECK-NEXT: cmp r4, #0
2281 ; CHECK-NEXT: movne r1, #0
2282 ; CHECK-NEXT: cmp r7, #0
2284 ; CHECK-NEXT: movne r1, #0
2285 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r10
2286 ; CHECK-NEXT: add sp, #16
2287 ; CHECK-NEXT: vpop {d8, d9}
2288 ; CHECK-NEXT: add sp, #4
2289 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2290 ; CHECK-NEXT: .p2align 3
2291 ; CHECK-NEXT: @ %bb.1:
2292 ; CHECK-NEXT: .LCPI33_0:
2293 ; CHECK-NEXT: .long 0 @ double 0
2294 ; CHECK-NEXT: .long 0
2295 ; CHECK-NEXT: .LCPI33_1:
2296 ; CHECK-NEXT: .long 0 @ double 255
2297 ; CHECK-NEXT: .long 1081073664
2298 %x = call <2 x i8> @llvm.fptoui.sat.v2f64.v2i8(<2 x double> %f)
2302 define arm_aapcs_vfpcc <2 x i13> @test_unsigned_v2f64_v2i13(<2 x double> %f) {
2303 ; CHECK-LABEL: test_unsigned_v2f64_v2i13:
2305 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2306 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2307 ; CHECK-NEXT: .pad #4
2308 ; CHECK-NEXT: sub sp, #4
2309 ; CHECK-NEXT: .vsave {d8, d9}
2310 ; CHECK-NEXT: vpush {d8, d9}
2311 ; CHECK-NEXT: .pad #16
2312 ; CHECK-NEXT: sub sp, #16
2313 ; CHECK-NEXT: vmov q4, q0
2314 ; CHECK-NEXT: vldr d0, .LCPI34_0
2315 ; CHECK-NEXT: vmov r6, r7, d9
2316 ; CHECK-NEXT: vmov r2, r3, d0
2317 ; CHECK-NEXT: mov r0, r6
2318 ; CHECK-NEXT: mov r1, r7
2319 ; CHECK-NEXT: strd r3, r2, [sp, #4] @ 8-byte Folded Spill
2320 ; CHECK-NEXT: bl __aeabi_dcmpge
2321 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2322 ; CHECK-NEXT: mov r0, r6
2323 ; CHECK-NEXT: mov r1, r7
2324 ; CHECK-NEXT: bl __aeabi_d2ulz
2325 ; CHECK-NEXT: vldr d0, .LCPI34_1
2326 ; CHECK-NEXT: mov r5, r0
2327 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
2328 ; CHECK-NEXT: mov r10, r1
2329 ; CHECK-NEXT: vmov r9, r8, d0
2330 ; CHECK-NEXT: mov r1, r7
2331 ; CHECK-NEXT: clz r0, r0
2332 ; CHECK-NEXT: vmov r11, r4, d8
2333 ; CHECK-NEXT: lsrs r0, r0, #5
2334 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2335 ; CHECK-NEXT: mov r0, r6
2337 ; CHECK-NEXT: movne r5, #0
2338 ; CHECK-NEXT: mov r2, r9
2339 ; CHECK-NEXT: mov r3, r8
2340 ; CHECK-NEXT: bl __aeabi_dcmpgt
2341 ; CHECK-NEXT: mov r6, r0
2342 ; CHECK-NEXT: cmp r0, #0
2343 ; CHECK-NEXT: mov r0, r11
2344 ; CHECK-NEXT: mov r1, r4
2345 ; CHECK-NEXT: mov r2, r9
2346 ; CHECK-NEXT: mov r3, r8
2348 ; CHECK-NEXT: movne r6, #1
2349 ; CHECK-NEXT: cmp r6, #0
2351 ; CHECK-NEXT: movwne r5, #8191
2352 ; CHECK-NEXT: bl __aeabi_dcmpgt
2353 ; CHECK-NEXT: mov r7, r0
2354 ; CHECK-NEXT: cmp r0, #0
2356 ; CHECK-NEXT: movne r7, #1
2357 ; CHECK-NEXT: ldrd r3, r2, [sp, #4] @ 8-byte Folded Reload
2358 ; CHECK-NEXT: mov r0, r11
2359 ; CHECK-NEXT: mov r1, r4
2360 ; CHECK-NEXT: mov r8, r4
2361 ; CHECK-NEXT: bl __aeabi_dcmpge
2362 ; CHECK-NEXT: clz r0, r0
2363 ; CHECK-NEXT: mov r1, r8
2364 ; CHECK-NEXT: lsrs r4, r0, #5
2365 ; CHECK-NEXT: mov r0, r11
2366 ; CHECK-NEXT: bl __aeabi_d2ulz
2367 ; CHECK-NEXT: cmp r4, #0
2369 ; CHECK-NEXT: movne r0, #0
2370 ; CHECK-NEXT: cmp r7, #0
2372 ; CHECK-NEXT: movwne r0, #8191
2373 ; CHECK-NEXT: ldr r2, [sp, #12] @ 4-byte Reload
2374 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2375 ; CHECK-NEXT: cmp r2, #0
2377 ; CHECK-NEXT: movne.w r10, #0
2378 ; CHECK-NEXT: cmp r6, #0
2380 ; CHECK-NEXT: movne.w r10, #0
2381 ; CHECK-NEXT: cmp r4, #0
2383 ; CHECK-NEXT: movne r1, #0
2384 ; CHECK-NEXT: cmp r7, #0
2386 ; CHECK-NEXT: movne r1, #0
2387 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r10
2388 ; CHECK-NEXT: add sp, #16
2389 ; CHECK-NEXT: vpop {d8, d9}
2390 ; CHECK-NEXT: add sp, #4
2391 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2392 ; CHECK-NEXT: .p2align 3
2393 ; CHECK-NEXT: @ %bb.1:
2394 ; CHECK-NEXT: .LCPI34_0:
2395 ; CHECK-NEXT: .long 0 @ double 0
2396 ; CHECK-NEXT: .long 0
2397 ; CHECK-NEXT: .LCPI34_1:
2398 ; CHECK-NEXT: .long 0 @ double 8191
2399 ; CHECK-NEXT: .long 1086324480
2400 %x = call <2 x i13> @llvm.fptoui.sat.v2f64.v2i13(<2 x double> %f)
2404 define arm_aapcs_vfpcc <2 x i16> @test_unsigned_v2f64_v2i16(<2 x double> %f) {
2405 ; CHECK-LABEL: test_unsigned_v2f64_v2i16:
2407 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2408 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2409 ; CHECK-NEXT: .pad #4
2410 ; CHECK-NEXT: sub sp, #4
2411 ; CHECK-NEXT: .vsave {d8, d9}
2412 ; CHECK-NEXT: vpush {d8, d9}
2413 ; CHECK-NEXT: .pad #16
2414 ; CHECK-NEXT: sub sp, #16
2415 ; CHECK-NEXT: vmov q4, q0
2416 ; CHECK-NEXT: vldr d0, .LCPI35_0
2417 ; CHECK-NEXT: vmov r6, r7, d9
2418 ; CHECK-NEXT: vmov r2, r3, d0
2419 ; CHECK-NEXT: mov r0, r6
2420 ; CHECK-NEXT: mov r1, r7
2421 ; CHECK-NEXT: strd r3, r2, [sp, #4] @ 8-byte Folded Spill
2422 ; CHECK-NEXT: bl __aeabi_dcmpge
2423 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2424 ; CHECK-NEXT: mov r0, r6
2425 ; CHECK-NEXT: mov r1, r7
2426 ; CHECK-NEXT: bl __aeabi_d2ulz
2427 ; CHECK-NEXT: vldr d0, .LCPI35_1
2428 ; CHECK-NEXT: mov r5, r0
2429 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
2430 ; CHECK-NEXT: mov r10, r1
2431 ; CHECK-NEXT: vmov r9, r8, d0
2432 ; CHECK-NEXT: mov r1, r7
2433 ; CHECK-NEXT: clz r0, r0
2434 ; CHECK-NEXT: vmov r11, r4, d8
2435 ; CHECK-NEXT: lsrs r0, r0, #5
2436 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2437 ; CHECK-NEXT: mov r0, r6
2439 ; CHECK-NEXT: movne r5, #0
2440 ; CHECK-NEXT: mov r2, r9
2441 ; CHECK-NEXT: mov r3, r8
2442 ; CHECK-NEXT: bl __aeabi_dcmpgt
2443 ; CHECK-NEXT: mov r6, r0
2444 ; CHECK-NEXT: cmp r0, #0
2445 ; CHECK-NEXT: mov r0, r11
2446 ; CHECK-NEXT: mov r1, r4
2447 ; CHECK-NEXT: mov r2, r9
2448 ; CHECK-NEXT: mov r3, r8
2450 ; CHECK-NEXT: movne r6, #1
2451 ; CHECK-NEXT: cmp r6, #0
2453 ; CHECK-NEXT: movwne r5, #65535
2454 ; CHECK-NEXT: bl __aeabi_dcmpgt
2455 ; CHECK-NEXT: mov r7, r0
2456 ; CHECK-NEXT: cmp r0, #0
2458 ; CHECK-NEXT: movne r7, #1
2459 ; CHECK-NEXT: ldrd r3, r2, [sp, #4] @ 8-byte Folded Reload
2460 ; CHECK-NEXT: mov r0, r11
2461 ; CHECK-NEXT: mov r1, r4
2462 ; CHECK-NEXT: mov r8, r4
2463 ; CHECK-NEXT: bl __aeabi_dcmpge
2464 ; CHECK-NEXT: clz r0, r0
2465 ; CHECK-NEXT: mov r1, r8
2466 ; CHECK-NEXT: lsrs r4, r0, #5
2467 ; CHECK-NEXT: mov r0, r11
2468 ; CHECK-NEXT: bl __aeabi_d2ulz
2469 ; CHECK-NEXT: cmp r4, #0
2471 ; CHECK-NEXT: movne r0, #0
2472 ; CHECK-NEXT: cmp r7, #0
2474 ; CHECK-NEXT: movwne r0, #65535
2475 ; CHECK-NEXT: ldr r2, [sp, #12] @ 4-byte Reload
2476 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2477 ; CHECK-NEXT: cmp r2, #0
2479 ; CHECK-NEXT: movne.w r10, #0
2480 ; CHECK-NEXT: cmp r6, #0
2482 ; CHECK-NEXT: movne.w r10, #0
2483 ; CHECK-NEXT: cmp r4, #0
2485 ; CHECK-NEXT: movne r1, #0
2486 ; CHECK-NEXT: cmp r7, #0
2488 ; CHECK-NEXT: movne r1, #0
2489 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r10
2490 ; CHECK-NEXT: add sp, #16
2491 ; CHECK-NEXT: vpop {d8, d9}
2492 ; CHECK-NEXT: add sp, #4
2493 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2494 ; CHECK-NEXT: .p2align 3
2495 ; CHECK-NEXT: @ %bb.1:
2496 ; CHECK-NEXT: .LCPI35_0:
2497 ; CHECK-NEXT: .long 0 @ double 0
2498 ; CHECK-NEXT: .long 0
2499 ; CHECK-NEXT: .LCPI35_1:
2500 ; CHECK-NEXT: .long 0 @ double 65535
2501 ; CHECK-NEXT: .long 1089470432
2502 %x = call <2 x i16> @llvm.fptoui.sat.v2f64.v2i16(<2 x double> %f)
2506 define arm_aapcs_vfpcc <2 x i19> @test_unsigned_v2f64_v2i19(<2 x double> %f) {
2507 ; CHECK-LABEL: test_unsigned_v2f64_v2i19:
2509 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2510 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2511 ; CHECK-NEXT: .pad #4
2512 ; CHECK-NEXT: sub sp, #4
2513 ; CHECK-NEXT: .vsave {d8, d9}
2514 ; CHECK-NEXT: vpush {d8, d9}
2515 ; CHECK-NEXT: .pad #16
2516 ; CHECK-NEXT: sub sp, #16
2517 ; CHECK-NEXT: vmov q4, q0
2518 ; CHECK-NEXT: vldr d0, .LCPI36_0
2519 ; CHECK-NEXT: vmov r11, r10, d8
2520 ; CHECK-NEXT: vmov r2, r3, d0
2521 ; CHECK-NEXT: mov r0, r11
2522 ; CHECK-NEXT: mov r1, r10
2523 ; CHECK-NEXT: strd r2, r3, [sp, #8] @ 8-byte Folded Spill
2524 ; CHECK-NEXT: bl __aeabi_dcmpgt
2525 ; CHECK-NEXT: vldr d0, .LCPI36_1
2526 ; CHECK-NEXT: mov r4, r0
2527 ; CHECK-NEXT: cmp r0, #0
2528 ; CHECK-NEXT: mov r0, r11
2529 ; CHECK-NEXT: vmov r5, r7, d0
2530 ; CHECK-NEXT: mov r1, r10
2531 ; CHECK-NEXT: vmov r8, r6, d9
2533 ; CHECK-NEXT: movne r4, #1
2534 ; CHECK-NEXT: mov r2, r5
2535 ; CHECK-NEXT: mov r3, r7
2536 ; CHECK-NEXT: bl __aeabi_dcmpge
2537 ; CHECK-NEXT: clz r0, r0
2538 ; CHECK-NEXT: mov r1, r6
2539 ; CHECK-NEXT: mov r2, r5
2540 ; CHECK-NEXT: mov r3, r7
2541 ; CHECK-NEXT: lsrs r0, r0, #5
2542 ; CHECK-NEXT: str r0, [sp, #4] @ 4-byte Spill
2543 ; CHECK-NEXT: mov r0, r8
2544 ; CHECK-NEXT: bl __aeabi_dcmpge
2545 ; CHECK-NEXT: clz r0, r0
2546 ; CHECK-NEXT: mov r1, r6
2547 ; CHECK-NEXT: lsr.w r9, r0, #5
2548 ; CHECK-NEXT: mov r0, r8
2549 ; CHECK-NEXT: bl __aeabi_d2ulz
2550 ; CHECK-NEXT: mov r5, r0
2551 ; CHECK-NEXT: cmp.w r9, #0
2553 ; CHECK-NEXT: movne r5, #0
2554 ; CHECK-NEXT: ldrd r2, r3, [sp, #8] @ 8-byte Folded Reload
2555 ; CHECK-NEXT: mov r7, r1
2556 ; CHECK-NEXT: mov r0, r8
2557 ; CHECK-NEXT: mov r1, r6
2558 ; CHECK-NEXT: bl __aeabi_dcmpgt
2559 ; CHECK-NEXT: mov r6, r0
2560 ; CHECK-NEXT: cmp r0, #0
2561 ; CHECK-NEXT: mov r0, r11
2562 ; CHECK-NEXT: mov r1, r10
2564 ; CHECK-NEXT: movne r6, #1
2565 ; CHECK-NEXT: cmp r6, #0
2566 ; CHECK-NEXT: itt ne
2567 ; CHECK-NEXT: movwne r5, #65535
2568 ; CHECK-NEXT: movtne r5, #7
2569 ; CHECK-NEXT: bl __aeabi_d2ulz
2570 ; CHECK-NEXT: ldr r2, [sp, #4] @ 4-byte Reload
2571 ; CHECK-NEXT: cmp r2, #0
2573 ; CHECK-NEXT: movne r0, #0
2574 ; CHECK-NEXT: cmp r4, #0
2575 ; CHECK-NEXT: itt ne
2576 ; CHECK-NEXT: movwne r0, #65535
2577 ; CHECK-NEXT: movtne r0, #7
2578 ; CHECK-NEXT: cmp.w r9, #0
2580 ; CHECK-NEXT: movne r7, #0
2581 ; CHECK-NEXT: cmp r6, #0
2583 ; CHECK-NEXT: movne r7, #0
2584 ; CHECK-NEXT: cmp r2, #0
2586 ; CHECK-NEXT: movne r1, #0
2587 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2588 ; CHECK-NEXT: cmp r4, #0
2590 ; CHECK-NEXT: movne r1, #0
2591 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r7
2592 ; CHECK-NEXT: add sp, #16
2593 ; CHECK-NEXT: vpop {d8, d9}
2594 ; CHECK-NEXT: add sp, #4
2595 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2596 ; CHECK-NEXT: .p2align 3
2597 ; CHECK-NEXT: @ %bb.1:
2598 ; CHECK-NEXT: .LCPI36_0:
2599 ; CHECK-NEXT: .long 0 @ double 524287
2600 ; CHECK-NEXT: .long 1092616188
2601 ; CHECK-NEXT: .LCPI36_1:
2602 ; CHECK-NEXT: .long 0 @ double 0
2603 ; CHECK-NEXT: .long 0
2604 %x = call <2 x i19> @llvm.fptoui.sat.v2f64.v2i19(<2 x double> %f)
2608 define arm_aapcs_vfpcc <2 x i32> @test_unsigned_v2f64_v2i32_duplicate(<2 x double> %f) {
2609 ; CHECK-LABEL: test_unsigned_v2f64_v2i32_duplicate:
2611 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2612 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2613 ; CHECK-NEXT: .pad #4
2614 ; CHECK-NEXT: sub sp, #4
2615 ; CHECK-NEXT: .vsave {d8, d9}
2616 ; CHECK-NEXT: vpush {d8, d9}
2617 ; CHECK-NEXT: .pad #16
2618 ; CHECK-NEXT: sub sp, #16
2619 ; CHECK-NEXT: vmov q4, q0
2620 ; CHECK-NEXT: vldr d0, .LCPI37_0
2621 ; CHECK-NEXT: vmov r6, r7, d9
2622 ; CHECK-NEXT: vmov r2, r3, d0
2623 ; CHECK-NEXT: mov r0, r6
2624 ; CHECK-NEXT: mov r1, r7
2625 ; CHECK-NEXT: strd r3, r2, [sp, #4] @ 8-byte Folded Spill
2626 ; CHECK-NEXT: bl __aeabi_dcmpge
2627 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2628 ; CHECK-NEXT: mov r0, r6
2629 ; CHECK-NEXT: mov r1, r7
2630 ; CHECK-NEXT: bl __aeabi_d2ulz
2631 ; CHECK-NEXT: vldr d0, .LCPI37_1
2632 ; CHECK-NEXT: mov r5, r0
2633 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
2634 ; CHECK-NEXT: mov r10, r1
2635 ; CHECK-NEXT: vmov r9, r8, d0
2636 ; CHECK-NEXT: mov r1, r7
2637 ; CHECK-NEXT: clz r0, r0
2638 ; CHECK-NEXT: vmov r11, r4, d8
2639 ; CHECK-NEXT: lsrs r0, r0, #5
2640 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2641 ; CHECK-NEXT: mov r0, r6
2643 ; CHECK-NEXT: movne r5, #0
2644 ; CHECK-NEXT: mov r2, r9
2645 ; CHECK-NEXT: mov r3, r8
2646 ; CHECK-NEXT: bl __aeabi_dcmpgt
2647 ; CHECK-NEXT: mov r6, r0
2648 ; CHECK-NEXT: cmp r0, #0
2649 ; CHECK-NEXT: mov r0, r11
2650 ; CHECK-NEXT: mov r1, r4
2651 ; CHECK-NEXT: mov r2, r9
2652 ; CHECK-NEXT: mov r3, r8
2654 ; CHECK-NEXT: movne r6, #1
2655 ; CHECK-NEXT: cmp r6, #0
2657 ; CHECK-NEXT: movne.w r5, #-1
2658 ; CHECK-NEXT: bl __aeabi_dcmpgt
2659 ; CHECK-NEXT: mov r7, r0
2660 ; CHECK-NEXT: cmp r0, #0
2662 ; CHECK-NEXT: movne r7, #1
2663 ; CHECK-NEXT: ldrd r3, r2, [sp, #4] @ 8-byte Folded Reload
2664 ; CHECK-NEXT: mov r0, r11
2665 ; CHECK-NEXT: mov r1, r4
2666 ; CHECK-NEXT: mov r8, r4
2667 ; CHECK-NEXT: bl __aeabi_dcmpge
2668 ; CHECK-NEXT: clz r0, r0
2669 ; CHECK-NEXT: mov r1, r8
2670 ; CHECK-NEXT: lsrs r4, r0, #5
2671 ; CHECK-NEXT: mov r0, r11
2672 ; CHECK-NEXT: bl __aeabi_d2ulz
2673 ; CHECK-NEXT: cmp r4, #0
2675 ; CHECK-NEXT: movne r0, #0
2676 ; CHECK-NEXT: cmp r7, #0
2678 ; CHECK-NEXT: movne.w r0, #-1
2679 ; CHECK-NEXT: ldr r2, [sp, #12] @ 4-byte Reload
2680 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2681 ; CHECK-NEXT: cmp r2, #0
2683 ; CHECK-NEXT: movne.w r10, #0
2684 ; CHECK-NEXT: cmp r6, #0
2686 ; CHECK-NEXT: movne.w r10, #0
2687 ; CHECK-NEXT: cmp r4, #0
2689 ; CHECK-NEXT: movne r1, #0
2690 ; CHECK-NEXT: cmp r7, #0
2692 ; CHECK-NEXT: movne r1, #0
2693 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r10
2694 ; CHECK-NEXT: add sp, #16
2695 ; CHECK-NEXT: vpop {d8, d9}
2696 ; CHECK-NEXT: add sp, #4
2697 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2698 ; CHECK-NEXT: .p2align 3
2699 ; CHECK-NEXT: @ %bb.1:
2700 ; CHECK-NEXT: .LCPI37_0:
2701 ; CHECK-NEXT: .long 0 @ double 0
2702 ; CHECK-NEXT: .long 0
2703 ; CHECK-NEXT: .LCPI37_1:
2704 ; CHECK-NEXT: .long 4292870144 @ double 4294967295
2705 ; CHECK-NEXT: .long 1106247679
2706 %x = call <2 x i32> @llvm.fptoui.sat.v2f64.v2i32(<2 x double> %f)
2710 define arm_aapcs_vfpcc <2 x i50> @test_unsigned_v2f64_v2i50(<2 x double> %f) {
2711 ; CHECK-LABEL: test_unsigned_v2f64_v2i50:
2713 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2714 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2715 ; CHECK-NEXT: .pad #4
2716 ; CHECK-NEXT: sub sp, #4
2717 ; CHECK-NEXT: .vsave {d8, d9}
2718 ; CHECK-NEXT: vpush {d8, d9}
2719 ; CHECK-NEXT: .pad #16
2720 ; CHECK-NEXT: sub sp, #16
2721 ; CHECK-NEXT: vmov q4, q0
2722 ; CHECK-NEXT: vldr d0, .LCPI38_0
2723 ; CHECK-NEXT: vmov r11, r10, d8
2724 ; CHECK-NEXT: vmov r2, r3, d0
2725 ; CHECK-NEXT: mov r0, r11
2726 ; CHECK-NEXT: mov r1, r10
2727 ; CHECK-NEXT: strd r2, r3, [sp, #8] @ 8-byte Folded Spill
2728 ; CHECK-NEXT: bl __aeabi_dcmpgt
2729 ; CHECK-NEXT: vldr d0, .LCPI38_1
2730 ; CHECK-NEXT: mov r4, r0
2731 ; CHECK-NEXT: cmp r0, #0
2732 ; CHECK-NEXT: mov r0, r11
2733 ; CHECK-NEXT: vmov r5, r7, d0
2734 ; CHECK-NEXT: mov r1, r10
2735 ; CHECK-NEXT: vmov r8, r6, d9
2737 ; CHECK-NEXT: movne r4, #1
2738 ; CHECK-NEXT: mov r2, r5
2739 ; CHECK-NEXT: mov r3, r7
2740 ; CHECK-NEXT: bl __aeabi_dcmpge
2741 ; CHECK-NEXT: clz r0, r0
2742 ; CHECK-NEXT: mov r1, r6
2743 ; CHECK-NEXT: mov r2, r5
2744 ; CHECK-NEXT: mov r3, r7
2745 ; CHECK-NEXT: lsrs r0, r0, #5
2746 ; CHECK-NEXT: str r0, [sp, #4] @ 4-byte Spill
2747 ; CHECK-NEXT: mov r0, r8
2748 ; CHECK-NEXT: bl __aeabi_dcmpge
2749 ; CHECK-NEXT: clz r0, r0
2750 ; CHECK-NEXT: mov r1, r6
2751 ; CHECK-NEXT: lsr.w r9, r0, #5
2752 ; CHECK-NEXT: mov r0, r8
2753 ; CHECK-NEXT: bl __aeabi_d2ulz
2754 ; CHECK-NEXT: mov r7, r1
2755 ; CHECK-NEXT: cmp.w r9, #0
2757 ; CHECK-NEXT: movne r7, #0
2758 ; CHECK-NEXT: ldrd r2, r3, [sp, #8] @ 8-byte Folded Reload
2759 ; CHECK-NEXT: mov r5, r0
2760 ; CHECK-NEXT: mov r0, r8
2761 ; CHECK-NEXT: mov r1, r6
2762 ; CHECK-NEXT: bl __aeabi_dcmpgt
2763 ; CHECK-NEXT: mov r6, r0
2764 ; CHECK-NEXT: cmp r0, #0
2765 ; CHECK-NEXT: mov r0, r11
2766 ; CHECK-NEXT: mov r1, r10
2768 ; CHECK-NEXT: movne r6, #1
2769 ; CHECK-NEXT: cmp r6, #0
2770 ; CHECK-NEXT: itt ne
2771 ; CHECK-NEXT: movwne r7, #65535
2772 ; CHECK-NEXT: movtne r7, #3
2773 ; CHECK-NEXT: bl __aeabi_d2ulz
2774 ; CHECK-NEXT: ldr r2, [sp, #4] @ 4-byte Reload
2775 ; CHECK-NEXT: cmp r2, #0
2777 ; CHECK-NEXT: movne r1, #0
2778 ; CHECK-NEXT: cmp r4, #0
2779 ; CHECK-NEXT: itt ne
2780 ; CHECK-NEXT: movwne r1, #65535
2781 ; CHECK-NEXT: movtne r1, #3
2782 ; CHECK-NEXT: cmp.w r9, #0
2784 ; CHECK-NEXT: movne r5, #0
2785 ; CHECK-NEXT: cmp r6, #0
2787 ; CHECK-NEXT: movne.w r5, #-1
2788 ; CHECK-NEXT: cmp r2, #0
2790 ; CHECK-NEXT: movne r0, #0
2791 ; CHECK-NEXT: cmp r4, #0
2793 ; CHECK-NEXT: movne.w r0, #-1
2794 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2795 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r7
2796 ; CHECK-NEXT: add sp, #16
2797 ; CHECK-NEXT: vpop {d8, d9}
2798 ; CHECK-NEXT: add sp, #4
2799 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2800 ; CHECK-NEXT: .p2align 3
2801 ; CHECK-NEXT: @ %bb.1:
2802 ; CHECK-NEXT: .LCPI38_0:
2803 ; CHECK-NEXT: .long 4294967288 @ double 1125899906842623
2804 ; CHECK-NEXT: .long 1125122047
2805 ; CHECK-NEXT: .LCPI38_1:
2806 ; CHECK-NEXT: .long 0 @ double 0
2807 ; CHECK-NEXT: .long 0
2808 %x = call <2 x i50> @llvm.fptoui.sat.v2f64.v2i50(<2 x double> %f)
2812 define arm_aapcs_vfpcc <2 x i64> @test_unsigned_v2f64_v2i64(<2 x double> %f) {
2813 ; CHECK-LABEL: test_unsigned_v2f64_v2i64:
2815 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2816 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2817 ; CHECK-NEXT: .pad #4
2818 ; CHECK-NEXT: sub sp, #4
2819 ; CHECK-NEXT: .vsave {d8, d9}
2820 ; CHECK-NEXT: vpush {d8, d9}
2821 ; CHECK-NEXT: .pad #16
2822 ; CHECK-NEXT: sub sp, #16
2823 ; CHECK-NEXT: vmov q4, q0
2824 ; CHECK-NEXT: vldr d0, .LCPI39_0
2825 ; CHECK-NEXT: vmov r6, r7, d9
2826 ; CHECK-NEXT: vmov r2, r3, d0
2827 ; CHECK-NEXT: mov r0, r6
2828 ; CHECK-NEXT: mov r1, r7
2829 ; CHECK-NEXT: strd r3, r2, [sp, #4] @ 8-byte Folded Spill
2830 ; CHECK-NEXT: bl __aeabi_dcmpge
2831 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2832 ; CHECK-NEXT: mov r0, r6
2833 ; CHECK-NEXT: mov r1, r7
2834 ; CHECK-NEXT: bl __aeabi_d2ulz
2835 ; CHECK-NEXT: vldr d0, .LCPI39_1
2836 ; CHECK-NEXT: mov r5, r0
2837 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
2838 ; CHECK-NEXT: mov r10, r1
2839 ; CHECK-NEXT: vmov r9, r8, d0
2840 ; CHECK-NEXT: mov r1, r7
2841 ; CHECK-NEXT: clz r0, r0
2842 ; CHECK-NEXT: vmov r11, r4, d8
2843 ; CHECK-NEXT: lsrs r0, r0, #5
2844 ; CHECK-NEXT: str r0, [sp, #12] @ 4-byte Spill
2845 ; CHECK-NEXT: mov r0, r6
2847 ; CHECK-NEXT: movne r5, #0
2848 ; CHECK-NEXT: mov r2, r9
2849 ; CHECK-NEXT: mov r3, r8
2850 ; CHECK-NEXT: bl __aeabi_dcmpgt
2851 ; CHECK-NEXT: mov r6, r0
2852 ; CHECK-NEXT: cmp r0, #0
2853 ; CHECK-NEXT: mov r0, r11
2854 ; CHECK-NEXT: mov r1, r4
2855 ; CHECK-NEXT: mov r2, r9
2856 ; CHECK-NEXT: mov r3, r8
2858 ; CHECK-NEXT: movne r6, #1
2859 ; CHECK-NEXT: cmp r6, #0
2861 ; CHECK-NEXT: movne.w r5, #-1
2862 ; CHECK-NEXT: bl __aeabi_dcmpgt
2863 ; CHECK-NEXT: mov r7, r0
2864 ; CHECK-NEXT: cmp r0, #0
2866 ; CHECK-NEXT: movne r7, #1
2867 ; CHECK-NEXT: ldrd r3, r2, [sp, #4] @ 8-byte Folded Reload
2868 ; CHECK-NEXT: mov r0, r11
2869 ; CHECK-NEXT: mov r1, r4
2870 ; CHECK-NEXT: mov r8, r4
2871 ; CHECK-NEXT: bl __aeabi_dcmpge
2872 ; CHECK-NEXT: clz r0, r0
2873 ; CHECK-NEXT: mov r1, r8
2874 ; CHECK-NEXT: lsrs r4, r0, #5
2875 ; CHECK-NEXT: mov r0, r11
2876 ; CHECK-NEXT: bl __aeabi_d2ulz
2877 ; CHECK-NEXT: cmp r4, #0
2879 ; CHECK-NEXT: movne r0, #0
2880 ; CHECK-NEXT: cmp r7, #0
2882 ; CHECK-NEXT: movne.w r0, #-1
2883 ; CHECK-NEXT: ldr r2, [sp, #12] @ 4-byte Reload
2884 ; CHECK-NEXT: vmov q0[2], q0[0], r0, r5
2885 ; CHECK-NEXT: cmp r2, #0
2887 ; CHECK-NEXT: movne.w r10, #0
2888 ; CHECK-NEXT: cmp r6, #0
2890 ; CHECK-NEXT: movne.w r10, #-1
2891 ; CHECK-NEXT: cmp r4, #0
2893 ; CHECK-NEXT: movne r1, #0
2894 ; CHECK-NEXT: cmp r7, #0
2896 ; CHECK-NEXT: movne.w r1, #-1
2897 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r10
2898 ; CHECK-NEXT: add sp, #16
2899 ; CHECK-NEXT: vpop {d8, d9}
2900 ; CHECK-NEXT: add sp, #4
2901 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
2902 ; CHECK-NEXT: .p2align 3
2903 ; CHECK-NEXT: @ %bb.1:
2904 ; CHECK-NEXT: .LCPI39_0:
2905 ; CHECK-NEXT: .long 0 @ double 0
2906 ; CHECK-NEXT: .long 0
2907 ; CHECK-NEXT: .LCPI39_1:
2908 ; CHECK-NEXT: .long 4294967295 @ double 1.844674407370955E+19
2909 ; CHECK-NEXT: .long 1139802111
2910 %x = call <2 x i64> @llvm.fptoui.sat.v2f64.v2i64(<2 x double> %f)
2914 define arm_aapcs_vfpcc <2 x i100> @test_unsigned_v2f64_v2i100(<2 x double> %f) {
2915 ; CHECK-LABEL: test_unsigned_v2f64_v2i100:
2917 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2918 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
2919 ; CHECK-NEXT: .pad #4
2920 ; CHECK-NEXT: sub sp, #4
2921 ; CHECK-NEXT: .vsave {d8, d9}
2922 ; CHECK-NEXT: vpush {d8, d9}
2923 ; CHECK-NEXT: .pad #48
2924 ; CHECK-NEXT: sub sp, #48
2925 ; CHECK-NEXT: vmov q4, q0
2926 ; CHECK-NEXT: vldr d0, .LCPI40_0
2927 ; CHECK-NEXT: vmov r6, r5, d8
2928 ; CHECK-NEXT: mov r8, r0
2929 ; CHECK-NEXT: vmov r2, r9, d0
2930 ; CHECK-NEXT: mov r0, r6
2931 ; CHECK-NEXT: mov r1, r5
2932 ; CHECK-NEXT: mov r3, r9
2933 ; CHECK-NEXT: mov r10, r2
2934 ; CHECK-NEXT: bl __aeabi_dcmpgt
2935 ; CHECK-NEXT: vldr d0, .LCPI40_1
2936 ; CHECK-NEXT: mov r7, r0
2937 ; CHECK-NEXT: mov r0, r6
2938 ; CHECK-NEXT: mov r1, r5
2939 ; CHECK-NEXT: vmov r11, r3, d0
2940 ; CHECK-NEXT: str r3, [sp, #44] @ 4-byte Spill
2941 ; CHECK-NEXT: mov r2, r11
2942 ; CHECK-NEXT: bl __aeabi_dcmpge
2943 ; CHECK-NEXT: mov r4, r0
2944 ; CHECK-NEXT: mov r0, r6
2945 ; CHECK-NEXT: mov r1, r5
2946 ; CHECK-NEXT: str r5, [sp, #36] @ 4-byte Spill
2947 ; CHECK-NEXT: bl __fixunsdfti
2948 ; CHECK-NEXT: cmp r4, #0
2949 ; CHECK-NEXT: strd r1, r0, [sp, #20] @ 8-byte Folded Spill
2950 ; CHECK-NEXT: csel r0, r2, r4, ne
2951 ; CHECK-NEXT: str r3, [sp, #40] @ 4-byte Spill
2952 ; CHECK-NEXT: cmp r7, #0
2954 ; CHECK-NEXT: movne.w r0, #-1
2955 ; CHECK-NEXT: str.w r0, [r8, #8]
2956 ; CHECK-NEXT: mov r0, r6
2957 ; CHECK-NEXT: mov r1, r5
2958 ; CHECK-NEXT: mov r2, r10
2959 ; CHECK-NEXT: mov r3, r9
2960 ; CHECK-NEXT: bl __aeabi_dcmpgt
2961 ; CHECK-NEXT: ldr r3, [sp, #44] @ 4-byte Reload
2962 ; CHECK-NEXT: mov r4, r0
2963 ; CHECK-NEXT: mov r0, r6
2964 ; CHECK-NEXT: mov r1, r5
2965 ; CHECK-NEXT: mov r2, r11
2966 ; CHECK-NEXT: mov r7, r6
2967 ; CHECK-NEXT: bl __aeabi_dcmpge
2968 ; CHECK-NEXT: ldr r1, [sp, #20] @ 4-byte Reload
2969 ; CHECK-NEXT: cmp r0, #0
2970 ; CHECK-NEXT: mov r2, r10
2971 ; CHECK-NEXT: mov r3, r9
2972 ; CHECK-NEXT: csel r0, r1, r0, ne
2973 ; CHECK-NEXT: cmp r4, #0
2975 ; CHECK-NEXT: movne.w r0, #-1
2976 ; CHECK-NEXT: str.w r0, [r8, #4]
2977 ; CHECK-NEXT: mov r0, r7
2978 ; CHECK-NEXT: mov r1, r5
2979 ; CHECK-NEXT: mov r6, r8
2980 ; CHECK-NEXT: strd r8, r7, [sp, #28] @ 8-byte Folded Spill
2981 ; CHECK-NEXT: bl __aeabi_dcmpgt
2982 ; CHECK-NEXT: mov r4, r0
2983 ; CHECK-NEXT: mov r0, r7
2984 ; CHECK-NEXT: ldr r7, [sp, #44] @ 4-byte Reload
2985 ; CHECK-NEXT: mov r1, r5
2986 ; CHECK-NEXT: mov r2, r11
2987 ; CHECK-NEXT: mov r5, r11
2988 ; CHECK-NEXT: mov r3, r7
2989 ; CHECK-NEXT: bl __aeabi_dcmpge
2990 ; CHECK-NEXT: vmov r8, r11, d9
2991 ; CHECK-NEXT: ldr r1, [sp, #24] @ 4-byte Reload
2992 ; CHECK-NEXT: cmp r0, #0
2993 ; CHECK-NEXT: mov r2, r10
2994 ; CHECK-NEXT: csel r0, r1, r0, ne
2995 ; CHECK-NEXT: cmp r4, #0
2997 ; CHECK-NEXT: movne.w r0, #-1
2998 ; CHECK-NEXT: str r0, [r6]
2999 ; CHECK-NEXT: mov r3, r9
3000 ; CHECK-NEXT: mov r0, r8
3001 ; CHECK-NEXT: mov r1, r11
3002 ; CHECK-NEXT: bl __aeabi_dcmpgt
3003 ; CHECK-NEXT: mov r4, r0
3004 ; CHECK-NEXT: mov r0, r8
3005 ; CHECK-NEXT: mov r1, r11
3006 ; CHECK-NEXT: mov r2, r5
3007 ; CHECK-NEXT: mov r3, r7
3008 ; CHECK-NEXT: mov r6, r5
3009 ; CHECK-NEXT: str r5, [sp] @ 4-byte Spill
3010 ; CHECK-NEXT: mov r5, r7
3011 ; CHECK-NEXT: bl __aeabi_dcmpge
3012 ; CHECK-NEXT: mov r7, r0
3013 ; CHECK-NEXT: mov r0, r8
3014 ; CHECK-NEXT: mov r1, r11
3015 ; CHECK-NEXT: bl __fixunsdfti
3016 ; CHECK-NEXT: cmp r7, #0
3017 ; CHECK-NEXT: strd r0, r2, [sp, #20] @ 8-byte Folded Spill
3018 ; CHECK-NEXT: csel r0, r3, r7, ne
3019 ; CHECK-NEXT: str r1, [sp, #4] @ 4-byte Spill
3020 ; CHECK-NEXT: cmp r4, #0
3022 ; CHECK-NEXT: movne r0, #15
3023 ; CHECK-NEXT: mov r7, r0
3024 ; CHECK-NEXT: str r0, [sp, #16] @ 4-byte Spill
3025 ; CHECK-NEXT: mov r0, r8
3026 ; CHECK-NEXT: mov r1, r11
3027 ; CHECK-NEXT: mov r2, r10
3028 ; CHECK-NEXT: mov r3, r9
3029 ; CHECK-NEXT: bl __aeabi_dcmpgt
3030 ; CHECK-NEXT: mov r4, r0
3031 ; CHECK-NEXT: mov r0, r8
3032 ; CHECK-NEXT: mov r1, r11
3033 ; CHECK-NEXT: mov r2, r6
3034 ; CHECK-NEXT: mov r3, r5
3035 ; CHECK-NEXT: bl __aeabi_dcmpge
3036 ; CHECK-NEXT: ldr r1, [sp, #4] @ 4-byte Reload
3037 ; CHECK-NEXT: cmp r0, #0
3038 ; CHECK-NEXT: mov r2, r10
3039 ; CHECK-NEXT: mov r3, r9
3040 ; CHECK-NEXT: csel r0, r1, r0, ne
3041 ; CHECK-NEXT: cmp r4, #0
3043 ; CHECK-NEXT: movne.w r0, #-1
3044 ; CHECK-NEXT: vmov q0[3], q0[1], r0, r7
3045 ; CHECK-NEXT: vmov r0, s1
3046 ; CHECK-NEXT: mov r1, r11
3047 ; CHECK-NEXT: mov r6, r10
3048 ; CHECK-NEXT: str.w r10, [sp, #12] @ 4-byte Spill
3049 ; CHECK-NEXT: str.w r9, [sp, #8] @ 4-byte Spill
3050 ; CHECK-NEXT: str r0, [sp, #4] @ 4-byte Spill
3051 ; CHECK-NEXT: mov r0, r8
3052 ; CHECK-NEXT: bl __aeabi_dcmpgt
3053 ; CHECK-NEXT: ldr r7, [sp] @ 4-byte Reload
3054 ; CHECK-NEXT: mov r10, r0
3055 ; CHECK-NEXT: mov r0, r8
3056 ; CHECK-NEXT: mov r1, r11
3057 ; CHECK-NEXT: mov r3, r5
3058 ; CHECK-NEXT: mov r2, r7
3059 ; CHECK-NEXT: bl __aeabi_dcmpge
3060 ; CHECK-NEXT: ldr r1, [sp, #20] @ 4-byte Reload
3061 ; CHECK-NEXT: cmp r0, #0
3062 ; CHECK-NEXT: mov r2, r6
3063 ; CHECK-NEXT: mov r3, r9
3064 ; CHECK-NEXT: csel r4, r1, r0, ne
3065 ; CHECK-NEXT: cmp.w r10, #0
3067 ; CHECK-NEXT: movne.w r4, #-1
3068 ; CHECK-NEXT: ldr r5, [sp, #4] @ 4-byte Reload
3069 ; CHECK-NEXT: mov r10, r4
3070 ; CHECK-NEXT: mov r0, r8
3071 ; CHECK-NEXT: mov r1, r11
3072 ; CHECK-NEXT: lsrl r10, r5, #28
3073 ; CHECK-NEXT: bl __aeabi_dcmpgt
3074 ; CHECK-NEXT: mov r1, r11
3075 ; CHECK-NEXT: ldr.w r11, [sp, #44] @ 4-byte Reload
3076 ; CHECK-NEXT: mov r6, r0
3077 ; CHECK-NEXT: mov r0, r8
3078 ; CHECK-NEXT: mov r2, r7
3079 ; CHECK-NEXT: mov r9, r7
3080 ; CHECK-NEXT: mov r3, r11
3081 ; CHECK-NEXT: bl __aeabi_dcmpge
3082 ; CHECK-NEXT: ldr r1, [sp, #24] @ 4-byte Reload
3083 ; CHECK-NEXT: cmp r0, #0
3084 ; CHECK-NEXT: csel r0, r1, r0, ne
3085 ; CHECK-NEXT: cmp r6, #0
3087 ; CHECK-NEXT: movne.w r0, #-1
3088 ; CHECK-NEXT: ldr r2, [sp, #28] @ 4-byte Reload
3089 ; CHECK-NEXT: orr.w r1, r5, r0, lsl #4
3090 ; CHECK-NEXT: strd r10, r1, [r2, #16]
3091 ; CHECK-NEXT: mov r8, r2
3092 ; CHECK-NEXT: ldr r1, [sp, #16] @ 4-byte Reload
3093 ; CHECK-NEXT: and r1, r1, #15
3094 ; CHECK-NEXT: lsrl r0, r1, #28
3095 ; CHECK-NEXT: strb r0, [r2, #24]
3096 ; CHECK-NEXT: ldr r6, [sp, #32] @ 4-byte Reload
3097 ; CHECK-NEXT: ldr r7, [sp, #36] @ 4-byte Reload
3098 ; CHECK-NEXT: ldrd r3, r2, [sp, #8] @ 8-byte Folded Reload
3099 ; CHECK-NEXT: mov r0, r6
3100 ; CHECK-NEXT: mov r1, r7
3101 ; CHECK-NEXT: bl __aeabi_dcmpgt
3102 ; CHECK-NEXT: mov r10, r0
3103 ; CHECK-NEXT: mov r0, r6
3104 ; CHECK-NEXT: mov r1, r7
3105 ; CHECK-NEXT: mov r2, r9
3106 ; CHECK-NEXT: mov r3, r11
3107 ; CHECK-NEXT: bl __aeabi_dcmpge
3108 ; CHECK-NEXT: ldr r1, [sp, #40] @ 4-byte Reload
3109 ; CHECK-NEXT: cmp r0, #0
3110 ; CHECK-NEXT: csel r0, r1, r0, ne
3111 ; CHECK-NEXT: cmp.w r10, #0
3113 ; CHECK-NEXT: movne r0, #15
3114 ; CHECK-NEXT: and r0, r0, #15
3115 ; CHECK-NEXT: orr.w r0, r0, r4, lsl #4
3116 ; CHECK-NEXT: str.w r0, [r8, #12]
3117 ; CHECK-NEXT: add sp, #48
3118 ; CHECK-NEXT: vpop {d8, d9}
3119 ; CHECK-NEXT: add sp, #4
3120 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
3121 ; CHECK-NEXT: .p2align 3
3122 ; CHECK-NEXT: @ %bb.1:
3123 ; CHECK-NEXT: .LCPI40_0:
3124 ; CHECK-NEXT: .long 4294967295 @ double 1.2676506002282293E+30
3125 ; CHECK-NEXT: .long 1177550847
3126 ; CHECK-NEXT: .LCPI40_1:
3127 ; CHECK-NEXT: .long 0 @ double 0
3128 ; CHECK-NEXT: .long 0
3129 %x = call <2 x i100> @llvm.fptoui.sat.v2f64.v2i100(<2 x double> %f)
3133 define arm_aapcs_vfpcc <2 x i128> @test_unsigned_v2f64_v2i128(<2 x double> %f) {
3134 ; CHECK-LABEL: test_unsigned_v2f64_v2i128:
3136 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
3137 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
3138 ; CHECK-NEXT: .pad #4
3139 ; CHECK-NEXT: sub sp, #4
3140 ; CHECK-NEXT: .vsave {d8, d9}
3141 ; CHECK-NEXT: vpush {d8, d9}
3142 ; CHECK-NEXT: .pad #32
3143 ; CHECK-NEXT: sub sp, #32
3144 ; CHECK-NEXT: vmov q4, q0
3145 ; CHECK-NEXT: vldr d0, .LCPI41_0
3146 ; CHECK-NEXT: vmov r8, r7, d9
3147 ; CHECK-NEXT: str r0, [sp, #24] @ 4-byte Spill
3148 ; CHECK-NEXT: vmov r6, r4, d0
3149 ; CHECK-NEXT: mov r0, r8
3150 ; CHECK-NEXT: mov r1, r7
3151 ; CHECK-NEXT: mov r2, r6
3152 ; CHECK-NEXT: mov r3, r4
3153 ; CHECK-NEXT: bl __aeabi_dcmpgt
3154 ; CHECK-NEXT: vldr d0, .LCPI41_1
3155 ; CHECK-NEXT: mov r9, r0
3156 ; CHECK-NEXT: mov r0, r8
3157 ; CHECK-NEXT: mov r1, r7
3158 ; CHECK-NEXT: vmov r10, r11, d0
3159 ; CHECK-NEXT: mov r2, r10
3160 ; CHECK-NEXT: mov r3, r11
3161 ; CHECK-NEXT: bl __aeabi_dcmpge
3162 ; CHECK-NEXT: mov r5, r0
3163 ; CHECK-NEXT: mov r0, r8
3164 ; CHECK-NEXT: mov r1, r7
3165 ; CHECK-NEXT: bl __fixunsdfti
3166 ; CHECK-NEXT: cmp r5, #0
3167 ; CHECK-NEXT: strd r1, r0, [sp, #16] @ 8-byte Folded Spill
3168 ; CHECK-NEXT: csel r0, r3, r5, ne
3169 ; CHECK-NEXT: str r2, [sp, #8] @ 4-byte Spill
3170 ; CHECK-NEXT: cmp.w r9, #0
3172 ; CHECK-NEXT: movne.w r0, #-1
3173 ; CHECK-NEXT: ldr r5, [sp, #24] @ 4-byte Reload
3174 ; CHECK-NEXT: mov r1, r7
3175 ; CHECK-NEXT: mov r2, r6
3176 ; CHECK-NEXT: mov r3, r4
3177 ; CHECK-NEXT: str r0, [r5, #28]
3178 ; CHECK-NEXT: mov r0, r8
3179 ; CHECK-NEXT: str r6, [sp, #28] @ 4-byte Spill
3180 ; CHECK-NEXT: bl __aeabi_dcmpgt
3181 ; CHECK-NEXT: mov r9, r0
3182 ; CHECK-NEXT: mov r0, r8
3183 ; CHECK-NEXT: mov r1, r7
3184 ; CHECK-NEXT: mov r2, r10
3185 ; CHECK-NEXT: mov r3, r11
3186 ; CHECK-NEXT: str.w r10, [sp, #4] @ 4-byte Spill
3187 ; CHECK-NEXT: bl __aeabi_dcmpge
3188 ; CHECK-NEXT: ldr r1, [sp, #8] @ 4-byte Reload
3189 ; CHECK-NEXT: cmp r0, #0
3190 ; CHECK-NEXT: mov r2, r6
3191 ; CHECK-NEXT: mov r3, r4
3192 ; CHECK-NEXT: csel r0, r1, r0, ne
3193 ; CHECK-NEXT: cmp.w r9, #0
3195 ; CHECK-NEXT: movne.w r0, #-1
3196 ; CHECK-NEXT: str r0, [r5, #24]
3197 ; CHECK-NEXT: mov r0, r8
3198 ; CHECK-NEXT: mov r1, r7
3199 ; CHECK-NEXT: str r4, [sp] @ 4-byte Spill
3200 ; CHECK-NEXT: bl __aeabi_dcmpgt
3201 ; CHECK-NEXT: mov r9, r0
3202 ; CHECK-NEXT: mov r0, r8
3203 ; CHECK-NEXT: mov r1, r7
3204 ; CHECK-NEXT: mov r2, r10
3205 ; CHECK-NEXT: mov r3, r11
3206 ; CHECK-NEXT: bl __aeabi_dcmpge
3207 ; CHECK-NEXT: ldr r1, [sp, #16] @ 4-byte Reload
3208 ; CHECK-NEXT: cmp r0, #0
3209 ; CHECK-NEXT: mov r3, r4
3210 ; CHECK-NEXT: vmov r6, r5, d8
3211 ; CHECK-NEXT: csel r0, r1, r0, ne
3212 ; CHECK-NEXT: cmp.w r9, #0
3214 ; CHECK-NEXT: movne.w r0, #-1
3215 ; CHECK-NEXT: ldr.w r9, [sp, #24] @ 4-byte Reload
3216 ; CHECK-NEXT: mov r1, r7
3217 ; CHECK-NEXT: str.w r0, [r9, #20]
3218 ; CHECK-NEXT: mov r0, r8
3219 ; CHECK-NEXT: ldr r2, [sp, #28] @ 4-byte Reload
3220 ; CHECK-NEXT: bl __aeabi_dcmpgt
3221 ; CHECK-NEXT: ldr r4, [sp, #4] @ 4-byte Reload
3222 ; CHECK-NEXT: mov r10, r0
3223 ; CHECK-NEXT: mov r1, r7
3224 ; CHECK-NEXT: mov r0, r8
3225 ; CHECK-NEXT: mov r3, r11
3226 ; CHECK-NEXT: mov r7, r11
3227 ; CHECK-NEXT: mov r2, r4
3228 ; CHECK-NEXT: str.w r11, [sp, #12] @ 4-byte Spill
3229 ; CHECK-NEXT: bl __aeabi_dcmpge
3230 ; CHECK-NEXT: ldr r1, [sp, #20] @ 4-byte Reload
3231 ; CHECK-NEXT: cmp r0, #0
3232 ; CHECK-NEXT: mov r11, r9
3233 ; CHECK-NEXT: csel r0, r1, r0, ne
3234 ; CHECK-NEXT: cmp.w r10, #0
3236 ; CHECK-NEXT: movne.w r0, #-1
3237 ; CHECK-NEXT: str.w r0, [r9, #16]
3238 ; CHECK-NEXT: ldr.w r8, [sp, #28] @ 4-byte Reload
3239 ; CHECK-NEXT: mov r0, r6
3240 ; CHECK-NEXT: ldr.w r9, [sp] @ 4-byte Reload
3241 ; CHECK-NEXT: mov r1, r5
3242 ; CHECK-NEXT: mov r2, r8
3243 ; CHECK-NEXT: mov r3, r9
3244 ; CHECK-NEXT: bl __aeabi_dcmpgt
3245 ; CHECK-NEXT: mov r10, r0
3246 ; CHECK-NEXT: mov r0, r6
3247 ; CHECK-NEXT: mov r1, r5
3248 ; CHECK-NEXT: mov r2, r4
3249 ; CHECK-NEXT: mov r3, r7
3250 ; CHECK-NEXT: bl __aeabi_dcmpge
3251 ; CHECK-NEXT: mov r7, r0
3252 ; CHECK-NEXT: mov r0, r6
3253 ; CHECK-NEXT: mov r1, r5
3254 ; CHECK-NEXT: bl __fixunsdfti
3255 ; CHECK-NEXT: cmp r7, #0
3256 ; CHECK-NEXT: strd r1, r0, [sp, #16] @ 8-byte Folded Spill
3257 ; CHECK-NEXT: csel r0, r3, r7, ne
3258 ; CHECK-NEXT: str r2, [sp, #8] @ 4-byte Spill
3259 ; CHECK-NEXT: cmp.w r10, #0
3261 ; CHECK-NEXT: movne.w r0, #-1
3262 ; CHECK-NEXT: str.w r0, [r11, #12]
3263 ; CHECK-NEXT: mov r0, r6
3264 ; CHECK-NEXT: mov r1, r5
3265 ; CHECK-NEXT: mov r2, r8
3266 ; CHECK-NEXT: mov r3, r9
3267 ; CHECK-NEXT: mov r7, r11
3268 ; CHECK-NEXT: bl __aeabi_dcmpgt
3269 ; CHECK-NEXT: mov r2, r4
3270 ; CHECK-NEXT: mov r10, r4
3271 ; CHECK-NEXT: ldr r4, [sp, #12] @ 4-byte Reload
3272 ; CHECK-NEXT: mov r11, r0
3273 ; CHECK-NEXT: mov r0, r6
3274 ; CHECK-NEXT: mov r1, r5
3275 ; CHECK-NEXT: mov r3, r4
3276 ; CHECK-NEXT: bl __aeabi_dcmpge
3277 ; CHECK-NEXT: ldr r1, [sp, #8] @ 4-byte Reload
3278 ; CHECK-NEXT: cmp r0, #0
3279 ; CHECK-NEXT: mov r2, r8
3280 ; CHECK-NEXT: mov r3, r9
3281 ; CHECK-NEXT: csel r0, r1, r0, ne
3282 ; CHECK-NEXT: cmp.w r11, #0
3284 ; CHECK-NEXT: movne.w r0, #-1
3285 ; CHECK-NEXT: str r0, [r7, #8]
3286 ; CHECK-NEXT: mov r0, r6
3287 ; CHECK-NEXT: mov r1, r5
3288 ; CHECK-NEXT: bl __aeabi_dcmpgt
3289 ; CHECK-NEXT: mov r11, r0
3290 ; CHECK-NEXT: mov r0, r6
3291 ; CHECK-NEXT: mov r1, r5
3292 ; CHECK-NEXT: mov r2, r10
3293 ; CHECK-NEXT: mov r3, r4
3294 ; CHECK-NEXT: bl __aeabi_dcmpge
3295 ; CHECK-NEXT: ldr r1, [sp, #16] @ 4-byte Reload
3296 ; CHECK-NEXT: cmp r0, #0
3297 ; CHECK-NEXT: mov r2, r8
3298 ; CHECK-NEXT: mov r3, r9
3299 ; CHECK-NEXT: csel r0, r1, r0, ne
3300 ; CHECK-NEXT: cmp.w r11, #0
3302 ; CHECK-NEXT: movne.w r0, #-1
3303 ; CHECK-NEXT: str r0, [r7, #4]
3304 ; CHECK-NEXT: mov r0, r6
3305 ; CHECK-NEXT: mov r1, r5
3306 ; CHECK-NEXT: bl __aeabi_dcmpgt
3307 ; CHECK-NEXT: mov r8, r0
3308 ; CHECK-NEXT: mov r0, r6
3309 ; CHECK-NEXT: mov r1, r5
3310 ; CHECK-NEXT: mov r2, r10
3311 ; CHECK-NEXT: mov r3, r4
3312 ; CHECK-NEXT: bl __aeabi_dcmpge
3313 ; CHECK-NEXT: ldr r1, [sp, #20] @ 4-byte Reload
3314 ; CHECK-NEXT: cmp r0, #0
3315 ; CHECK-NEXT: csel r0, r1, r0, ne
3316 ; CHECK-NEXT: cmp.w r8, #0
3318 ; CHECK-NEXT: movne.w r0, #-1
3319 ; CHECK-NEXT: str r0, [r7]
3320 ; CHECK-NEXT: add sp, #32
3321 ; CHECK-NEXT: vpop {d8, d9}
3322 ; CHECK-NEXT: add sp, #4
3323 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
3324 ; CHECK-NEXT: .p2align 3
3325 ; CHECK-NEXT: @ %bb.1:
3326 ; CHECK-NEXT: .LCPI41_0:
3327 ; CHECK-NEXT: .long 4294967295 @ double 3.4028236692093843E+38
3328 ; CHECK-NEXT: .long 1206910975
3329 ; CHECK-NEXT: .LCPI41_1:
3330 ; CHECK-NEXT: .long 0 @ double 0
3331 ; CHECK-NEXT: .long 0
3332 %x = call <2 x i128> @llvm.fptoui.sat.v2f64.v2i128(<2 x double> %f)
3337 ; 4-Vector half to signed integer -- result size variation
3340 declare <8 x i1> @llvm.fptoui.sat.v8f16.v8i1 (<8 x half>)
3341 declare <8 x i8> @llvm.fptoui.sat.v8f16.v8i8 (<8 x half>)
3342 declare <8 x i13> @llvm.fptoui.sat.v8f16.v8i13 (<8 x half>)
3343 declare <8 x i16> @llvm.fptoui.sat.v8f16.v8i16 (<8 x half>)
3344 declare <8 x i19> @llvm.fptoui.sat.v8f16.v8i19 (<8 x half>)
3345 declare <8 x i50> @llvm.fptoui.sat.v8f16.v8i50 (<8 x half>)
3346 declare <8 x i64> @llvm.fptoui.sat.v8f16.v8i64 (<8 x half>)
3347 declare <8 x i100> @llvm.fptoui.sat.v8f16.v8i100(<8 x half>)
3348 declare <8 x i128> @llvm.fptoui.sat.v8f16.v8i128(<8 x half>)
3350 define arm_aapcs_vfpcc <8 x i1> @test_unsigned_v8f16_v8i1(<8 x half> %f) {
3351 ; CHECK-LABEL: test_unsigned_v8f16_v8i1:
3353 ; CHECK-NEXT: vldr s4, .LCPI42_0
3354 ; CHECK-NEXT: vcvtt.f32.f16 s8, s3
3355 ; CHECK-NEXT: vcvtb.f32.f16 s10, s3
3356 ; CHECK-NEXT: vcvtb.f32.f16 s3, s0
3357 ; CHECK-NEXT: vmov.f32 s6, #1.000000e+00
3358 ; CHECK-NEXT: vmaxnm.f32 s3, s3, s4
3359 ; CHECK-NEXT: vminnm.f32 s3, s3, s6
3360 ; CHECK-NEXT: vcvtt.f32.f16 s0, s0
3361 ; CHECK-NEXT: vcvt.u32.f32 s3, s3
3362 ; CHECK-NEXT: vmaxnm.f32 s0, s0, s4
3363 ; CHECK-NEXT: vminnm.f32 s0, s0, s6
3364 ; CHECK-NEXT: movs r1, #0
3365 ; CHECK-NEXT: vcvt.u32.f32 s0, s0
3366 ; CHECK-NEXT: vcvtt.f32.f16 s14, s1
3367 ; CHECK-NEXT: vcvtb.f32.f16 s1, s1
3368 ; CHECK-NEXT: vmaxnm.f32 s14, s14, s4
3369 ; CHECK-NEXT: vmaxnm.f32 s1, s1, s4
3370 ; CHECK-NEXT: vminnm.f32 s14, s14, s6
3371 ; CHECK-NEXT: vminnm.f32 s1, s1, s6
3372 ; CHECK-NEXT: vcvt.u32.f32 s14, s14
3373 ; CHECK-NEXT: vcvt.u32.f32 s1, s1
3374 ; CHECK-NEXT: vcvtt.f32.f16 s12, s2
3375 ; CHECK-NEXT: vmov r2, s3
3376 ; CHECK-NEXT: vcvtb.f32.f16 s2, s2
3377 ; CHECK-NEXT: vmaxnm.f32 s2, s2, s4
3378 ; CHECK-NEXT: vmaxnm.f32 s12, s12, s4
3379 ; CHECK-NEXT: vminnm.f32 s2, s2, s6
3380 ; CHECK-NEXT: vminnm.f32 s12, s12, s6
3381 ; CHECK-NEXT: vcvt.u32.f32 s2, s2
3382 ; CHECK-NEXT: vmaxnm.f32 s10, s10, s4
3383 ; CHECK-NEXT: vcvt.u32.f32 s12, s12
3384 ; CHECK-NEXT: vminnm.f32 s10, s10, s6
3385 ; CHECK-NEXT: vcvt.u32.f32 s10, s10
3386 ; CHECK-NEXT: vmaxnm.f32 s8, s8, s4
3387 ; CHECK-NEXT: vminnm.f32 s8, s8, s6
3388 ; CHECK-NEXT: vcvt.u32.f32 s8, s8
3389 ; CHECK-NEXT: and r2, r2, #1
3390 ; CHECK-NEXT: rsbs r2, r2, #0
3391 ; CHECK-NEXT: bfi r1, r2, #0, #1
3392 ; CHECK-NEXT: vmov r2, s0
3393 ; CHECK-NEXT: and r2, r2, #1
3394 ; CHECK-NEXT: rsbs r2, r2, #0
3395 ; CHECK-NEXT: bfi r1, r2, #1, #1
3396 ; CHECK-NEXT: vmov r2, s1
3397 ; CHECK-NEXT: and r2, r2, #1
3398 ; CHECK-NEXT: rsbs r2, r2, #0
3399 ; CHECK-NEXT: bfi r1, r2, #2, #1
3400 ; CHECK-NEXT: vmov r2, s14
3401 ; CHECK-NEXT: and r2, r2, #1
3402 ; CHECK-NEXT: rsbs r2, r2, #0
3403 ; CHECK-NEXT: bfi r1, r2, #3, #1
3404 ; CHECK-NEXT: vmov r2, s2
3405 ; CHECK-NEXT: and r2, r2, #1
3406 ; CHECK-NEXT: rsbs r2, r2, #0
3407 ; CHECK-NEXT: bfi r1, r2, #4, #1
3408 ; CHECK-NEXT: vmov r2, s12
3409 ; CHECK-NEXT: and r2, r2, #1
3410 ; CHECK-NEXT: rsbs r2, r2, #0
3411 ; CHECK-NEXT: bfi r1, r2, #5, #1
3412 ; CHECK-NEXT: vmov r2, s10
3413 ; CHECK-NEXT: and r2, r2, #1
3414 ; CHECK-NEXT: rsbs r2, r2, #0
3415 ; CHECK-NEXT: bfi r1, r2, #6, #1
3416 ; CHECK-NEXT: vmov r2, s8
3417 ; CHECK-NEXT: and r2, r2, #1
3418 ; CHECK-NEXT: rsbs r2, r2, #0
3419 ; CHECK-NEXT: bfi r1, r2, #7, #1
3420 ; CHECK-NEXT: strb r1, [r0]
3422 ; CHECK-NEXT: .p2align 2
3423 ; CHECK-NEXT: @ %bb.1:
3424 ; CHECK-NEXT: .LCPI42_0:
3425 ; CHECK-NEXT: .long 0x00000000 @ float 0
3426 %x = call <8 x i1> @llvm.fptoui.sat.v8f16.v8i1(<8 x half> %f)
3430 define arm_aapcs_vfpcc <8 x i8> @test_unsigned_v8f16_v8i8(<8 x half> %f) {
3431 ; CHECK-MVE-LABEL: test_unsigned_v8f16_v8i8:
3432 ; CHECK-MVE: @ %bb.0:
3433 ; CHECK-MVE-NEXT: vldr s6, .LCPI43_1
3434 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s10, s2
3435 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s2, s2
3436 ; CHECK-MVE-NEXT: vldr s4, .LCPI43_0
3437 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3438 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s8, s3
3439 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3440 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s12, s3
3441 ; CHECK-MVE-NEXT: vcvt.u32.f32 s5, s2
3442 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s2, s0
3443 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3444 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s0, s0
3445 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s6
3446 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3447 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s4
3448 ; CHECK-MVE-NEXT: vcvt.u32.f32 s7, s2
3449 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s2, s1
3450 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s14, s1
3451 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3452 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
3453 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s8, s6
3454 ; CHECK-MVE-NEXT: vmaxnm.f32 s10, s10, s6
3455 ; CHECK-MVE-NEXT: vmaxnm.f32 s12, s12, s6
3456 ; CHECK-MVE-NEXT: vmaxnm.f32 s14, s14, s6
3457 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3458 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s4
3459 ; CHECK-MVE-NEXT: vminnm.f32 s10, s10, s4
3460 ; CHECK-MVE-NEXT: vminnm.f32 s12, s12, s4
3461 ; CHECK-MVE-NEXT: vminnm.f32 s14, s14, s4
3462 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s2
3463 ; CHECK-MVE-NEXT: vcvt.u32.f32 s14, s14
3464 ; CHECK-MVE-NEXT: vcvt.u32.f32 s10, s10
3465 ; CHECK-MVE-NEXT: vcvt.u32.f32 s12, s12
3466 ; CHECK-MVE-NEXT: vmov r0, s0
3467 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
3468 ; CHECK-MVE-NEXT: vmov.16 q0[0], r0
3469 ; CHECK-MVE-NEXT: vmov r0, s7
3470 ; CHECK-MVE-NEXT: vmov.16 q0[1], r0
3471 ; CHECK-MVE-NEXT: vmov r0, s4
3472 ; CHECK-MVE-NEXT: vmov.16 q0[2], r0
3473 ; CHECK-MVE-NEXT: vmov r0, s14
3474 ; CHECK-MVE-NEXT: vmov.16 q0[3], r0
3475 ; CHECK-MVE-NEXT: vmov r0, s5
3476 ; CHECK-MVE-NEXT: vmov.16 q0[4], r0
3477 ; CHECK-MVE-NEXT: vmov r0, s10
3478 ; CHECK-MVE-NEXT: vmov.16 q0[5], r0
3479 ; CHECK-MVE-NEXT: vmov r0, s12
3480 ; CHECK-MVE-NEXT: vmov.16 q0[6], r0
3481 ; CHECK-MVE-NEXT: vmov r0, s8
3482 ; CHECK-MVE-NEXT: vmov.16 q0[7], r0
3483 ; CHECK-MVE-NEXT: bx lr
3484 ; CHECK-MVE-NEXT: .p2align 2
3485 ; CHECK-MVE-NEXT: @ %bb.1:
3486 ; CHECK-MVE-NEXT: .LCPI43_0:
3487 ; CHECK-MVE-NEXT: .long 0x437f0000 @ float 255
3488 ; CHECK-MVE-NEXT: .LCPI43_1:
3489 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
3491 ; CHECK-MVEFP-LABEL: test_unsigned_v8f16_v8i8:
3492 ; CHECK-MVEFP: @ %bb.0:
3493 ; CHECK-MVEFP-NEXT: vcvt.u16.f16 q0, q0
3494 ; CHECK-MVEFP-NEXT: vqmovnb.u16 q0, q0
3495 ; CHECK-MVEFP-NEXT: vmovlb.u8 q0, q0
3496 ; CHECK-MVEFP-NEXT: bx lr
3497 %x = call <8 x i8> @llvm.fptoui.sat.v8f16.v8i8(<8 x half> %f)
3501 define arm_aapcs_vfpcc <8 x i13> @test_unsigned_v8f16_v8i13(<8 x half> %f) {
3502 ; CHECK-MVE-LABEL: test_unsigned_v8f16_v8i13:
3503 ; CHECK-MVE: @ %bb.0:
3504 ; CHECK-MVE-NEXT: vldr s6, .LCPI44_1
3505 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s10, s2
3506 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s2, s2
3507 ; CHECK-MVE-NEXT: vldr s4, .LCPI44_0
3508 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3509 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s8, s3
3510 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3511 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s12, s3
3512 ; CHECK-MVE-NEXT: vcvt.u32.f32 s5, s2
3513 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s2, s0
3514 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3515 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s0, s0
3516 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s6
3517 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3518 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s4
3519 ; CHECK-MVE-NEXT: vcvt.u32.f32 s7, s2
3520 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s2, s1
3521 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s14, s1
3522 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3523 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
3524 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s8, s6
3525 ; CHECK-MVE-NEXT: vmaxnm.f32 s10, s10, s6
3526 ; CHECK-MVE-NEXT: vmaxnm.f32 s12, s12, s6
3527 ; CHECK-MVE-NEXT: vmaxnm.f32 s14, s14, s6
3528 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3529 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s4
3530 ; CHECK-MVE-NEXT: vminnm.f32 s10, s10, s4
3531 ; CHECK-MVE-NEXT: vminnm.f32 s12, s12, s4
3532 ; CHECK-MVE-NEXT: vminnm.f32 s14, s14, s4
3533 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s2
3534 ; CHECK-MVE-NEXT: vcvt.u32.f32 s14, s14
3535 ; CHECK-MVE-NEXT: vcvt.u32.f32 s10, s10
3536 ; CHECK-MVE-NEXT: vcvt.u32.f32 s12, s12
3537 ; CHECK-MVE-NEXT: vmov r0, s0
3538 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
3539 ; CHECK-MVE-NEXT: vmov.16 q0[0], r0
3540 ; CHECK-MVE-NEXT: vmov r0, s7
3541 ; CHECK-MVE-NEXT: vmov.16 q0[1], r0
3542 ; CHECK-MVE-NEXT: vmov r0, s4
3543 ; CHECK-MVE-NEXT: vmov.16 q0[2], r0
3544 ; CHECK-MVE-NEXT: vmov r0, s14
3545 ; CHECK-MVE-NEXT: vmov.16 q0[3], r0
3546 ; CHECK-MVE-NEXT: vmov r0, s5
3547 ; CHECK-MVE-NEXT: vmov.16 q0[4], r0
3548 ; CHECK-MVE-NEXT: vmov r0, s10
3549 ; CHECK-MVE-NEXT: vmov.16 q0[5], r0
3550 ; CHECK-MVE-NEXT: vmov r0, s12
3551 ; CHECK-MVE-NEXT: vmov.16 q0[6], r0
3552 ; CHECK-MVE-NEXT: vmov r0, s8
3553 ; CHECK-MVE-NEXT: vmov.16 q0[7], r0
3554 ; CHECK-MVE-NEXT: bx lr
3555 ; CHECK-MVE-NEXT: .p2align 2
3556 ; CHECK-MVE-NEXT: @ %bb.1:
3557 ; CHECK-MVE-NEXT: .LCPI44_0:
3558 ; CHECK-MVE-NEXT: .long 0x45fff800 @ float 8191
3559 ; CHECK-MVE-NEXT: .LCPI44_1:
3560 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
3562 ; CHECK-MVEFP-LABEL: test_unsigned_v8f16_v8i13:
3563 ; CHECK-MVEFP: @ %bb.0:
3564 ; CHECK-MVEFP-NEXT: vmvn.i16 q1, #0xe000
3565 ; CHECK-MVEFP-NEXT: vcvt.u16.f16 q0, q0
3566 ; CHECK-MVEFP-NEXT: vmin.u16 q0, q0, q1
3567 ; CHECK-MVEFP-NEXT: bx lr
3568 %x = call <8 x i13> @llvm.fptoui.sat.v8f16.v8i13(<8 x half> %f)
3572 define arm_aapcs_vfpcc <8 x i16> @test_unsigned_v8f16_v8i16(<8 x half> %f) {
3573 ; CHECK-MVE-LABEL: test_unsigned_v8f16_v8i16:
3574 ; CHECK-MVE: @ %bb.0:
3575 ; CHECK-MVE-NEXT: vldr s6, .LCPI45_1
3576 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s10, s2
3577 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s2, s2
3578 ; CHECK-MVE-NEXT: vldr s4, .LCPI45_0
3579 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3580 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s8, s3
3581 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3582 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s12, s3
3583 ; CHECK-MVE-NEXT: vcvt.u32.f32 s5, s2
3584 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s2, s0
3585 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3586 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s0, s0
3587 ; CHECK-MVE-NEXT: vmaxnm.f32 s0, s0, s6
3588 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3589 ; CHECK-MVE-NEXT: vminnm.f32 s0, s0, s4
3590 ; CHECK-MVE-NEXT: vcvt.u32.f32 s7, s2
3591 ; CHECK-MVE-NEXT: vcvtb.f32.f16 s2, s1
3592 ; CHECK-MVE-NEXT: vcvtt.f32.f16 s14, s1
3593 ; CHECK-MVE-NEXT: vmaxnm.f32 s2, s2, s6
3594 ; CHECK-MVE-NEXT: vcvt.u32.f32 s0, s0
3595 ; CHECK-MVE-NEXT: vmaxnm.f32 s8, s8, s6
3596 ; CHECK-MVE-NEXT: vmaxnm.f32 s10, s10, s6
3597 ; CHECK-MVE-NEXT: vmaxnm.f32 s12, s12, s6
3598 ; CHECK-MVE-NEXT: vmaxnm.f32 s14, s14, s6
3599 ; CHECK-MVE-NEXT: vminnm.f32 s2, s2, s4
3600 ; CHECK-MVE-NEXT: vminnm.f32 s8, s8, s4
3601 ; CHECK-MVE-NEXT: vminnm.f32 s10, s10, s4
3602 ; CHECK-MVE-NEXT: vminnm.f32 s12, s12, s4
3603 ; CHECK-MVE-NEXT: vminnm.f32 s14, s14, s4
3604 ; CHECK-MVE-NEXT: vcvt.u32.f32 s4, s2
3605 ; CHECK-MVE-NEXT: vcvt.u32.f32 s14, s14
3606 ; CHECK-MVE-NEXT: vcvt.u32.f32 s10, s10
3607 ; CHECK-MVE-NEXT: vcvt.u32.f32 s12, s12
3608 ; CHECK-MVE-NEXT: vmov r0, s0
3609 ; CHECK-MVE-NEXT: vcvt.u32.f32 s8, s8
3610 ; CHECK-MVE-NEXT: vmov.16 q0[0], r0
3611 ; CHECK-MVE-NEXT: vmov r0, s7
3612 ; CHECK-MVE-NEXT: vmov.16 q0[1], r0
3613 ; CHECK-MVE-NEXT: vmov r0, s4
3614 ; CHECK-MVE-NEXT: vmov.16 q0[2], r0
3615 ; CHECK-MVE-NEXT: vmov r0, s14
3616 ; CHECK-MVE-NEXT: vmov.16 q0[3], r0
3617 ; CHECK-MVE-NEXT: vmov r0, s5
3618 ; CHECK-MVE-NEXT: vmov.16 q0[4], r0
3619 ; CHECK-MVE-NEXT: vmov r0, s10
3620 ; CHECK-MVE-NEXT: vmov.16 q0[5], r0
3621 ; CHECK-MVE-NEXT: vmov r0, s12
3622 ; CHECK-MVE-NEXT: vmov.16 q0[6], r0
3623 ; CHECK-MVE-NEXT: vmov r0, s8
3624 ; CHECK-MVE-NEXT: vmov.16 q0[7], r0
3625 ; CHECK-MVE-NEXT: bx lr
3626 ; CHECK-MVE-NEXT: .p2align 2
3627 ; CHECK-MVE-NEXT: @ %bb.1:
3628 ; CHECK-MVE-NEXT: .LCPI45_0:
3629 ; CHECK-MVE-NEXT: .long 0x477fff00 @ float 65535
3630 ; CHECK-MVE-NEXT: .LCPI45_1:
3631 ; CHECK-MVE-NEXT: .long 0x00000000 @ float 0
3633 ; CHECK-MVEFP-LABEL: test_unsigned_v8f16_v8i16:
3634 ; CHECK-MVEFP: @ %bb.0:
3635 ; CHECK-MVEFP-NEXT: vcvt.u16.f16 q0, q0
3636 ; CHECK-MVEFP-NEXT: bx lr
3637 %x = call <8 x i16> @llvm.fptoui.sat.v8f16.v8i16(<8 x half> %f)
3641 define arm_aapcs_vfpcc <8 x i19> @test_unsigned_v8f16_v8i19(<8 x half> %f) {
3642 ; CHECK-LABEL: test_unsigned_v8f16_v8i19:
3644 ; CHECK-NEXT: .save {r4, r5, r6, r7, r9, r11, lr}
3645 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r9, r11, lr}
3646 ; CHECK-NEXT: vldr s4, .LCPI46_0
3647 ; CHECK-NEXT: vcvtb.f32.f16 s14, s1
3648 ; CHECK-NEXT: vldr s6, .LCPI46_1
3649 ; CHECK-NEXT: vcvtt.f32.f16 s12, s1
3650 ; CHECK-NEXT: vmaxnm.f32 s14, s14, s4
3651 ; CHECK-NEXT: vmaxnm.f32 s12, s12, s4
3652 ; CHECK-NEXT: vminnm.f32 s14, s14, s6
3653 ; CHECK-NEXT: vminnm.f32 s12, s12, s6
3654 ; CHECK-NEXT: vcvt.u32.f32 s14, s14
3655 ; CHECK-NEXT: vcvtb.f32.f16 s10, s0
3656 ; CHECK-NEXT: vcvt.u32.f32 s12, s12
3657 ; CHECK-NEXT: vcvtt.f32.f16 s0, s0
3658 ; CHECK-NEXT: vmaxnm.f32 s0, s0, s4
3659 ; CHECK-NEXT: vmaxnm.f32 s10, s10, s4
3660 ; CHECK-NEXT: vminnm.f32 s0, s0, s6
3661 ; CHECK-NEXT: vminnm.f32 s10, s10, s6
3662 ; CHECK-NEXT: vcvt.u32.f32 s0, s0
3663 ; CHECK-NEXT: movs r1, #0
3664 ; CHECK-NEXT: vcvt.u32.f32 s10, s10
3665 ; CHECK-NEXT: vcvtt.f32.f16 s8, s2
3666 ; CHECK-NEXT: vcvtb.f32.f16 s2, s2
3667 ; CHECK-NEXT: vmaxnm.f32 s8, s8, s4
3668 ; CHECK-NEXT: vmov r2, s14
3669 ; CHECK-NEXT: vmaxnm.f32 s2, s2, s4
3670 ; CHECK-NEXT: vmov r4, s12
3671 ; CHECK-NEXT: vminnm.f32 s2, s2, s6
3672 ; CHECK-NEXT: vcvt.u32.f32 s2, s2
3673 ; CHECK-NEXT: vminnm.f32 s8, s8, s6
3674 ; CHECK-NEXT: vcvt.u32.f32 s8, s8
3675 ; CHECK-NEXT: mov.w r11, #0
3676 ; CHECK-NEXT: vmov r12, s0
3677 ; CHECK-NEXT: vcvtt.f32.f16 s0, s3
3678 ; CHECK-NEXT: lsll r12, r1, #19
3679 ; CHECK-NEXT: vmaxnm.f32 s0, s0, s4
3680 ; CHECK-NEXT: vminnm.f32 s0, s0, s6
3681 ; CHECK-NEXT: movs r5, #0
3682 ; CHECK-NEXT: vcvt.u32.f32 s0, s0
3683 ; CHECK-NEXT: movs r7, #0
3684 ; CHECK-NEXT: mov.w r9, #0
3685 ; CHECK-NEXT: movs r3, #0
3686 ; CHECK-NEXT: orr.w r1, r1, r2, lsl #6
3687 ; CHECK-NEXT: lsrl r2, r5, #26
3688 ; CHECK-NEXT: orr.w r1, r1, r4, lsl #25
3689 ; CHECK-NEXT: str r1, [r0, #4]
3690 ; CHECK-NEXT: vmov r1, s10
3691 ; CHECK-NEXT: lsrl r4, r11, #7
3692 ; CHECK-NEXT: orr.w r1, r1, r12
3693 ; CHECK-NEXT: str r1, [r0]
3694 ; CHECK-NEXT: orr.w r1, r2, r4
3695 ; CHECK-NEXT: vmov r2, s2
3696 ; CHECK-NEXT: lsll r2, r7, #12
3697 ; CHECK-NEXT: vmov r4, s8
3698 ; CHECK-NEXT: orrs r2, r1
3699 ; CHECK-NEXT: movs r1, #0
3700 ; CHECK-NEXT: lsll r4, r1, #31
3701 ; CHECK-NEXT: orr.w r12, r2, r4
3702 ; CHECK-NEXT: vmov r4, s0
3703 ; CHECK-NEXT: vcvtb.f32.f16 s0, s3
3704 ; CHECK-NEXT: lsll r4, r3, #5
3705 ; CHECK-NEXT: vmaxnm.f32 s0, s0, s4
3706 ; CHECK-NEXT: vminnm.f32 s0, s0, s6
3707 ; CHECK-NEXT: vcvt.u32.f32 s0, s0
3708 ; CHECK-NEXT: vmov r2, s0
3709 ; CHECK-NEXT: mov r6, r2
3710 ; CHECK-NEXT: lsrl r6, r9, #14
3711 ; CHECK-NEXT: orr.w r3, r6, r4
3712 ; CHECK-NEXT: strh r3, [r0, #16]
3713 ; CHECK-NEXT: str.w r12, [r0, #8]
3714 ; CHECK-NEXT: lsrs r3, r3, #16
3715 ; CHECK-NEXT: strb r3, [r0, #18]
3716 ; CHECK-NEXT: orr.w r3, r5, r11
3717 ; CHECK-NEXT: orrs r3, r7
3718 ; CHECK-NEXT: orrs r1, r3
3719 ; CHECK-NEXT: orr.w r1, r1, r2, lsl #18
3720 ; CHECK-NEXT: str r1, [r0, #12]
3721 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r9, r11, pc}
3722 ; CHECK-NEXT: .p2align 2
3723 ; CHECK-NEXT: @ %bb.1:
3724 ; CHECK-NEXT: .LCPI46_0:
3725 ; CHECK-NEXT: .long 0x00000000 @ float 0
3726 ; CHECK-NEXT: .LCPI46_1:
3727 ; CHECK-NEXT: .long 0x48ffffe0 @ float 524287
3728 %x = call <8 x i19> @llvm.fptoui.sat.v8f16.v8i19(<8 x half> %f)
3732 define arm_aapcs_vfpcc <8 x i32> @test_unsigned_v8f16_v8i32_duplicate(<8 x half> %f) {
3733 ; CHECK-LABEL: test_unsigned_v8f16_v8i32_duplicate:
3735 ; CHECK-NEXT: vmovx.f16 s4, s3
3736 ; CHECK-NEXT: vmovx.f16 s6, s0
3737 ; CHECK-NEXT: vcvt.u32.f16 s8, s4
3738 ; CHECK-NEXT: vmovx.f16 s4, s2
3739 ; CHECK-NEXT: vcvt.u32.f16 s10, s4
3740 ; CHECK-NEXT: vmovx.f16 s4, s1
3741 ; CHECK-NEXT: vcvt.u32.f16 s14, s2
3742 ; CHECK-NEXT: vcvt.u32.f16 s2, s1
3743 ; CHECK-NEXT: vcvt.u32.f16 s0, s0
3744 ; CHECK-NEXT: vcvt.u32.f16 s4, s4
3745 ; CHECK-NEXT: vcvt.u32.f16 s6, s6
3746 ; CHECK-NEXT: vmov r0, s2
3747 ; CHECK-NEXT: vmov r1, s0
3748 ; CHECK-NEXT: vcvt.u32.f16 s12, s3
3749 ; CHECK-NEXT: vmov q0[2], q0[0], r1, r0
3750 ; CHECK-NEXT: vmov r0, s4
3751 ; CHECK-NEXT: vmov r1, s6
3752 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r0
3753 ; CHECK-NEXT: vmov r0, s12
3754 ; CHECK-NEXT: vmov r1, s14
3755 ; CHECK-NEXT: vmov q1[2], q1[0], r1, r0
3756 ; CHECK-NEXT: vmov r0, s8
3757 ; CHECK-NEXT: vmov r1, s10
3758 ; CHECK-NEXT: vmov q1[3], q1[1], r1, r0
3760 %x = call <8 x i32> @llvm.fptoui.sat.v8f16.v8i32(<8 x half> %f)
3764 define arm_aapcs_vfpcc <8 x i50> @test_unsigned_v8f16_v8i50(<8 x half> %f) {
3765 ; CHECK-LABEL: test_unsigned_v8f16_v8i50:
3767 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
3768 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
3769 ; CHECK-NEXT: .pad #4
3770 ; CHECK-NEXT: sub sp, #4
3771 ; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13, d14}
3772 ; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13, d14}
3773 ; CHECK-NEXT: .pad #8
3774 ; CHECK-NEXT: sub sp, #8
3775 ; CHECK-NEXT: vmov q4, q0
3776 ; CHECK-NEXT: mov r10, r0
3777 ; CHECK-NEXT: vcvtb.f32.f16 s24, s18
3778 ; CHECK-NEXT: vmov r0, s24
3779 ; CHECK-NEXT: bl __aeabi_f2ulz
3780 ; CHECK-NEXT: vcvtt.f32.f16 s28, s19
3781 ; CHECK-NEXT: mov r7, r0
3782 ; CHECK-NEXT: vmov r0, s28
3783 ; CHECK-NEXT: vcvtb.f32.f16 s22, s16
3784 ; CHECK-NEXT: vcvtb.f32.f16 s26, s19
3785 ; CHECK-NEXT: vcmp.f32 s24, #0
3786 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3787 ; CHECK-NEXT: mov r9, r1
3788 ; CHECK-NEXT: vmov r5, s22
3789 ; CHECK-NEXT: vldr s20, .LCPI48_0
3790 ; CHECK-NEXT: vmov r11, s26
3792 ; CHECK-NEXT: movlt r7, #0
3793 ; CHECK-NEXT: bl __aeabi_f2ulz
3794 ; CHECK-NEXT: vcmp.f32 s28, #0
3795 ; CHECK-NEXT: mov r4, r1
3796 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3797 ; CHECK-NEXT: vcmp.f32 s28, s20
3798 ; CHECK-NEXT: mov r6, r0
3800 ; CHECK-NEXT: movlt r4, #0
3801 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3802 ; CHECK-NEXT: mov r0, r5
3803 ; CHECK-NEXT: vcmp.f32 s24, s20
3804 ; CHECK-NEXT: itt gt
3805 ; CHECK-NEXT: movwgt r4, #65535
3806 ; CHECK-NEXT: movtgt r4, #3
3807 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3809 ; CHECK-NEXT: movgt.w r7, #-1
3810 ; CHECK-NEXT: str.w r7, [r10, #25]
3811 ; CHECK-NEXT: bl __aeabi_f2ulz
3812 ; CHECK-NEXT: vcmp.f32 s22, #0
3813 ; CHECK-NEXT: str r1, [sp, #4] @ 4-byte Spill
3814 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3815 ; CHECK-NEXT: vcmp.f32 s22, s20
3817 ; CHECK-NEXT: movlt r0, #0
3818 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3819 ; CHECK-NEXT: vcmp.f32 s28, #0
3821 ; CHECK-NEXT: movgt.w r0, #-1
3822 ; CHECK-NEXT: mov r7, r4
3823 ; CHECK-NEXT: str.w r0, [r10]
3824 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3826 ; CHECK-NEXT: movlt r6, #0
3827 ; CHECK-NEXT: vcmp.f32 s28, s20
3828 ; CHECK-NEXT: mov r0, r11
3829 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3831 ; CHECK-NEXT: movgt.w r6, #-1
3832 ; CHECK-NEXT: bfc r7, #18, #14
3833 ; CHECK-NEXT: lsll r6, r7, #22
3834 ; CHECK-NEXT: bl __aeabi_f2ulz
3835 ; CHECK-NEXT: vcmp.f32 s26, #0
3836 ; CHECK-NEXT: mov r5, r0
3837 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3838 ; CHECK-NEXT: vcmp.f32 s26, s20
3840 ; CHECK-NEXT: movlt r5, #0
3841 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3842 ; CHECK-NEXT: vcmp.f32 s26, #0
3844 ; CHECK-NEXT: movgt.w r5, #-1
3845 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3846 ; CHECK-NEXT: vcmp.f32 s26, s20
3848 ; CHECK-NEXT: movlt r1, #0
3849 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3850 ; CHECK-NEXT: itt gt
3851 ; CHECK-NEXT: movwgt r1, #65535
3852 ; CHECK-NEXT: movtgt r1, #3
3853 ; CHECK-NEXT: mov r2, r5
3854 ; CHECK-NEXT: bfc r1, #18, #14
3855 ; CHECK-NEXT: vcvtt.f32.f16 s26, s18
3856 ; CHECK-NEXT: lsrl r2, r1, #28
3857 ; CHECK-NEXT: orr.w r0, r1, r7
3858 ; CHECK-NEXT: str.w r0, [r10, #45]
3859 ; CHECK-NEXT: vmov r0, s26
3860 ; CHECK-NEXT: orrs r6, r2
3861 ; CHECK-NEXT: bl __aeabi_f2ulz
3862 ; CHECK-NEXT: vcmp.f32 s26, #0
3863 ; CHECK-NEXT: mov r7, r0
3864 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3866 ; CHECK-NEXT: movlt r1, #0
3867 ; CHECK-NEXT: vcmp.f32 s26, s20
3868 ; CHECK-NEXT: vcvtb.f32.f16 s18, s17
3869 ; CHECK-NEXT: lsrs r0, r4, #10
3870 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3871 ; CHECK-NEXT: itt gt
3872 ; CHECK-NEXT: movwgt r1, #65535
3873 ; CHECK-NEXT: movtgt r1, #3
3874 ; CHECK-NEXT: str.w r6, [r10, #41]
3875 ; CHECK-NEXT: strb.w r0, [r10, #49]
3876 ; CHECK-NEXT: vmov r0, s18
3877 ; CHECK-NEXT: vcmp.f32 s26, #0
3878 ; CHECK-NEXT: bfc r1, #18, #14
3879 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3881 ; CHECK-NEXT: movlt r7, #0
3882 ; CHECK-NEXT: vcmp.f32 s26, s20
3883 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3885 ; CHECK-NEXT: movgt.w r7, #-1
3886 ; CHECK-NEXT: mov r4, r7
3887 ; CHECK-NEXT: lsrl r4, r1, #14
3888 ; CHECK-NEXT: orr.w r6, r1, r5, lsl #4
3889 ; CHECK-NEXT: bl __aeabi_f2ulz
3890 ; CHECK-NEXT: vcvtt.f32.f16 s26, s17
3891 ; CHECK-NEXT: mov r11, r0
3892 ; CHECK-NEXT: vmov r0, s26
3893 ; CHECK-NEXT: mov r5, r1
3894 ; CHECK-NEXT: vcmp.f32 s18, #0
3895 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3897 ; CHECK-NEXT: movlt r5, #0
3898 ; CHECK-NEXT: vcmp.f32 s18, s20
3899 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3900 ; CHECK-NEXT: itt gt
3901 ; CHECK-NEXT: movwgt r5, #65535
3902 ; CHECK-NEXT: movtgt r5, #3
3903 ; CHECK-NEXT: str.w r6, [r10, #37]
3904 ; CHECK-NEXT: str.w r4, [r10, #33]
3905 ; CHECK-NEXT: bl __aeabi_f2ulz
3906 ; CHECK-NEXT: vcmp.f32 s26, #0
3907 ; CHECK-NEXT: mov r6, r1
3908 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3909 ; CHECK-NEXT: vcmp.f32 s26, s20
3911 ; CHECK-NEXT: movlt r6, #0
3912 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3913 ; CHECK-NEXT: vcmp.f32 s24, #0
3914 ; CHECK-NEXT: itt gt
3915 ; CHECK-NEXT: movwgt r6, #65535
3916 ; CHECK-NEXT: movtgt r6, #3
3917 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3919 ; CHECK-NEXT: movlt.w r9, #0
3920 ; CHECK-NEXT: vcmp.f32 s24, s20
3921 ; CHECK-NEXT: mov r4, r0
3922 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3923 ; CHECK-NEXT: itt gt
3924 ; CHECK-NEXT: movwgt r9, #65535
3925 ; CHECK-NEXT: movtgt r9, #3
3926 ; CHECK-NEXT: bfc r9, #18, #14
3927 ; CHECK-NEXT: vcvtt.f32.f16 s16, s16
3928 ; CHECK-NEXT: orr.w r0, r9, r7, lsl #18
3929 ; CHECK-NEXT: str.w r0, [r10, #29]
3930 ; CHECK-NEXT: vmov r0, s16
3931 ; CHECK-NEXT: mov r1, r6
3932 ; CHECK-NEXT: vcmp.f32 s26, #0
3933 ; CHECK-NEXT: bfc r1, #18, #14
3934 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3935 ; CHECK-NEXT: vcmp.f32 s26, s20
3937 ; CHECK-NEXT: movlt r4, #0
3938 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3939 ; CHECK-NEXT: vcmp.f32 s18, #0
3941 ; CHECK-NEXT: movgt.w r4, #-1
3942 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3944 ; CHECK-NEXT: movlt.w r11, #0
3945 ; CHECK-NEXT: vcmp.f32 s18, s20
3946 ; CHECK-NEXT: bfc r5, #18, #14
3947 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3949 ; CHECK-NEXT: movgt.w r11, #-1
3950 ; CHECK-NEXT: mov r8, r11
3951 ; CHECK-NEXT: vcmp.f32 s22, #0
3952 ; CHECK-NEXT: ldr r7, [sp, #4] @ 4-byte Reload
3953 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3954 ; CHECK-NEXT: lsll r4, r1, #22
3955 ; CHECK-NEXT: lsrl r8, r5, #28
3957 ; CHECK-NEXT: movlt r7, #0
3958 ; CHECK-NEXT: vcmp.f32 s22, s20
3959 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3960 ; CHECK-NEXT: itt gt
3961 ; CHECK-NEXT: movwgt r7, #65535
3962 ; CHECK-NEXT: movtgt r7, #3
3963 ; CHECK-NEXT: orrs r1, r5
3964 ; CHECK-NEXT: str.w r1, [r10, #20]
3965 ; CHECK-NEXT: bl __aeabi_f2ulz
3966 ; CHECK-NEXT: vcmp.f32 s16, #0
3967 ; CHECK-NEXT: orr.w r2, r8, r4
3968 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3970 ; CHECK-NEXT: movlt r1, #0
3971 ; CHECK-NEXT: vcmp.f32 s16, s20
3972 ; CHECK-NEXT: bfc r7, #18, #14
3973 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3974 ; CHECK-NEXT: itt gt
3975 ; CHECK-NEXT: movwgt r1, #65535
3976 ; CHECK-NEXT: movtgt r1, #3
3977 ; CHECK-NEXT: str.w r2, [r10, #16]
3978 ; CHECK-NEXT: lsrs r2, r6, #10
3979 ; CHECK-NEXT: vcmp.f32 s16, #0
3980 ; CHECK-NEXT: strb.w r2, [r10, #24]
3981 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3983 ; CHECK-NEXT: movlt r0, #0
3984 ; CHECK-NEXT: vcmp.f32 s16, s20
3985 ; CHECK-NEXT: bfc r1, #18, #14
3986 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
3988 ; CHECK-NEXT: movgt.w r0, #-1
3989 ; CHECK-NEXT: mov r2, r0
3990 ; CHECK-NEXT: orr.w r0, r7, r0, lsl #18
3991 ; CHECK-NEXT: lsrl r2, r1, #14
3992 ; CHECK-NEXT: orr.w r1, r1, r11, lsl #4
3993 ; CHECK-NEXT: strd r2, r1, [r10, #8]
3994 ; CHECK-NEXT: str.w r0, [r10, #4]
3995 ; CHECK-NEXT: add sp, #8
3996 ; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13, d14}
3997 ; CHECK-NEXT: add sp, #4
3998 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
3999 ; CHECK-NEXT: .p2align 2
4000 ; CHECK-NEXT: @ %bb.1:
4001 ; CHECK-NEXT: .LCPI48_0:
4002 ; CHECK-NEXT: .long 0x587fffff @ float 1.12589984E+15
4003 %x = call <8 x i50> @llvm.fptoui.sat.v8f16.v8i50(<8 x half> %f)
4007 define arm_aapcs_vfpcc <8 x i64> @test_unsigned_v8f16_v8i64(<8 x half> %f) {
4008 ; CHECK-LABEL: test_unsigned_v8f16_v8i64:
4010 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
4011 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
4012 ; CHECK-NEXT: .pad #4
4013 ; CHECK-NEXT: sub sp, #4
4014 ; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13, d14, d15}
4015 ; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13, d14, d15}
4016 ; CHECK-NEXT: vmov q4, q0
4017 ; CHECK-NEXT: vcvtt.f32.f16 s20, s19
4018 ; CHECK-NEXT: vmov r0, s20
4019 ; CHECK-NEXT: bl __aeabi_f2ulz
4020 ; CHECK-NEXT: vcvtb.f32.f16 s22, s19
4021 ; CHECK-NEXT: mov r9, r0
4022 ; CHECK-NEXT: vmov r0, s22
4023 ; CHECK-NEXT: vldr s28, .LCPI49_0
4024 ; CHECK-NEXT: vcmp.f32 s20, #0
4025 ; CHECK-NEXT: vcvtt.f32.f16 s24, s16
4026 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4027 ; CHECK-NEXT: vcvtb.f32.f16 s16, s16
4029 ; CHECK-NEXT: movlt.w r9, #0
4030 ; CHECK-NEXT: vcmp.f32 s20, s28
4031 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4032 ; CHECK-NEXT: mov r8, r1
4033 ; CHECK-NEXT: vmov r5, s24
4035 ; CHECK-NEXT: movgt.w r9, #-1
4036 ; CHECK-NEXT: vmov r4, s16
4037 ; CHECK-NEXT: bl __aeabi_f2ulz
4038 ; CHECK-NEXT: vcmp.f32 s22, #0
4039 ; CHECK-NEXT: mov r11, r0
4040 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4041 ; CHECK-NEXT: vcmp.f32 s22, s28
4043 ; CHECK-NEXT: movlt.w r11, #0
4044 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4045 ; CHECK-NEXT: vcmp.f32 s20, #0
4047 ; CHECK-NEXT: movgt.w r11, #-1
4048 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4049 ; CHECK-NEXT: vcmp.f32 s20, s28
4051 ; CHECK-NEXT: movlt.w r8, #0
4052 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4053 ; CHECK-NEXT: mov r10, r1
4054 ; CHECK-NEXT: vcmp.f32 s22, #0
4056 ; CHECK-NEXT: movgt.w r8, #-1
4057 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4058 ; CHECK-NEXT: mov r0, r5
4060 ; CHECK-NEXT: movlt.w r10, #0
4061 ; CHECK-NEXT: vcmp.f32 s22, s28
4062 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4064 ; CHECK-NEXT: movgt.w r10, #-1
4065 ; CHECK-NEXT: bl __aeabi_f2ulz
4066 ; CHECK-NEXT: mov r6, r0
4067 ; CHECK-NEXT: vcmp.f32 s24, #0
4068 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4069 ; CHECK-NEXT: mov r0, r4
4071 ; CHECK-NEXT: movlt r6, #0
4072 ; CHECK-NEXT: vcmp.f32 s24, s28
4073 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4074 ; CHECK-NEXT: mov r5, r1
4076 ; CHECK-NEXT: movgt.w r6, #-1
4077 ; CHECK-NEXT: bl __aeabi_f2ulz
4078 ; CHECK-NEXT: vcvtt.f32.f16 s30, s17
4079 ; CHECK-NEXT: mov r7, r1
4080 ; CHECK-NEXT: vmov r1, s30
4081 ; CHECK-NEXT: vcmp.f32 s16, #0
4082 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4084 ; CHECK-NEXT: movlt r0, #0
4085 ; CHECK-NEXT: vcmp.f32 s16, s28
4086 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4088 ; CHECK-NEXT: movgt.w r0, #-1
4089 ; CHECK-NEXT: vmov q5[2], q5[0], r0, r6
4090 ; CHECK-NEXT: mov r0, r1
4091 ; CHECK-NEXT: bl __aeabi_f2ulz
4092 ; CHECK-NEXT: vcmp.f32 s30, #0
4093 ; CHECK-NEXT: mov r6, r0
4094 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4095 ; CHECK-NEXT: vcmp.f32 s30, s28
4097 ; CHECK-NEXT: movlt r6, #0
4098 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4099 ; CHECK-NEXT: vcmp.f32 s24, #0
4101 ; CHECK-NEXT: movgt.w r6, #-1
4102 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4103 ; CHECK-NEXT: vcmp.f32 s24, s28
4105 ; CHECK-NEXT: movlt r5, #0
4106 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4107 ; CHECK-NEXT: vcmp.f32 s16, #0
4109 ; CHECK-NEXT: movgt.w r5, #-1
4110 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4111 ; CHECK-NEXT: vcmp.f32 s16, s28
4112 ; CHECK-NEXT: vcvtb.f32.f16 s16, s17
4114 ; CHECK-NEXT: movlt r7, #0
4115 ; CHECK-NEXT: vmov r0, s16
4116 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4118 ; CHECK-NEXT: movgt.w r7, #-1
4119 ; CHECK-NEXT: mov r4, r1
4120 ; CHECK-NEXT: vmov q5[3], q5[1], r7, r5
4121 ; CHECK-NEXT: bl __aeabi_f2ulz
4122 ; CHECK-NEXT: vcvtt.f32.f16 s17, s18
4123 ; CHECK-NEXT: mov r7, r1
4124 ; CHECK-NEXT: vmov r1, s17
4125 ; CHECK-NEXT: vcmp.f32 s16, #0
4126 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4128 ; CHECK-NEXT: movlt r0, #0
4129 ; CHECK-NEXT: vcmp.f32 s16, s28
4130 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4132 ; CHECK-NEXT: movgt.w r0, #-1
4133 ; CHECK-NEXT: vmov q6[2], q6[0], r0, r6
4134 ; CHECK-NEXT: mov r0, r1
4135 ; CHECK-NEXT: bl __aeabi_f2ulz
4136 ; CHECK-NEXT: vcmp.f32 s17, #0
4137 ; CHECK-NEXT: mov r6, r0
4138 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4139 ; CHECK-NEXT: vcmp.f32 s17, s28
4141 ; CHECK-NEXT: movlt r6, #0
4142 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4143 ; CHECK-NEXT: vcmp.f32 s30, #0
4145 ; CHECK-NEXT: movgt.w r6, #-1
4146 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4147 ; CHECK-NEXT: vcmp.f32 s30, s28
4149 ; CHECK-NEXT: movlt r4, #0
4150 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4151 ; CHECK-NEXT: vcmp.f32 s16, #0
4153 ; CHECK-NEXT: movgt.w r4, #-1
4154 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4155 ; CHECK-NEXT: vcmp.f32 s16, s28
4156 ; CHECK-NEXT: vcvtb.f32.f16 s16, s18
4158 ; CHECK-NEXT: movlt r7, #0
4159 ; CHECK-NEXT: vmov r0, s16
4160 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4162 ; CHECK-NEXT: movgt.w r7, #-1
4163 ; CHECK-NEXT: mov r5, r1
4164 ; CHECK-NEXT: vmov q6[3], q6[1], r7, r4
4165 ; CHECK-NEXT: bl __aeabi_f2ulz
4166 ; CHECK-NEXT: vcmp.f32 s16, #0
4167 ; CHECK-NEXT: vmov q3[2], q3[0], r11, r9
4168 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4169 ; CHECK-NEXT: vcmp.f32 s16, s28
4171 ; CHECK-NEXT: movlt r0, #0
4172 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4173 ; CHECK-NEXT: vcmp.f32 s17, #0
4175 ; CHECK-NEXT: movgt.w r0, #-1
4176 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4177 ; CHECK-NEXT: vcmp.f32 s17, s28
4179 ; CHECK-NEXT: movlt r5, #0
4180 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4181 ; CHECK-NEXT: vcmp.f32 s16, #0
4183 ; CHECK-NEXT: movgt.w r5, #-1
4184 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4186 ; CHECK-NEXT: movlt r1, #0
4187 ; CHECK-NEXT: vcmp.f32 s16, s28
4188 ; CHECK-NEXT: vmov q2[2], q2[0], r0, r6
4189 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4191 ; CHECK-NEXT: movgt.w r1, #-1
4192 ; CHECK-NEXT: vmov q2[3], q2[1], r1, r5
4193 ; CHECK-NEXT: vmov q3[3], q3[1], r10, r8
4194 ; CHECK-NEXT: vmov q0, q5
4195 ; CHECK-NEXT: vmov q1, q6
4196 ; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13, d14, d15}
4197 ; CHECK-NEXT: add sp, #4
4198 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
4199 ; CHECK-NEXT: .p2align 2
4200 ; CHECK-NEXT: @ %bb.1:
4201 ; CHECK-NEXT: .LCPI49_0:
4202 ; CHECK-NEXT: .long 0x5f7fffff @ float 1.8446743E+19
4203 %x = call <8 x i64> @llvm.fptoui.sat.v8f16.v8i64(<8 x half> %f)
4207 define arm_aapcs_vfpcc <8 x i100> @test_unsigned_v8f16_v8i100(<8 x half> %f) {
4208 ; CHECK-LABEL: test_unsigned_v8f16_v8i100:
4210 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr}
4211 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr}
4212 ; CHECK-NEXT: .pad #4
4213 ; CHECK-NEXT: sub sp, #4
4214 ; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13, d14, d15}
4215 ; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13, d14, d15}
4216 ; CHECK-NEXT: .pad #32
4217 ; CHECK-NEXT: sub sp, #32
4218 ; CHECK-NEXT: vmov q4, q0
4219 ; CHECK-NEXT: mov r9, r0
4220 ; CHECK-NEXT: vcvtb.f32.f16 s30, s19
4221 ; CHECK-NEXT: vcvtb.f32.f16 s28, s18
4222 ; CHECK-NEXT: vmov r0, s30
4223 ; CHECK-NEXT: vcvtt.f32.f16 s22, s19
4224 ; CHECK-NEXT: vcvtb.f32.f16 s24, s16
4225 ; CHECK-NEXT: vcvtb.f32.f16 s26, s17
4226 ; CHECK-NEXT: vldr s20, .LCPI50_1
4227 ; CHECK-NEXT: vmov r8, s22
4228 ; CHECK-NEXT: vmov r5, s28
4229 ; CHECK-NEXT: vcvtt.f32.f16 s18, s18
4230 ; CHECK-NEXT: vmov r4, s24
4231 ; CHECK-NEXT: vmov r6, s26
4232 ; CHECK-NEXT: bl __fixunssfti
4233 ; CHECK-NEXT: vcmp.f32 s30, #0
4234 ; CHECK-NEXT: mov r7, r3
4235 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4236 ; CHECK-NEXT: vcmp.f32 s30, s20
4238 ; CHECK-NEXT: movlt r2, #0
4239 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4240 ; CHECK-NEXT: vcmp.f32 s30, #0
4242 ; CHECK-NEXT: movgt.w r2, #-1
4243 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4244 ; CHECK-NEXT: vcmp.f32 s30, s20
4245 ; CHECK-NEXT: str.w r2, [r9, #83]
4247 ; CHECK-NEXT: movlt r1, #0
4248 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4249 ; CHECK-NEXT: vcmp.f32 s30, #0
4251 ; CHECK-NEXT: movgt.w r1, #-1
4252 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4253 ; CHECK-NEXT: str.w r1, [r9, #79]
4255 ; CHECK-NEXT: movlt r0, #0
4256 ; CHECK-NEXT: vcmp.f32 s30, s20
4257 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4259 ; CHECK-NEXT: movgt.w r0, #-1
4260 ; CHECK-NEXT: str.w r0, [r9, #75]
4261 ; CHECK-NEXT: mov r0, r5
4262 ; CHECK-NEXT: bl __fixunssfti
4263 ; CHECK-NEXT: vcmp.f32 s28, #0
4264 ; CHECK-NEXT: mov r5, r3
4265 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4266 ; CHECK-NEXT: vcmp.f32 s28, s20
4268 ; CHECK-NEXT: movlt r2, #0
4269 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4270 ; CHECK-NEXT: vcmp.f32 s28, #0
4272 ; CHECK-NEXT: movgt.w r2, #-1
4273 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4274 ; CHECK-NEXT: vcmp.f32 s28, s20
4275 ; CHECK-NEXT: str.w r2, [r9, #58]
4277 ; CHECK-NEXT: movlt r1, #0
4278 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4279 ; CHECK-NEXT: vcmp.f32 s28, #0
4281 ; CHECK-NEXT: movgt.w r1, #-1
4282 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4283 ; CHECK-NEXT: str.w r1, [r9, #54]
4285 ; CHECK-NEXT: movlt r0, #0
4286 ; CHECK-NEXT: vcmp.f32 s28, s20
4287 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4289 ; CHECK-NEXT: movgt.w r0, #-1
4290 ; CHECK-NEXT: str.w r0, [r9, #50]
4291 ; CHECK-NEXT: mov r0, r6
4292 ; CHECK-NEXT: bl __fixunssfti
4293 ; CHECK-NEXT: vcmp.f32 s26, #0
4294 ; CHECK-NEXT: str r3, [sp, #24] @ 4-byte Spill
4295 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4296 ; CHECK-NEXT: vcmp.f32 s26, s20
4298 ; CHECK-NEXT: movlt r2, #0
4299 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4300 ; CHECK-NEXT: vcmp.f32 s26, #0
4302 ; CHECK-NEXT: movgt.w r2, #-1
4303 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4304 ; CHECK-NEXT: vcmp.f32 s26, s20
4305 ; CHECK-NEXT: str.w r2, [r9, #33]
4307 ; CHECK-NEXT: movlt r1, #0
4308 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4309 ; CHECK-NEXT: vcmp.f32 s26, #0
4311 ; CHECK-NEXT: movgt.w r1, #-1
4312 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4313 ; CHECK-NEXT: str.w r1, [r9, #29]
4315 ; CHECK-NEXT: movlt r0, #0
4316 ; CHECK-NEXT: vcmp.f32 s26, s20
4317 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4319 ; CHECK-NEXT: movgt.w r0, #-1
4320 ; CHECK-NEXT: str.w r0, [r9, #25]
4321 ; CHECK-NEXT: mov r0, r4
4322 ; CHECK-NEXT: bl __fixunssfti
4323 ; CHECK-NEXT: vcmp.f32 s24, #0
4324 ; CHECK-NEXT: mov r4, r3
4325 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4326 ; CHECK-NEXT: vcmp.f32 s24, s20
4328 ; CHECK-NEXT: movlt r2, #0
4329 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4330 ; CHECK-NEXT: vcmp.f32 s24, #0
4332 ; CHECK-NEXT: movgt.w r2, #-1
4333 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4334 ; CHECK-NEXT: vcmp.f32 s24, s20
4335 ; CHECK-NEXT: str.w r2, [r9, #8]
4337 ; CHECK-NEXT: movlt r1, #0
4338 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4339 ; CHECK-NEXT: vcmp.f32 s24, #0
4341 ; CHECK-NEXT: movgt.w r1, #-1
4342 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4343 ; CHECK-NEXT: str.w r1, [r9, #4]
4345 ; CHECK-NEXT: movlt r0, #0
4346 ; CHECK-NEXT: vcmp.f32 s24, s20
4347 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4349 ; CHECK-NEXT: movgt.w r0, #-1
4350 ; CHECK-NEXT: str.w r0, [r9]
4351 ; CHECK-NEXT: mov r0, r8
4352 ; CHECK-NEXT: bl __fixunssfti
4353 ; CHECK-NEXT: vcmp.f32 s22, #0
4354 ; CHECK-NEXT: mov r6, r0
4355 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4356 ; CHECK-NEXT: vcmp.f32 s22, s20
4357 ; CHECK-NEXT: str r3, [sp, #12] @ 4-byte Spill
4359 ; CHECK-NEXT: movlt r6, #0
4360 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4361 ; CHECK-NEXT: vcmp.f32 s30, #0
4363 ; CHECK-NEXT: movgt.w r6, #-1
4364 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4366 ; CHECK-NEXT: movlt r7, #0
4367 ; CHECK-NEXT: vcmp.f32 s30, s20
4368 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4370 ; CHECK-NEXT: movgt r7, #15
4371 ; CHECK-NEXT: and r0, r7, #15
4372 ; CHECK-NEXT: mov r11, r1
4373 ; CHECK-NEXT: orr.w r1, r0, r6, lsl #4
4374 ; CHECK-NEXT: vmov r0, s18
4375 ; CHECK-NEXT: mov r10, r2
4376 ; CHECK-NEXT: str.w r1, [r9, #87]
4377 ; CHECK-NEXT: bl __fixunssfti
4378 ; CHECK-NEXT: vcmp.f32 s18, #0
4379 ; CHECK-NEXT: mov r8, r0
4380 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4381 ; CHECK-NEXT: vcmp.f32 s18, s20
4382 ; CHECK-NEXT: str r1, [sp, #8] @ 4-byte Spill
4383 ; CHECK-NEXT: mov r7, r3
4384 ; CHECK-NEXT: str r2, [sp, #20] @ 4-byte Spill
4386 ; CHECK-NEXT: movlt.w r8, #0
4387 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4388 ; CHECK-NEXT: vcmp.f32 s28, #0
4390 ; CHECK-NEXT: movgt.w r8, #-1
4391 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4392 ; CHECK-NEXT: vcmp.f32 s28, s20
4394 ; CHECK-NEXT: movlt r5, #0
4395 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4397 ; CHECK-NEXT: movgt r5, #15
4398 ; CHECK-NEXT: and r0, r5, #15
4399 ; CHECK-NEXT: vcvtt.f32.f16 s28, s17
4400 ; CHECK-NEXT: orr.w r0, r0, r8, lsl #4
4401 ; CHECK-NEXT: str.w r0, [r9, #62]
4402 ; CHECK-NEXT: vmov r0, s28
4403 ; CHECK-NEXT: bl __fixunssfti
4404 ; CHECK-NEXT: vcmp.f32 s28, #0
4405 ; CHECK-NEXT: str r1, [sp, #16] @ 4-byte Spill
4406 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4407 ; CHECK-NEXT: str r2, [sp, #28] @ 4-byte Spill
4408 ; CHECK-NEXT: str r3, [sp, #4] @ 4-byte Spill
4410 ; CHECK-NEXT: movlt r0, #0
4411 ; CHECK-NEXT: vcmp.f32 s28, s20
4412 ; CHECK-NEXT: vcvtt.f32.f16 s16, s16
4413 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4415 ; CHECK-NEXT: movgt.w r0, #-1
4416 ; CHECK-NEXT: vcmp.f32 s26, #0
4417 ; CHECK-NEXT: mov r1, r0
4418 ; CHECK-NEXT: str r0, [sp] @ 4-byte Spill
4419 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4420 ; CHECK-NEXT: ldr r0, [sp, #24] @ 4-byte Reload
4421 ; CHECK-NEXT: vcmp.f32 s26, s20
4423 ; CHECK-NEXT: movlt r0, #0
4424 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4426 ; CHECK-NEXT: movgt r0, #15
4427 ; CHECK-NEXT: and r0, r0, #15
4428 ; CHECK-NEXT: orr.w r0, r0, r1, lsl #4
4429 ; CHECK-NEXT: str.w r0, [r9, #37]
4430 ; CHECK-NEXT: vmov r0, s16
4431 ; CHECK-NEXT: bl __fixunssfti
4432 ; CHECK-NEXT: vcmp.f32 s16, #0
4433 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4434 ; CHECK-NEXT: vcmp.f32 s16, s20
4436 ; CHECK-NEXT: movlt r0, #0
4437 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4438 ; CHECK-NEXT: vcmp.f32 s24, #0
4440 ; CHECK-NEXT: movgt.w r0, #-1
4441 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4443 ; CHECK-NEXT: movlt r4, #0
4444 ; CHECK-NEXT: vcmp.f32 s24, s20
4445 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4447 ; CHECK-NEXT: movgt r4, #15
4448 ; CHECK-NEXT: and r5, r4, #15
4449 ; CHECK-NEXT: vcmp.f32 s22, #0
4450 ; CHECK-NEXT: orr.w r5, r5, r0, lsl #4
4451 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4452 ; CHECK-NEXT: str.w r5, [r9, #12]
4454 ; CHECK-NEXT: movlt.w r11, #0
4455 ; CHECK-NEXT: vcmp.f32 s22, s20
4456 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4458 ; CHECK-NEXT: movgt.w r11, #-1
4459 ; CHECK-NEXT: vcmp.f32 s22, #0
4460 ; CHECK-NEXT: lsrl r6, r11, #28
4461 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4463 ; CHECK-NEXT: movlt.w r10, #0
4464 ; CHECK-NEXT: vcmp.f32 s22, s20
4465 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4467 ; CHECK-NEXT: movgt.w r10, #-1
4468 ; CHECK-NEXT: orr.w r5, r11, r10, lsl #4
4469 ; CHECK-NEXT: str.w r5, [r9, #95]
4470 ; CHECK-NEXT: str.w r6, [r9, #91]
4471 ; CHECK-NEXT: vcmp.f32 s22, #0
4472 ; CHECK-NEXT: ldr r6, [sp, #12] @ 4-byte Reload
4473 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4475 ; CHECK-NEXT: movlt r6, #0
4476 ; CHECK-NEXT: vcmp.f32 s22, s20
4477 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4479 ; CHECK-NEXT: movgt r6, #15
4480 ; CHECK-NEXT: and r5, r6, #15
4481 ; CHECK-NEXT: vcmp.f32 s18, #0
4482 ; CHECK-NEXT: lsrl r10, r5, #28
4483 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4484 ; CHECK-NEXT: strb.w r10, [r9, #99]
4486 ; CHECK-NEXT: movlt r7, #0
4487 ; CHECK-NEXT: vcmp.f32 s18, s20
4488 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4490 ; CHECK-NEXT: movgt r7, #15
4491 ; CHECK-NEXT: vcmp.f32 s18, #0
4492 ; CHECK-NEXT: ldr r6, [sp, #8] @ 4-byte Reload
4493 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4495 ; CHECK-NEXT: movlt r6, #0
4496 ; CHECK-NEXT: vcmp.f32 s18, s20
4497 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4499 ; CHECK-NEXT: movgt.w r6, #-1
4500 ; CHECK-NEXT: vmov q0[3], q0[1], r6, r7
4501 ; CHECK-NEXT: vcmp.f32 s18, #0
4502 ; CHECK-NEXT: vmov r5, s1
4503 ; CHECK-NEXT: ldr r4, [sp, #20] @ 4-byte Reload
4504 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4505 ; CHECK-NEXT: lsrl r8, r5, #28
4507 ; CHECK-NEXT: movlt r4, #0
4508 ; CHECK-NEXT: vcmp.f32 s18, s20
4509 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4511 ; CHECK-NEXT: movgt.w r4, #-1
4512 ; CHECK-NEXT: orr.w r6, r5, r4, lsl #4
4513 ; CHECK-NEXT: and r5, r7, #15
4514 ; CHECK-NEXT: lsrl r4, r5, #28
4515 ; CHECK-NEXT: str.w r6, [r9, #70]
4516 ; CHECK-NEXT: str.w r8, [r9, #66]
4517 ; CHECK-NEXT: vcmp.f32 s28, #0
4518 ; CHECK-NEXT: strb.w r4, [r9, #74]
4519 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4520 ; CHECK-NEXT: ldr r7, [sp, #4] @ 4-byte Reload
4521 ; CHECK-NEXT: vcmp.f32 s28, s20
4523 ; CHECK-NEXT: movlt r7, #0
4524 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4526 ; CHECK-NEXT: movgt r7, #15
4527 ; CHECK-NEXT: mov r12, r7
4528 ; CHECK-NEXT: vcmp.f32 s28, #0
4529 ; CHECK-NEXT: ldr r7, [sp, #16] @ 4-byte Reload
4530 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4532 ; CHECK-NEXT: movlt r7, #0
4533 ; CHECK-NEXT: vcmp.f32 s28, s20
4534 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4536 ; CHECK-NEXT: movgt.w r7, #-1
4537 ; CHECK-NEXT: b.w .LBB50_2
4538 ; CHECK-NEXT: .p2align 2
4539 ; CHECK-NEXT: @ %bb.1:
4540 ; CHECK-NEXT: .LCPI50_1:
4541 ; CHECK-NEXT: .long 0x717fffff @ float 1.26765052E+30
4542 ; CHECK-NEXT: .p2align 1
4543 ; CHECK-NEXT: .LBB50_2:
4544 ; CHECK-NEXT: vmov q0[3], q0[1], r7, r12
4545 ; CHECK-NEXT: ldr r4, [sp] @ 4-byte Reload
4546 ; CHECK-NEXT: vmov r5, s1
4547 ; CHECK-NEXT: ldr r6, [sp, #28] @ 4-byte Reload
4548 ; CHECK-NEXT: vcmp.f32 s28, #0
4549 ; CHECK-NEXT: lsrl r4, r5, #28
4550 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4552 ; CHECK-NEXT: movlt r6, #0
4553 ; CHECK-NEXT: vcmp.f32 s28, s20
4554 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4556 ; CHECK-NEXT: movgt.w r6, #-1
4557 ; CHECK-NEXT: orr.w r7, r5, r6, lsl #4
4558 ; CHECK-NEXT: and r5, r12, #15
4559 ; CHECK-NEXT: vcmp.f32 s16, #0
4560 ; CHECK-NEXT: lsrl r6, r5, #28
4561 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4562 ; CHECK-NEXT: vcmp.f32 s16, s20
4563 ; CHECK-NEXT: str.w r7, [r9, #45]
4564 ; CHECK-NEXT: str.w r4, [r9, #41]
4565 ; CHECK-NEXT: strb.w r6, [r9, #49]
4567 ; CHECK-NEXT: movlt r3, #0
4568 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4569 ; CHECK-NEXT: vcmp.f32 s16, #0
4571 ; CHECK-NEXT: movgt r3, #15
4572 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4574 ; CHECK-NEXT: movlt r1, #0
4575 ; CHECK-NEXT: vcmp.f32 s16, s20
4576 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4578 ; CHECK-NEXT: movgt.w r1, #-1
4579 ; CHECK-NEXT: vmov q0[3], q0[1], r1, r3
4580 ; CHECK-NEXT: vcmp.f32 s16, #0
4581 ; CHECK-NEXT: vmov r1, s1
4582 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4583 ; CHECK-NEXT: lsrl r0, r1, #28
4585 ; CHECK-NEXT: movlt r2, #0
4586 ; CHECK-NEXT: vcmp.f32 s16, s20
4587 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4589 ; CHECK-NEXT: movgt.w r2, #-1
4590 ; CHECK-NEXT: orr.w r1, r1, r2, lsl #4
4591 ; CHECK-NEXT: strd r0, r1, [r9, #16]
4592 ; CHECK-NEXT: and r1, r3, #15
4593 ; CHECK-NEXT: lsrl r2, r1, #28
4594 ; CHECK-NEXT: strb.w r2, [r9, #24]
4595 ; CHECK-NEXT: add sp, #32
4596 ; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13, d14, d15}
4597 ; CHECK-NEXT: add sp, #4
4598 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc}
4599 ; CHECK-NEXT: @ %bb.3:
4600 %x = call <8 x i100> @llvm.fptoui.sat.v8f16.v8i100(<8 x half> %f)
4604 define arm_aapcs_vfpcc <8 x i128> @test_unsigned_v8f16_v8i128(<8 x half> %f) {
4605 ; CHECK-LABEL: test_unsigned_v8f16_v8i128:
4607 ; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, lr}
4608 ; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, lr}
4609 ; CHECK-NEXT: .pad #4
4610 ; CHECK-NEXT: sub sp, #4
4611 ; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13, d14, d15}
4612 ; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13, d14, d15}
4613 ; CHECK-NEXT: vmov q4, q0
4614 ; CHECK-NEXT: mov r4, r0
4615 ; CHECK-NEXT: vcvtt.f32.f16 s26, s19
4616 ; CHECK-NEXT: vcvtb.f32.f16 s22, s16
4617 ; CHECK-NEXT: vmov r0, s26
4618 ; CHECK-NEXT: vcvtt.f32.f16 s16, s16
4619 ; CHECK-NEXT: vcvtb.f32.f16 s24, s17
4620 ; CHECK-NEXT: vcvtb.f32.f16 s30, s19
4621 ; CHECK-NEXT: vldr s20, .LCPI51_0
4622 ; CHECK-NEXT: vmov r8, s22
4623 ; CHECK-NEXT: vmov r9, s16
4624 ; CHECK-NEXT: vcvtt.f32.f16 s28, s18
4625 ; CHECK-NEXT: vmov r7, s24
4626 ; CHECK-NEXT: vmov r6, s30
4627 ; CHECK-NEXT: bl __fixunssfti
4628 ; CHECK-NEXT: vcmp.f32 s26, #0
4629 ; CHECK-NEXT: vcvtb.f32.f16 s18, s18
4630 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4631 ; CHECK-NEXT: vcmp.f32 s26, s20
4633 ; CHECK-NEXT: movlt r3, #0
4634 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4635 ; CHECK-NEXT: vcmp.f32 s26, #0
4637 ; CHECK-NEXT: movgt.w r3, #-1
4638 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4639 ; CHECK-NEXT: vcmp.f32 s26, s20
4640 ; CHECK-NEXT: str r3, [r4, #124]
4642 ; CHECK-NEXT: movlt r2, #0
4643 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4644 ; CHECK-NEXT: vcmp.f32 s26, #0
4646 ; CHECK-NEXT: movgt.w r2, #-1
4647 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4648 ; CHECK-NEXT: vcmp.f32 s26, s20
4649 ; CHECK-NEXT: str r2, [r4, #120]
4651 ; CHECK-NEXT: movlt r1, #0
4652 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4653 ; CHECK-NEXT: vcmp.f32 s26, #0
4655 ; CHECK-NEXT: movgt.w r1, #-1
4656 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4657 ; CHECK-NEXT: str r1, [r4, #116]
4659 ; CHECK-NEXT: movlt r0, #0
4660 ; CHECK-NEXT: vcmp.f32 s26, s20
4661 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4663 ; CHECK-NEXT: movgt.w r0, #-1
4664 ; CHECK-NEXT: str r0, [r4, #112]
4665 ; CHECK-NEXT: mov r0, r6
4666 ; CHECK-NEXT: vmov r5, s28
4667 ; CHECK-NEXT: bl __fixunssfti
4668 ; CHECK-NEXT: vcmp.f32 s30, #0
4669 ; CHECK-NEXT: vcvtt.f32.f16 s26, s17
4670 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4671 ; CHECK-NEXT: vcmp.f32 s30, s20
4673 ; CHECK-NEXT: movlt r3, #0
4674 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4675 ; CHECK-NEXT: vcmp.f32 s30, #0
4677 ; CHECK-NEXT: movgt.w r3, #-1
4678 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4679 ; CHECK-NEXT: vcmp.f32 s30, s20
4680 ; CHECK-NEXT: str r3, [r4, #108]
4682 ; CHECK-NEXT: movlt r2, #0
4683 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4684 ; CHECK-NEXT: vcmp.f32 s30, #0
4686 ; CHECK-NEXT: movgt.w r2, #-1
4687 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4688 ; CHECK-NEXT: vcmp.f32 s30, s20
4689 ; CHECK-NEXT: str r2, [r4, #104]
4691 ; CHECK-NEXT: movlt r1, #0
4692 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4693 ; CHECK-NEXT: vcmp.f32 s30, #0
4695 ; CHECK-NEXT: movgt.w r1, #-1
4696 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4697 ; CHECK-NEXT: str r1, [r4, #100]
4699 ; CHECK-NEXT: movlt r0, #0
4700 ; CHECK-NEXT: vcmp.f32 s30, s20
4701 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4703 ; CHECK-NEXT: movgt.w r0, #-1
4704 ; CHECK-NEXT: str r0, [r4, #96]
4705 ; CHECK-NEXT: mov r0, r5
4706 ; CHECK-NEXT: vmov r6, s18
4707 ; CHECK-NEXT: bl __fixunssfti
4708 ; CHECK-NEXT: vcmp.f32 s28, #0
4709 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4710 ; CHECK-NEXT: vcmp.f32 s28, s20
4712 ; CHECK-NEXT: movlt r3, #0
4713 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4714 ; CHECK-NEXT: vcmp.f32 s28, #0
4716 ; CHECK-NEXT: movgt.w r3, #-1
4717 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4718 ; CHECK-NEXT: vcmp.f32 s28, s20
4719 ; CHECK-NEXT: str r3, [r4, #92]
4721 ; CHECK-NEXT: movlt r2, #0
4722 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4723 ; CHECK-NEXT: vcmp.f32 s28, #0
4725 ; CHECK-NEXT: movgt.w r2, #-1
4726 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4727 ; CHECK-NEXT: vcmp.f32 s28, s20
4728 ; CHECK-NEXT: str r2, [r4, #88]
4730 ; CHECK-NEXT: movlt r1, #0
4731 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4732 ; CHECK-NEXT: vcmp.f32 s28, #0
4734 ; CHECK-NEXT: movgt.w r1, #-1
4735 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4736 ; CHECK-NEXT: str r1, [r4, #84]
4738 ; CHECK-NEXT: movlt r0, #0
4739 ; CHECK-NEXT: vcmp.f32 s28, s20
4740 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4742 ; CHECK-NEXT: movgt.w r0, #-1
4743 ; CHECK-NEXT: str r0, [r4, #80]
4744 ; CHECK-NEXT: mov r0, r6
4745 ; CHECK-NEXT: vmov r5, s26
4746 ; CHECK-NEXT: bl __fixunssfti
4747 ; CHECK-NEXT: vcmp.f32 s18, #0
4748 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4749 ; CHECK-NEXT: vcmp.f32 s18, s20
4751 ; CHECK-NEXT: movlt r3, #0
4752 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4753 ; CHECK-NEXT: vcmp.f32 s18, #0
4755 ; CHECK-NEXT: movgt.w r3, #-1
4756 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4757 ; CHECK-NEXT: vcmp.f32 s18, s20
4758 ; CHECK-NEXT: str r3, [r4, #76]
4760 ; CHECK-NEXT: movlt r2, #0
4761 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4762 ; CHECK-NEXT: vcmp.f32 s18, #0
4764 ; CHECK-NEXT: movgt.w r2, #-1
4765 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4766 ; CHECK-NEXT: vcmp.f32 s18, s20
4767 ; CHECK-NEXT: str r2, [r4, #72]
4769 ; CHECK-NEXT: movlt r1, #0
4770 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4771 ; CHECK-NEXT: vcmp.f32 s18, #0
4773 ; CHECK-NEXT: movgt.w r1, #-1
4774 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4775 ; CHECK-NEXT: str r1, [r4, #68]
4777 ; CHECK-NEXT: movlt r0, #0
4778 ; CHECK-NEXT: vcmp.f32 s18, s20
4779 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4781 ; CHECK-NEXT: movgt.w r0, #-1
4782 ; CHECK-NEXT: str r0, [r4, #64]
4783 ; CHECK-NEXT: mov r0, r5
4784 ; CHECK-NEXT: bl __fixunssfti
4785 ; CHECK-NEXT: vcmp.f32 s26, #0
4786 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4787 ; CHECK-NEXT: vcmp.f32 s26, s20
4789 ; CHECK-NEXT: movlt r3, #0
4790 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4791 ; CHECK-NEXT: vcmp.f32 s26, #0
4793 ; CHECK-NEXT: movgt.w r3, #-1
4794 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4795 ; CHECK-NEXT: vcmp.f32 s26, s20
4796 ; CHECK-NEXT: str r3, [r4, #60]
4798 ; CHECK-NEXT: movlt r2, #0
4799 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4800 ; CHECK-NEXT: vcmp.f32 s26, #0
4802 ; CHECK-NEXT: movgt.w r2, #-1
4803 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4804 ; CHECK-NEXT: vcmp.f32 s26, s20
4805 ; CHECK-NEXT: str r2, [r4, #56]
4807 ; CHECK-NEXT: movlt r1, #0
4808 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4809 ; CHECK-NEXT: vcmp.f32 s26, #0
4811 ; CHECK-NEXT: movgt.w r1, #-1
4812 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4813 ; CHECK-NEXT: str r1, [r4, #52]
4815 ; CHECK-NEXT: movlt r0, #0
4816 ; CHECK-NEXT: vcmp.f32 s26, s20
4817 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4819 ; CHECK-NEXT: movgt.w r0, #-1
4820 ; CHECK-NEXT: str r0, [r4, #48]
4821 ; CHECK-NEXT: mov r0, r7
4822 ; CHECK-NEXT: bl __fixunssfti
4823 ; CHECK-NEXT: vcmp.f32 s24, #0
4824 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4825 ; CHECK-NEXT: vcmp.f32 s24, s20
4827 ; CHECK-NEXT: movlt r3, #0
4828 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4829 ; CHECK-NEXT: vcmp.f32 s24, #0
4831 ; CHECK-NEXT: movgt.w r3, #-1
4832 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4833 ; CHECK-NEXT: vcmp.f32 s24, s20
4834 ; CHECK-NEXT: str r3, [r4, #44]
4836 ; CHECK-NEXT: movlt r2, #0
4837 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4838 ; CHECK-NEXT: vcmp.f32 s24, #0
4840 ; CHECK-NEXT: movgt.w r2, #-1
4841 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4842 ; CHECK-NEXT: vcmp.f32 s24, s20
4843 ; CHECK-NEXT: str r2, [r4, #40]
4845 ; CHECK-NEXT: movlt r1, #0
4846 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4847 ; CHECK-NEXT: vcmp.f32 s24, #0
4849 ; CHECK-NEXT: movgt.w r1, #-1
4850 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4851 ; CHECK-NEXT: str r1, [r4, #36]
4853 ; CHECK-NEXT: movlt r0, #0
4854 ; CHECK-NEXT: vcmp.f32 s24, s20
4855 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4857 ; CHECK-NEXT: movgt.w r0, #-1
4858 ; CHECK-NEXT: str r0, [r4, #32]
4859 ; CHECK-NEXT: mov r0, r9
4860 ; CHECK-NEXT: bl __fixunssfti
4861 ; CHECK-NEXT: vcmp.f32 s16, #0
4862 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4863 ; CHECK-NEXT: vcmp.f32 s16, s20
4865 ; CHECK-NEXT: movlt r3, #0
4866 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4867 ; CHECK-NEXT: vcmp.f32 s16, #0
4869 ; CHECK-NEXT: movgt.w r3, #-1
4870 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4871 ; CHECK-NEXT: vcmp.f32 s16, s20
4872 ; CHECK-NEXT: str r3, [r4, #28]
4874 ; CHECK-NEXT: movlt r2, #0
4875 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4876 ; CHECK-NEXT: vcmp.f32 s16, #0
4878 ; CHECK-NEXT: movgt.w r2, #-1
4879 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4880 ; CHECK-NEXT: vcmp.f32 s16, s20
4881 ; CHECK-NEXT: str r2, [r4, #24]
4883 ; CHECK-NEXT: movlt r1, #0
4884 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4885 ; CHECK-NEXT: vcmp.f32 s16, #0
4887 ; CHECK-NEXT: movgt.w r1, #-1
4888 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4889 ; CHECK-NEXT: str r1, [r4, #20]
4891 ; CHECK-NEXT: movlt r0, #0
4892 ; CHECK-NEXT: vcmp.f32 s16, s20
4893 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4895 ; CHECK-NEXT: movgt.w r0, #-1
4896 ; CHECK-NEXT: str r0, [r4, #16]
4897 ; CHECK-NEXT: mov r0, r8
4898 ; CHECK-NEXT: bl __fixunssfti
4899 ; CHECK-NEXT: vcmp.f32 s22, #0
4900 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4901 ; CHECK-NEXT: vcmp.f32 s22, s20
4903 ; CHECK-NEXT: movlt r3, #0
4904 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4905 ; CHECK-NEXT: vcmp.f32 s22, #0
4907 ; CHECK-NEXT: movgt.w r3, #-1
4908 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4909 ; CHECK-NEXT: vcmp.f32 s22, s20
4910 ; CHECK-NEXT: str r3, [r4, #12]
4912 ; CHECK-NEXT: movlt r2, #0
4913 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4914 ; CHECK-NEXT: vcmp.f32 s22, #0
4916 ; CHECK-NEXT: movgt.w r2, #-1
4917 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4918 ; CHECK-NEXT: vcmp.f32 s22, s20
4919 ; CHECK-NEXT: str r2, [r4, #8]
4921 ; CHECK-NEXT: movlt r1, #0
4922 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4923 ; CHECK-NEXT: vcmp.f32 s22, #0
4925 ; CHECK-NEXT: movgt.w r1, #-1
4926 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4927 ; CHECK-NEXT: str r1, [r4, #4]
4929 ; CHECK-NEXT: movlt r0, #0
4930 ; CHECK-NEXT: vcmp.f32 s22, s20
4931 ; CHECK-NEXT: vmrs APSR_nzcv, fpscr
4933 ; CHECK-NEXT: movgt.w r0, #-1
4934 ; CHECK-NEXT: str r0, [r4]
4935 ; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13, d14, d15}
4936 ; CHECK-NEXT: add sp, #4
4937 ; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, pc}
4938 ; CHECK-NEXT: .p2align 2
4939 ; CHECK-NEXT: @ %bb.1:
4940 ; CHECK-NEXT: .LCPI51_0:
4941 ; CHECK-NEXT: .long 0x7f7fffff @ float 3.40282347E+38
4942 %x = call <8 x i128> @llvm.fptoui.sat.v8f16.v8i128(<8 x half> %f)