1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+sse2 -O3 | FileCheck %s --check-prefixes=SSE-X86
3 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+sse2 -O3 | FileCheck %s --check-prefixes=SSE-X64
4 ; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+avx -O3 | FileCheck %s --check-prefixes=AVX-X86,AVX1-X86
5 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx -O3 | FileCheck %s --check-prefixes=AVX-X64,AVX1-X64
6 ; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+avx512f -mattr=+avx512vl -O3 | FileCheck %s --check-prefixes=AVX-X86,AVX512-X86
7 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f -mattr=+avx512vl -O3 | FileCheck %s --check-prefixes=AVX-X64,AVX512-X64
8 ; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=-sse -O3 | FileCheck %s --check-prefixes=X87
10 declare i1 @llvm.experimental.constrained.fptosi.i1.f32(float, metadata)
11 declare i8 @llvm.experimental.constrained.fptosi.i8.f32(float, metadata)
12 declare i16 @llvm.experimental.constrained.fptosi.i16.f32(float, metadata)
13 declare i32 @llvm.experimental.constrained.fptosi.i32.f32(float, metadata)
14 declare i64 @llvm.experimental.constrained.fptosi.i64.f32(float, metadata)
15 declare i1 @llvm.experimental.constrained.fptoui.i1.f32(float, metadata)
16 declare i8 @llvm.experimental.constrained.fptoui.i8.f32(float, metadata)
17 declare i16 @llvm.experimental.constrained.fptoui.i16.f32(float, metadata)
18 declare i32 @llvm.experimental.constrained.fptoui.i32.f32(float, metadata)
19 declare i64 @llvm.experimental.constrained.fptoui.i64.f32(float, metadata)
21 declare i1 @llvm.experimental.constrained.fptosi.i1.f64(double, metadata)
22 declare i8 @llvm.experimental.constrained.fptosi.i8.f64(double, metadata)
23 declare i16 @llvm.experimental.constrained.fptosi.i16.f64(double, metadata)
24 declare i32 @llvm.experimental.constrained.fptosi.i32.f64(double, metadata)
25 declare i64 @llvm.experimental.constrained.fptosi.i64.f64(double, metadata)
26 declare i1 @llvm.experimental.constrained.fptoui.i1.f64(double, metadata)
27 declare i8 @llvm.experimental.constrained.fptoui.i8.f64(double, metadata)
28 declare i16 @llvm.experimental.constrained.fptoui.i16.f64(double, metadata)
29 declare i32 @llvm.experimental.constrained.fptoui.i32.f64(double, metadata)
30 declare i64 @llvm.experimental.constrained.fptoui.i64.f64(double, metadata)
32 define i1 @fptosi_f32toi1(float %x) #0 {
33 ; SSE-X86-LABEL: fptosi_f32toi1:
35 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
36 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
39 ; SSE-X64-LABEL: fptosi_f32toi1:
41 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
42 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
45 ; AVX-X86-LABEL: fptosi_f32toi1:
47 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
48 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
51 ; AVX-X64-LABEL: fptosi_f32toi1:
53 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
54 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
57 ; X87-LABEL: fptosi_f32toi1:
59 ; X87-NEXT: subl $8, %esp
60 ; X87-NEXT: .cfi_def_cfa_offset 12
61 ; X87-NEXT: flds {{[0-9]+}}(%esp)
63 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
64 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
65 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
66 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
67 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
68 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
69 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
70 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
71 ; X87-NEXT: addl $8, %esp
72 ; X87-NEXT: .cfi_def_cfa_offset 4
74 %result = call i1 @llvm.experimental.constrained.fptosi.i1.f32(float %x,
75 metadata !"fpexcept.strict") #0
79 define i8 @fptosi_f32toi8(float %x) #0 {
80 ; SSE-X86-LABEL: fptosi_f32toi8:
82 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
83 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
86 ; SSE-X64-LABEL: fptosi_f32toi8:
88 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
89 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
92 ; AVX-X86-LABEL: fptosi_f32toi8:
94 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
95 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
98 ; AVX-X64-LABEL: fptosi_f32toi8:
100 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
101 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
104 ; X87-LABEL: fptosi_f32toi8:
106 ; X87-NEXT: subl $8, %esp
107 ; X87-NEXT: .cfi_def_cfa_offset 12
108 ; X87-NEXT: flds {{[0-9]+}}(%esp)
110 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
111 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
112 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
113 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
114 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
115 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
116 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
117 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
118 ; X87-NEXT: addl $8, %esp
119 ; X87-NEXT: .cfi_def_cfa_offset 4
121 %result = call i8 @llvm.experimental.constrained.fptosi.i8.f32(float %x,
122 metadata !"fpexcept.strict") #0
126 define i16 @fptosi_f32toi16(float %x) #0 {
127 ; SSE-X86-LABEL: fptosi_f32toi16:
129 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
130 ; SSE-X86-NEXT: # kill: def $ax killed $ax killed $eax
133 ; SSE-X64-LABEL: fptosi_f32toi16:
135 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
136 ; SSE-X64-NEXT: # kill: def $ax killed $ax killed $eax
139 ; AVX-X86-LABEL: fptosi_f32toi16:
141 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
142 ; AVX-X86-NEXT: # kill: def $ax killed $ax killed $eax
145 ; AVX-X64-LABEL: fptosi_f32toi16:
147 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
148 ; AVX-X64-NEXT: # kill: def $ax killed $ax killed $eax
151 ; X87-LABEL: fptosi_f32toi16:
153 ; X87-NEXT: subl $8, %esp
154 ; X87-NEXT: .cfi_def_cfa_offset 12
155 ; X87-NEXT: flds {{[0-9]+}}(%esp)
157 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
158 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
159 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
160 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
161 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
162 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
163 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
164 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
165 ; X87-NEXT: addl $8, %esp
166 ; X87-NEXT: .cfi_def_cfa_offset 4
168 %result = call i16 @llvm.experimental.constrained.fptosi.i16.f32(float %x,
169 metadata !"fpexcept.strict") #0
173 define i32 @fptosi_f32toi32(float %x) #0 {
174 ; SSE-X86-LABEL: fptosi_f32toi32:
176 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
179 ; SSE-X64-LABEL: fptosi_f32toi32:
181 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
184 ; AVX-X86-LABEL: fptosi_f32toi32:
186 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
189 ; AVX-X64-LABEL: fptosi_f32toi32:
191 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
194 ; X87-LABEL: fptosi_f32toi32:
196 ; X87-NEXT: subl $8, %esp
197 ; X87-NEXT: .cfi_def_cfa_offset 12
198 ; X87-NEXT: flds {{[0-9]+}}(%esp)
200 ; X87-NEXT: fnstcw (%esp)
201 ; X87-NEXT: movzwl (%esp), %eax
202 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
203 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
204 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
205 ; X87-NEXT: fistpl {{[0-9]+}}(%esp)
206 ; X87-NEXT: fldcw (%esp)
207 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
208 ; X87-NEXT: addl $8, %esp
209 ; X87-NEXT: .cfi_def_cfa_offset 4
211 %result = call i32 @llvm.experimental.constrained.fptosi.i32.f32(float %x,
212 metadata !"fpexcept.strict") #0
216 define i64 @fptosi_f32toi64(float %x) #0 {
217 ; SSE-X86-LABEL: fptosi_f32toi64:
219 ; SSE-X86-NEXT: pushl %ebp
220 ; SSE-X86-NEXT: .cfi_def_cfa_offset 8
221 ; SSE-X86-NEXT: .cfi_offset %ebp, -8
222 ; SSE-X86-NEXT: movl %esp, %ebp
223 ; SSE-X86-NEXT: .cfi_def_cfa_register %ebp
224 ; SSE-X86-NEXT: andl $-8, %esp
225 ; SSE-X86-NEXT: subl $16, %esp
226 ; SSE-X86-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
227 ; SSE-X86-NEXT: movss %xmm0, {{[0-9]+}}(%esp)
228 ; SSE-X86-NEXT: flds {{[0-9]+}}(%esp)
230 ; SSE-X86-NEXT: fnstcw {{[0-9]+}}(%esp)
231 ; SSE-X86-NEXT: movzwl {{[0-9]+}}(%esp), %eax
232 ; SSE-X86-NEXT: orl $3072, %eax # imm = 0xC00
233 ; SSE-X86-NEXT: movw %ax, {{[0-9]+}}(%esp)
234 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
235 ; SSE-X86-NEXT: fistpll {{[0-9]+}}(%esp)
236 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
237 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
238 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %edx
239 ; SSE-X86-NEXT: movl %ebp, %esp
240 ; SSE-X86-NEXT: popl %ebp
241 ; SSE-X86-NEXT: .cfi_def_cfa %esp, 4
244 ; SSE-X64-LABEL: fptosi_f32toi64:
246 ; SSE-X64-NEXT: cvttss2si %xmm0, %rax
249 ; AVX-X86-LABEL: fptosi_f32toi64:
251 ; AVX-X86-NEXT: pushl %ebp
252 ; AVX-X86-NEXT: .cfi_def_cfa_offset 8
253 ; AVX-X86-NEXT: .cfi_offset %ebp, -8
254 ; AVX-X86-NEXT: movl %esp, %ebp
255 ; AVX-X86-NEXT: .cfi_def_cfa_register %ebp
256 ; AVX-X86-NEXT: andl $-8, %esp
257 ; AVX-X86-NEXT: subl $8, %esp
258 ; AVX-X86-NEXT: vmovss {{.*#+}} xmm0 = mem[0],zero,zero,zero
259 ; AVX-X86-NEXT: vmovss %xmm0, (%esp)
260 ; AVX-X86-NEXT: flds (%esp)
261 ; AVX-X86-NEXT: fisttpll (%esp)
263 ; AVX-X86-NEXT: movl (%esp), %eax
264 ; AVX-X86-NEXT: movl {{[0-9]+}}(%esp), %edx
265 ; AVX-X86-NEXT: movl %ebp, %esp
266 ; AVX-X86-NEXT: popl %ebp
267 ; AVX-X86-NEXT: .cfi_def_cfa %esp, 4
270 ; AVX-X64-LABEL: fptosi_f32toi64:
272 ; AVX-X64-NEXT: vcvttss2si %xmm0, %rax
275 ; X87-LABEL: fptosi_f32toi64:
277 ; X87-NEXT: pushl %ebp
278 ; X87-NEXT: .cfi_def_cfa_offset 8
279 ; X87-NEXT: .cfi_offset %ebp, -8
280 ; X87-NEXT: movl %esp, %ebp
281 ; X87-NEXT: .cfi_def_cfa_register %ebp
282 ; X87-NEXT: andl $-8, %esp
283 ; X87-NEXT: subl $16, %esp
284 ; X87-NEXT: flds 8(%ebp)
286 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
287 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
288 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
289 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
290 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
291 ; X87-NEXT: fistpll {{[0-9]+}}(%esp)
292 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
293 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
294 ; X87-NEXT: movl {{[0-9]+}}(%esp), %edx
295 ; X87-NEXT: movl %ebp, %esp
296 ; X87-NEXT: popl %ebp
297 ; X87-NEXT: .cfi_def_cfa %esp, 4
299 %result = call i64 @llvm.experimental.constrained.fptosi.i64.f32(float %x,
300 metadata !"fpexcept.strict") #0
304 define i1 @fptoui_f32toi1(float %x) #0 {
305 ; SSE-X86-LABEL: fptoui_f32toi1:
307 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
308 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
311 ; SSE-X64-LABEL: fptoui_f32toi1:
313 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
314 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
317 ; AVX-X86-LABEL: fptoui_f32toi1:
319 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
320 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
323 ; AVX-X64-LABEL: fptoui_f32toi1:
325 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
326 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
329 ; X87-LABEL: fptoui_f32toi1:
331 ; X87-NEXT: subl $8, %esp
332 ; X87-NEXT: .cfi_def_cfa_offset 12
333 ; X87-NEXT: flds {{[0-9]+}}(%esp)
335 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
336 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
337 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
338 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
339 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
340 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
341 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
342 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
343 ; X87-NEXT: addl $8, %esp
344 ; X87-NEXT: .cfi_def_cfa_offset 4
346 %result = call i1 @llvm.experimental.constrained.fptoui.i1.f32(float %x,
347 metadata !"fpexcept.strict") #0
351 define i8 @fptoui_f32toi8(float %x) #0 {
352 ; SSE-X86-LABEL: fptoui_f32toi8:
354 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
355 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
358 ; SSE-X64-LABEL: fptoui_f32toi8:
360 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
361 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
364 ; AVX-X86-LABEL: fptoui_f32toi8:
366 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
367 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
370 ; AVX-X64-LABEL: fptoui_f32toi8:
372 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
373 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
376 ; X87-LABEL: fptoui_f32toi8:
378 ; X87-NEXT: subl $8, %esp
379 ; X87-NEXT: .cfi_def_cfa_offset 12
380 ; X87-NEXT: flds {{[0-9]+}}(%esp)
382 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
383 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
384 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
385 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
386 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
387 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
388 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
389 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
390 ; X87-NEXT: addl $8, %esp
391 ; X87-NEXT: .cfi_def_cfa_offset 4
393 %result = call i8 @llvm.experimental.constrained.fptoui.i8.f32(float %x,
394 metadata !"fpexcept.strict") #0
398 define i16 @fptoui_f32toi16(float %x) #0 {
399 ; SSE-X86-LABEL: fptoui_f32toi16:
401 ; SSE-X86-NEXT: cvttss2si {{[0-9]+}}(%esp), %eax
402 ; SSE-X86-NEXT: # kill: def $ax killed $ax killed $eax
405 ; SSE-X64-LABEL: fptoui_f32toi16:
407 ; SSE-X64-NEXT: cvttss2si %xmm0, %eax
408 ; SSE-X64-NEXT: # kill: def $ax killed $ax killed $eax
411 ; AVX-X86-LABEL: fptoui_f32toi16:
413 ; AVX-X86-NEXT: vcvttss2si {{[0-9]+}}(%esp), %eax
414 ; AVX-X86-NEXT: # kill: def $ax killed $ax killed $eax
417 ; AVX-X64-LABEL: fptoui_f32toi16:
419 ; AVX-X64-NEXT: vcvttss2si %xmm0, %eax
420 ; AVX-X64-NEXT: # kill: def $ax killed $ax killed $eax
423 ; X87-LABEL: fptoui_f32toi16:
425 ; X87-NEXT: subl $8, %esp
426 ; X87-NEXT: .cfi_def_cfa_offset 12
427 ; X87-NEXT: flds {{[0-9]+}}(%esp)
429 ; X87-NEXT: fnstcw (%esp)
430 ; X87-NEXT: movzwl (%esp), %eax
431 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
432 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
433 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
434 ; X87-NEXT: fistpl {{[0-9]+}}(%esp)
435 ; X87-NEXT: fldcw (%esp)
436 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
437 ; X87-NEXT: # kill: def $ax killed $ax killed $eax
438 ; X87-NEXT: addl $8, %esp
439 ; X87-NEXT: .cfi_def_cfa_offset 4
441 %result = call i16 @llvm.experimental.constrained.fptoui.i16.f32(float %x,
442 metadata !"fpexcept.strict") #0
446 define i32 @fptoui_f32toi32(float %x) #0 {
447 ; SSE-X86-LABEL: fptoui_f32toi32:
449 ; SSE-X86-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
450 ; SSE-X86-NEXT: movss {{.*#+}} xmm2 = mem[0],zero,zero,zero
451 ; SSE-X86-NEXT: comiss %xmm0, %xmm2
452 ; SSE-X86-NEXT: xorps %xmm1, %xmm1
453 ; SSE-X86-NEXT: ja .LBB8_2
454 ; SSE-X86-NEXT: # %bb.1:
455 ; SSE-X86-NEXT: movaps %xmm2, %xmm1
456 ; SSE-X86-NEXT: .LBB8_2:
457 ; SSE-X86-NEXT: setbe %al
458 ; SSE-X86-NEXT: movzbl %al, %ecx
459 ; SSE-X86-NEXT: shll $31, %ecx
460 ; SSE-X86-NEXT: subss %xmm1, %xmm0
461 ; SSE-X86-NEXT: cvttss2si %xmm0, %eax
462 ; SSE-X86-NEXT: xorl %ecx, %eax
465 ; SSE-X64-LABEL: fptoui_f32toi32:
467 ; SSE-X64-NEXT: cvttss2si %xmm0, %rax
468 ; SSE-X64-NEXT: # kill: def $eax killed $eax killed $rax
471 ; AVX1-X86-LABEL: fptoui_f32toi32:
473 ; AVX1-X86-NEXT: pushl %ebp
474 ; AVX1-X86-NEXT: .cfi_def_cfa_offset 8
475 ; AVX1-X86-NEXT: .cfi_offset %ebp, -8
476 ; AVX1-X86-NEXT: movl %esp, %ebp
477 ; AVX1-X86-NEXT: .cfi_def_cfa_register %ebp
478 ; AVX1-X86-NEXT: andl $-8, %esp
479 ; AVX1-X86-NEXT: subl $8, %esp
480 ; AVX1-X86-NEXT: vmovss {{.*#+}} xmm0 = mem[0],zero,zero,zero
481 ; AVX1-X86-NEXT: vmovss %xmm0, (%esp)
482 ; AVX1-X86-NEXT: flds (%esp)
483 ; AVX1-X86-NEXT: fisttpll (%esp)
484 ; AVX1-X86-NEXT: wait
485 ; AVX1-X86-NEXT: movl (%esp), %eax
486 ; AVX1-X86-NEXT: movl %ebp, %esp
487 ; AVX1-X86-NEXT: popl %ebp
488 ; AVX1-X86-NEXT: .cfi_def_cfa %esp, 4
489 ; AVX1-X86-NEXT: retl
491 ; AVX1-X64-LABEL: fptoui_f32toi32:
493 ; AVX1-X64-NEXT: vcvttss2si %xmm0, %rax
494 ; AVX1-X64-NEXT: # kill: def $eax killed $eax killed $rax
495 ; AVX1-X64-NEXT: retq
497 ; AVX512-X86-LABEL: fptoui_f32toi32:
498 ; AVX512-X86: # %bb.0:
499 ; AVX512-X86-NEXT: vcvttss2usi {{[0-9]+}}(%esp), %eax
500 ; AVX512-X86-NEXT: retl
502 ; AVX512-X64-LABEL: fptoui_f32toi32:
503 ; AVX512-X64: # %bb.0:
504 ; AVX512-X64-NEXT: vcvttss2usi %xmm0, %eax
505 ; AVX512-X64-NEXT: retq
507 ; X87-LABEL: fptoui_f32toi32:
509 ; X87-NEXT: pushl %ebp
510 ; X87-NEXT: .cfi_def_cfa_offset 8
511 ; X87-NEXT: .cfi_offset %ebp, -8
512 ; X87-NEXT: movl %esp, %ebp
513 ; X87-NEXT: .cfi_def_cfa_register %ebp
514 ; X87-NEXT: andl $-8, %esp
515 ; X87-NEXT: subl $16, %esp
516 ; X87-NEXT: flds 8(%ebp)
518 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
519 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
520 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
521 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
522 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
523 ; X87-NEXT: fistpll {{[0-9]+}}(%esp)
524 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
525 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
526 ; X87-NEXT: movl %ebp, %esp
527 ; X87-NEXT: popl %ebp
528 ; X87-NEXT: .cfi_def_cfa %esp, 4
530 %result = call i32 @llvm.experimental.constrained.fptoui.i32.f32(float %x,
531 metadata !"fpexcept.strict") #0
535 define i64 @fptoui_f32toi64(float %x) #0 {
536 ; SSE-X86-LABEL: fptoui_f32toi64:
538 ; SSE-X86-NEXT: pushl %ebp
539 ; SSE-X86-NEXT: .cfi_def_cfa_offset 8
540 ; SSE-X86-NEXT: .cfi_offset %ebp, -8
541 ; SSE-X86-NEXT: movl %esp, %ebp
542 ; SSE-X86-NEXT: .cfi_def_cfa_register %ebp
543 ; SSE-X86-NEXT: andl $-8, %esp
544 ; SSE-X86-NEXT: subl $16, %esp
545 ; SSE-X86-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
546 ; SSE-X86-NEXT: movss {{.*#+}} xmm1 = mem[0],zero,zero,zero
547 ; SSE-X86-NEXT: comiss %xmm0, %xmm1
548 ; SSE-X86-NEXT: jbe .LBB9_2
549 ; SSE-X86-NEXT: # %bb.1:
550 ; SSE-X86-NEXT: xorps %xmm1, %xmm1
551 ; SSE-X86-NEXT: .LBB9_2:
552 ; SSE-X86-NEXT: subss %xmm1, %xmm0
553 ; SSE-X86-NEXT: movss %xmm0, {{[0-9]+}}(%esp)
554 ; SSE-X86-NEXT: setbe %al
555 ; SSE-X86-NEXT: flds {{[0-9]+}}(%esp)
557 ; SSE-X86-NEXT: fnstcw {{[0-9]+}}(%esp)
558 ; SSE-X86-NEXT: movzwl {{[0-9]+}}(%esp), %ecx
559 ; SSE-X86-NEXT: orl $3072, %ecx # imm = 0xC00
560 ; SSE-X86-NEXT: movw %cx, {{[0-9]+}}(%esp)
561 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
562 ; SSE-X86-NEXT: fistpll {{[0-9]+}}(%esp)
563 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
564 ; SSE-X86-NEXT: movzbl %al, %edx
565 ; SSE-X86-NEXT: shll $31, %edx
566 ; SSE-X86-NEXT: xorl {{[0-9]+}}(%esp), %edx
567 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
568 ; SSE-X86-NEXT: movl %ebp, %esp
569 ; SSE-X86-NEXT: popl %ebp
570 ; SSE-X86-NEXT: .cfi_def_cfa %esp, 4
573 ; SSE-X64-LABEL: fptoui_f32toi64:
575 ; SSE-X64-NEXT: movss {{.*#+}} xmm2 = mem[0],zero,zero,zero
576 ; SSE-X64-NEXT: comiss %xmm2, %xmm0
577 ; SSE-X64-NEXT: xorps %xmm1, %xmm1
578 ; SSE-X64-NEXT: jb .LBB9_2
579 ; SSE-X64-NEXT: # %bb.1:
580 ; SSE-X64-NEXT: movaps %xmm2, %xmm1
581 ; SSE-X64-NEXT: .LBB9_2:
582 ; SSE-X64-NEXT: subss %xmm1, %xmm0
583 ; SSE-X64-NEXT: cvttss2si %xmm0, %rcx
584 ; SSE-X64-NEXT: setae %al
585 ; SSE-X64-NEXT: movzbl %al, %eax
586 ; SSE-X64-NEXT: shlq $63, %rax
587 ; SSE-X64-NEXT: xorq %rcx, %rax
590 ; AVX1-X86-LABEL: fptoui_f32toi64:
592 ; AVX1-X86-NEXT: pushl %ebp
593 ; AVX1-X86-NEXT: .cfi_def_cfa_offset 8
594 ; AVX1-X86-NEXT: .cfi_offset %ebp, -8
595 ; AVX1-X86-NEXT: movl %esp, %ebp
596 ; AVX1-X86-NEXT: .cfi_def_cfa_register %ebp
597 ; AVX1-X86-NEXT: andl $-8, %esp
598 ; AVX1-X86-NEXT: subl $8, %esp
599 ; AVX1-X86-NEXT: vmovss {{.*#+}} xmm0 = mem[0],zero,zero,zero
600 ; AVX1-X86-NEXT: vmovss {{.*#+}} xmm1 = mem[0],zero,zero,zero
601 ; AVX1-X86-NEXT: vcomiss %xmm0, %xmm1
602 ; AVX1-X86-NEXT: jbe .LBB9_2
603 ; AVX1-X86-NEXT: # %bb.1:
604 ; AVX1-X86-NEXT: vxorps %xmm1, %xmm1, %xmm1
605 ; AVX1-X86-NEXT: .LBB9_2:
606 ; AVX1-X86-NEXT: vsubss %xmm1, %xmm0, %xmm0
607 ; AVX1-X86-NEXT: vmovss %xmm0, (%esp)
608 ; AVX1-X86-NEXT: flds (%esp)
609 ; AVX1-X86-NEXT: fisttpll (%esp)
610 ; AVX1-X86-NEXT: wait
611 ; AVX1-X86-NEXT: setbe %al
612 ; AVX1-X86-NEXT: movzbl %al, %edx
613 ; AVX1-X86-NEXT: shll $31, %edx
614 ; AVX1-X86-NEXT: xorl {{[0-9]+}}(%esp), %edx
615 ; AVX1-X86-NEXT: movl (%esp), %eax
616 ; AVX1-X86-NEXT: movl %ebp, %esp
617 ; AVX1-X86-NEXT: popl %ebp
618 ; AVX1-X86-NEXT: .cfi_def_cfa %esp, 4
619 ; AVX1-X86-NEXT: retl
621 ; AVX1-X64-LABEL: fptoui_f32toi64:
623 ; AVX1-X64-NEXT: vmovss {{.*#+}} xmm1 = mem[0],zero,zero,zero
624 ; AVX1-X64-NEXT: vcomiss %xmm1, %xmm0
625 ; AVX1-X64-NEXT: vxorps %xmm2, %xmm2, %xmm2
626 ; AVX1-X64-NEXT: jb .LBB9_2
627 ; AVX1-X64-NEXT: # %bb.1:
628 ; AVX1-X64-NEXT: vmovaps %xmm1, %xmm2
629 ; AVX1-X64-NEXT: .LBB9_2:
630 ; AVX1-X64-NEXT: vsubss %xmm2, %xmm0, %xmm0
631 ; AVX1-X64-NEXT: vcvttss2si %xmm0, %rcx
632 ; AVX1-X64-NEXT: setae %al
633 ; AVX1-X64-NEXT: movzbl %al, %eax
634 ; AVX1-X64-NEXT: shlq $63, %rax
635 ; AVX1-X64-NEXT: xorq %rcx, %rax
636 ; AVX1-X64-NEXT: retq
638 ; AVX512-X86-LABEL: fptoui_f32toi64:
639 ; AVX512-X86: # %bb.0:
640 ; AVX512-X86-NEXT: pushl %ebp
641 ; AVX512-X86-NEXT: .cfi_def_cfa_offset 8
642 ; AVX512-X86-NEXT: .cfi_offset %ebp, -8
643 ; AVX512-X86-NEXT: movl %esp, %ebp
644 ; AVX512-X86-NEXT: .cfi_def_cfa_register %ebp
645 ; AVX512-X86-NEXT: andl $-8, %esp
646 ; AVX512-X86-NEXT: subl $8, %esp
647 ; AVX512-X86-NEXT: vmovss {{.*#+}} xmm0 = mem[0],zero,zero,zero
648 ; AVX512-X86-NEXT: vmovss {{.*#+}} xmm1 = mem[0],zero,zero,zero
649 ; AVX512-X86-NEXT: xorl %edx, %edx
650 ; AVX512-X86-NEXT: vcomiss %xmm0, %xmm1
651 ; AVX512-X86-NEXT: setbe %dl
652 ; AVX512-X86-NEXT: kmovw %edx, %k1
653 ; AVX512-X86-NEXT: vmovss %xmm1, %xmm1, %xmm1 {%k1} {z}
654 ; AVX512-X86-NEXT: vsubss %xmm1, %xmm0, %xmm0
655 ; AVX512-X86-NEXT: vmovss %xmm0, (%esp)
656 ; AVX512-X86-NEXT: flds (%esp)
657 ; AVX512-X86-NEXT: fisttpll (%esp)
658 ; AVX512-X86-NEXT: wait
659 ; AVX512-X86-NEXT: shll $31, %edx
660 ; AVX512-X86-NEXT: xorl {{[0-9]+}}(%esp), %edx
661 ; AVX512-X86-NEXT: movl (%esp), %eax
662 ; AVX512-X86-NEXT: movl %ebp, %esp
663 ; AVX512-X86-NEXT: popl %ebp
664 ; AVX512-X86-NEXT: .cfi_def_cfa %esp, 4
665 ; AVX512-X86-NEXT: retl
667 ; AVX512-X64-LABEL: fptoui_f32toi64:
668 ; AVX512-X64: # %bb.0:
669 ; AVX512-X64-NEXT: vcvttss2usi %xmm0, %rax
670 ; AVX512-X64-NEXT: retq
672 ; X87-LABEL: fptoui_f32toi64:
674 ; X87-NEXT: pushl %ebp
675 ; X87-NEXT: .cfi_def_cfa_offset 8
676 ; X87-NEXT: .cfi_offset %ebp, -8
677 ; X87-NEXT: movl %esp, %ebp
678 ; X87-NEXT: .cfi_def_cfa_register %ebp
679 ; X87-NEXT: andl $-8, %esp
680 ; X87-NEXT: subl $16, %esp
681 ; X87-NEXT: flds 8(%ebp)
682 ; X87-NEXT: flds {{\.?LCPI[0-9]+_[0-9]+}}
683 ; X87-NEXT: fcom %st(1)
685 ; X87-NEXT: fnstsw %ax
686 ; X87-NEXT: xorl %edx, %edx
687 ; X87-NEXT: # kill: def $ah killed $ah killed $ax
689 ; X87-NEXT: setbe %al
691 ; X87-NEXT: jbe .LBB9_2
693 ; X87-NEXT: fstp %st(1)
696 ; X87-NEXT: fstp %st(0)
697 ; X87-NEXT: fsubrp %st, %st(1)
699 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
700 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %ecx
701 ; X87-NEXT: orl $3072, %ecx # imm = 0xC00
702 ; X87-NEXT: movw %cx, {{[0-9]+}}(%esp)
703 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
704 ; X87-NEXT: fistpll {{[0-9]+}}(%esp)
705 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
706 ; X87-NEXT: movb %al, %dl
707 ; X87-NEXT: shll $31, %edx
708 ; X87-NEXT: xorl {{[0-9]+}}(%esp), %edx
709 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
710 ; X87-NEXT: movl %ebp, %esp
711 ; X87-NEXT: popl %ebp
712 ; X87-NEXT: .cfi_def_cfa %esp, 4
714 %result = call i64 @llvm.experimental.constrained.fptoui.i64.f32(float %x,
715 metadata !"fpexcept.strict") #0
719 define i8 @fptosi_f64toi8(double %x) #0 {
720 ; SSE-X86-LABEL: fptosi_f64toi8:
722 ; SSE-X86-NEXT: cvttsd2si {{[0-9]+}}(%esp), %eax
723 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
726 ; SSE-X64-LABEL: fptosi_f64toi8:
728 ; SSE-X64-NEXT: cvttsd2si %xmm0, %eax
729 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
732 ; AVX-X86-LABEL: fptosi_f64toi8:
734 ; AVX-X86-NEXT: vcvttsd2si {{[0-9]+}}(%esp), %eax
735 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
738 ; AVX-X64-LABEL: fptosi_f64toi8:
740 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %eax
741 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
744 ; X87-LABEL: fptosi_f64toi8:
746 ; X87-NEXT: subl $8, %esp
747 ; X87-NEXT: .cfi_def_cfa_offset 12
748 ; X87-NEXT: fldl {{[0-9]+}}(%esp)
750 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
751 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
752 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
753 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
754 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
755 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
756 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
757 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
758 ; X87-NEXT: addl $8, %esp
759 ; X87-NEXT: .cfi_def_cfa_offset 4
761 %result = call i8 @llvm.experimental.constrained.fptosi.i8.f64(double %x,
762 metadata !"fpexcept.strict") #0
766 define i16 @fptosi_f64toi16(double %x) #0 {
767 ; SSE-X86-LABEL: fptosi_f64toi16:
769 ; SSE-X86-NEXT: cvttsd2si {{[0-9]+}}(%esp), %eax
770 ; SSE-X86-NEXT: # kill: def $ax killed $ax killed $eax
773 ; SSE-X64-LABEL: fptosi_f64toi16:
775 ; SSE-X64-NEXT: cvttsd2si %xmm0, %eax
776 ; SSE-X64-NEXT: # kill: def $ax killed $ax killed $eax
779 ; AVX-X86-LABEL: fptosi_f64toi16:
781 ; AVX-X86-NEXT: vcvttsd2si {{[0-9]+}}(%esp), %eax
782 ; AVX-X86-NEXT: # kill: def $ax killed $ax killed $eax
785 ; AVX-X64-LABEL: fptosi_f64toi16:
787 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %eax
788 ; AVX-X64-NEXT: # kill: def $ax killed $ax killed $eax
791 ; X87-LABEL: fptosi_f64toi16:
793 ; X87-NEXT: subl $8, %esp
794 ; X87-NEXT: .cfi_def_cfa_offset 12
795 ; X87-NEXT: fldl {{[0-9]+}}(%esp)
797 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
798 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
799 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
800 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
801 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
802 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
803 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
804 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
805 ; X87-NEXT: addl $8, %esp
806 ; X87-NEXT: .cfi_def_cfa_offset 4
808 %result = call i16 @llvm.experimental.constrained.fptosi.i16.f64(double %x,
809 metadata !"fpexcept.strict") #0
813 define i32 @fptosi_f64toi32(double %x) #0 {
814 ; SSE-X86-LABEL: fptosi_f64toi32:
816 ; SSE-X86-NEXT: cvttsd2si {{[0-9]+}}(%esp), %eax
819 ; SSE-X64-LABEL: fptosi_f64toi32:
821 ; SSE-X64-NEXT: cvttsd2si %xmm0, %eax
824 ; AVX-X86-LABEL: fptosi_f64toi32:
826 ; AVX-X86-NEXT: vcvttsd2si {{[0-9]+}}(%esp), %eax
829 ; AVX-X64-LABEL: fptosi_f64toi32:
831 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %eax
834 ; X87-LABEL: fptosi_f64toi32:
836 ; X87-NEXT: subl $8, %esp
837 ; X87-NEXT: .cfi_def_cfa_offset 12
838 ; X87-NEXT: fldl {{[0-9]+}}(%esp)
840 ; X87-NEXT: fnstcw (%esp)
841 ; X87-NEXT: movzwl (%esp), %eax
842 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
843 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
844 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
845 ; X87-NEXT: fistpl {{[0-9]+}}(%esp)
846 ; X87-NEXT: fldcw (%esp)
847 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
848 ; X87-NEXT: addl $8, %esp
849 ; X87-NEXT: .cfi_def_cfa_offset 4
851 %result = call i32 @llvm.experimental.constrained.fptosi.i32.f64(double %x,
852 metadata !"fpexcept.strict") #0
856 define i64 @fptosi_f64toi64(double %x) #0 {
857 ; SSE-X86-LABEL: fptosi_f64toi64:
859 ; SSE-X86-NEXT: pushl %ebp
860 ; SSE-X86-NEXT: .cfi_def_cfa_offset 8
861 ; SSE-X86-NEXT: .cfi_offset %ebp, -8
862 ; SSE-X86-NEXT: movl %esp, %ebp
863 ; SSE-X86-NEXT: .cfi_def_cfa_register %ebp
864 ; SSE-X86-NEXT: andl $-8, %esp
865 ; SSE-X86-NEXT: subl $16, %esp
866 ; SSE-X86-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
867 ; SSE-X86-NEXT: movsd %xmm0, {{[0-9]+}}(%esp)
868 ; SSE-X86-NEXT: fldl {{[0-9]+}}(%esp)
870 ; SSE-X86-NEXT: fnstcw {{[0-9]+}}(%esp)
871 ; SSE-X86-NEXT: movzwl {{[0-9]+}}(%esp), %eax
872 ; SSE-X86-NEXT: orl $3072, %eax # imm = 0xC00
873 ; SSE-X86-NEXT: movw %ax, {{[0-9]+}}(%esp)
874 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
875 ; SSE-X86-NEXT: fistpll {{[0-9]+}}(%esp)
876 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
877 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
878 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %edx
879 ; SSE-X86-NEXT: movl %ebp, %esp
880 ; SSE-X86-NEXT: popl %ebp
881 ; SSE-X86-NEXT: .cfi_def_cfa %esp, 4
884 ; SSE-X64-LABEL: fptosi_f64toi64:
886 ; SSE-X64-NEXT: cvttsd2si %xmm0, %rax
889 ; AVX-X86-LABEL: fptosi_f64toi64:
891 ; AVX-X86-NEXT: pushl %ebp
892 ; AVX-X86-NEXT: .cfi_def_cfa_offset 8
893 ; AVX-X86-NEXT: .cfi_offset %ebp, -8
894 ; AVX-X86-NEXT: movl %esp, %ebp
895 ; AVX-X86-NEXT: .cfi_def_cfa_register %ebp
896 ; AVX-X86-NEXT: andl $-8, %esp
897 ; AVX-X86-NEXT: subl $8, %esp
898 ; AVX-X86-NEXT: vmovsd {{.*#+}} xmm0 = mem[0],zero
899 ; AVX-X86-NEXT: vmovsd %xmm0, (%esp)
900 ; AVX-X86-NEXT: fldl (%esp)
901 ; AVX-X86-NEXT: fisttpll (%esp)
903 ; AVX-X86-NEXT: movl (%esp), %eax
904 ; AVX-X86-NEXT: movl {{[0-9]+}}(%esp), %edx
905 ; AVX-X86-NEXT: movl %ebp, %esp
906 ; AVX-X86-NEXT: popl %ebp
907 ; AVX-X86-NEXT: .cfi_def_cfa %esp, 4
910 ; AVX-X64-LABEL: fptosi_f64toi64:
912 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %rax
915 ; X87-LABEL: fptosi_f64toi64:
917 ; X87-NEXT: pushl %ebp
918 ; X87-NEXT: .cfi_def_cfa_offset 8
919 ; X87-NEXT: .cfi_offset %ebp, -8
920 ; X87-NEXT: movl %esp, %ebp
921 ; X87-NEXT: .cfi_def_cfa_register %ebp
922 ; X87-NEXT: andl $-8, %esp
923 ; X87-NEXT: subl $16, %esp
924 ; X87-NEXT: fldl 8(%ebp)
926 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
927 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
928 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
929 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
930 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
931 ; X87-NEXT: fistpll {{[0-9]+}}(%esp)
932 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
933 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
934 ; X87-NEXT: movl {{[0-9]+}}(%esp), %edx
935 ; X87-NEXT: movl %ebp, %esp
936 ; X87-NEXT: popl %ebp
937 ; X87-NEXT: .cfi_def_cfa %esp, 4
939 %result = call i64 @llvm.experimental.constrained.fptosi.i64.f64(double %x,
940 metadata !"fpexcept.strict") #0
944 define i1 @fptoui_f64toi1(double %x) #0 {
945 ; SSE-X86-LABEL: fptoui_f64toi1:
947 ; SSE-X86-NEXT: cvttsd2si {{[0-9]+}}(%esp), %eax
948 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
951 ; SSE-X64-LABEL: fptoui_f64toi1:
953 ; SSE-X64-NEXT: cvttsd2si %xmm0, %eax
954 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
957 ; AVX-X86-LABEL: fptoui_f64toi1:
959 ; AVX-X86-NEXT: vcvttsd2si {{[0-9]+}}(%esp), %eax
960 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
963 ; AVX-X64-LABEL: fptoui_f64toi1:
965 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %eax
966 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
969 ; X87-LABEL: fptoui_f64toi1:
971 ; X87-NEXT: subl $8, %esp
972 ; X87-NEXT: .cfi_def_cfa_offset 12
973 ; X87-NEXT: fldl {{[0-9]+}}(%esp)
975 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
976 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
977 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
978 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
979 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
980 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
981 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
982 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
983 ; X87-NEXT: addl $8, %esp
984 ; X87-NEXT: .cfi_def_cfa_offset 4
986 %result = call i1 @llvm.experimental.constrained.fptoui.i1.f64(double %x,
987 metadata !"fpexcept.strict") #0
991 define i8 @fptoui_f64toi8(double %x) #0 {
992 ; SSE-X86-LABEL: fptoui_f64toi8:
994 ; SSE-X86-NEXT: cvttsd2si {{[0-9]+}}(%esp), %eax
995 ; SSE-X86-NEXT: # kill: def $al killed $al killed $eax
998 ; SSE-X64-LABEL: fptoui_f64toi8:
1000 ; SSE-X64-NEXT: cvttsd2si %xmm0, %eax
1001 ; SSE-X64-NEXT: # kill: def $al killed $al killed $eax
1002 ; SSE-X64-NEXT: retq
1004 ; AVX-X86-LABEL: fptoui_f64toi8:
1006 ; AVX-X86-NEXT: vcvttsd2si {{[0-9]+}}(%esp), %eax
1007 ; AVX-X86-NEXT: # kill: def $al killed $al killed $eax
1008 ; AVX-X86-NEXT: retl
1010 ; AVX-X64-LABEL: fptoui_f64toi8:
1012 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %eax
1013 ; AVX-X64-NEXT: # kill: def $al killed $al killed $eax
1014 ; AVX-X64-NEXT: retq
1016 ; X87-LABEL: fptoui_f64toi8:
1018 ; X87-NEXT: subl $8, %esp
1019 ; X87-NEXT: .cfi_def_cfa_offset 12
1020 ; X87-NEXT: fldl {{[0-9]+}}(%esp)
1022 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
1023 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
1024 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
1025 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
1026 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1027 ; X87-NEXT: fistps {{[0-9]+}}(%esp)
1028 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1029 ; X87-NEXT: movzbl {{[0-9]+}}(%esp), %eax
1030 ; X87-NEXT: addl $8, %esp
1031 ; X87-NEXT: .cfi_def_cfa_offset 4
1033 %result = call i8 @llvm.experimental.constrained.fptoui.i8.f64(double %x,
1034 metadata !"fpexcept.strict") #0
1038 define i16 @fptoui_f64toi16(double %x) #0 {
1039 ; SSE-X86-LABEL: fptoui_f64toi16:
1041 ; SSE-X86-NEXT: cvttsd2si {{[0-9]+}}(%esp), %eax
1042 ; SSE-X86-NEXT: # kill: def $ax killed $ax killed $eax
1043 ; SSE-X86-NEXT: retl
1045 ; SSE-X64-LABEL: fptoui_f64toi16:
1047 ; SSE-X64-NEXT: cvttsd2si %xmm0, %eax
1048 ; SSE-X64-NEXT: # kill: def $ax killed $ax killed $eax
1049 ; SSE-X64-NEXT: retq
1051 ; AVX-X86-LABEL: fptoui_f64toi16:
1053 ; AVX-X86-NEXT: vcvttsd2si {{[0-9]+}}(%esp), %eax
1054 ; AVX-X86-NEXT: # kill: def $ax killed $ax killed $eax
1055 ; AVX-X86-NEXT: retl
1057 ; AVX-X64-LABEL: fptoui_f64toi16:
1059 ; AVX-X64-NEXT: vcvttsd2si %xmm0, %eax
1060 ; AVX-X64-NEXT: # kill: def $ax killed $ax killed $eax
1061 ; AVX-X64-NEXT: retq
1063 ; X87-LABEL: fptoui_f64toi16:
1065 ; X87-NEXT: subl $8, %esp
1066 ; X87-NEXT: .cfi_def_cfa_offset 12
1067 ; X87-NEXT: fldl {{[0-9]+}}(%esp)
1069 ; X87-NEXT: fnstcw (%esp)
1070 ; X87-NEXT: movzwl (%esp), %eax
1071 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
1072 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
1073 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1074 ; X87-NEXT: fistpl {{[0-9]+}}(%esp)
1075 ; X87-NEXT: fldcw (%esp)
1076 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
1077 ; X87-NEXT: # kill: def $ax killed $ax killed $eax
1078 ; X87-NEXT: addl $8, %esp
1079 ; X87-NEXT: .cfi_def_cfa_offset 4
1081 %result = call i16 @llvm.experimental.constrained.fptoui.i16.f64(double %x,
1082 metadata !"fpexcept.strict") #0
1086 define i32 @fptoui_f64toi32(double %x) #0 {
1087 ; SSE-X86-LABEL: fptoui_f64toi32:
1089 ; SSE-X86-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
1090 ; SSE-X86-NEXT: movsd {{.*#+}} xmm2 = mem[0],zero
1091 ; SSE-X86-NEXT: comisd %xmm0, %xmm2
1092 ; SSE-X86-NEXT: xorpd %xmm1, %xmm1
1093 ; SSE-X86-NEXT: ja .LBB17_2
1094 ; SSE-X86-NEXT: # %bb.1:
1095 ; SSE-X86-NEXT: movapd %xmm2, %xmm1
1096 ; SSE-X86-NEXT: .LBB17_2:
1097 ; SSE-X86-NEXT: setbe %al
1098 ; SSE-X86-NEXT: movzbl %al, %ecx
1099 ; SSE-X86-NEXT: shll $31, %ecx
1100 ; SSE-X86-NEXT: subsd %xmm1, %xmm0
1101 ; SSE-X86-NEXT: cvttsd2si %xmm0, %eax
1102 ; SSE-X86-NEXT: xorl %ecx, %eax
1103 ; SSE-X86-NEXT: retl
1105 ; SSE-X64-LABEL: fptoui_f64toi32:
1107 ; SSE-X64-NEXT: cvttsd2si %xmm0, %rax
1108 ; SSE-X64-NEXT: # kill: def $eax killed $eax killed $rax
1109 ; SSE-X64-NEXT: retq
1111 ; AVX1-X86-LABEL: fptoui_f64toi32:
1112 ; AVX1-X86: # %bb.0:
1113 ; AVX1-X86-NEXT: pushl %ebp
1114 ; AVX1-X86-NEXT: .cfi_def_cfa_offset 8
1115 ; AVX1-X86-NEXT: .cfi_offset %ebp, -8
1116 ; AVX1-X86-NEXT: movl %esp, %ebp
1117 ; AVX1-X86-NEXT: .cfi_def_cfa_register %ebp
1118 ; AVX1-X86-NEXT: andl $-8, %esp
1119 ; AVX1-X86-NEXT: subl $8, %esp
1120 ; AVX1-X86-NEXT: vmovsd {{.*#+}} xmm0 = mem[0],zero
1121 ; AVX1-X86-NEXT: vmovsd %xmm0, (%esp)
1122 ; AVX1-X86-NEXT: fldl (%esp)
1123 ; AVX1-X86-NEXT: fisttpll (%esp)
1124 ; AVX1-X86-NEXT: wait
1125 ; AVX1-X86-NEXT: movl (%esp), %eax
1126 ; AVX1-X86-NEXT: movl %ebp, %esp
1127 ; AVX1-X86-NEXT: popl %ebp
1128 ; AVX1-X86-NEXT: .cfi_def_cfa %esp, 4
1129 ; AVX1-X86-NEXT: retl
1131 ; AVX1-X64-LABEL: fptoui_f64toi32:
1132 ; AVX1-X64: # %bb.0:
1133 ; AVX1-X64-NEXT: vcvttsd2si %xmm0, %rax
1134 ; AVX1-X64-NEXT: # kill: def $eax killed $eax killed $rax
1135 ; AVX1-X64-NEXT: retq
1137 ; AVX512-X86-LABEL: fptoui_f64toi32:
1138 ; AVX512-X86: # %bb.0:
1139 ; AVX512-X86-NEXT: vcvttsd2usi {{[0-9]+}}(%esp), %eax
1140 ; AVX512-X86-NEXT: retl
1142 ; AVX512-X64-LABEL: fptoui_f64toi32:
1143 ; AVX512-X64: # %bb.0:
1144 ; AVX512-X64-NEXT: vcvttsd2usi %xmm0, %eax
1145 ; AVX512-X64-NEXT: retq
1147 ; X87-LABEL: fptoui_f64toi32:
1149 ; X87-NEXT: pushl %ebp
1150 ; X87-NEXT: .cfi_def_cfa_offset 8
1151 ; X87-NEXT: .cfi_offset %ebp, -8
1152 ; X87-NEXT: movl %esp, %ebp
1153 ; X87-NEXT: .cfi_def_cfa_register %ebp
1154 ; X87-NEXT: andl $-8, %esp
1155 ; X87-NEXT: subl $16, %esp
1156 ; X87-NEXT: fldl 8(%ebp)
1158 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
1159 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %eax
1160 ; X87-NEXT: orl $3072, %eax # imm = 0xC00
1161 ; X87-NEXT: movw %ax, {{[0-9]+}}(%esp)
1162 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1163 ; X87-NEXT: fistpll {{[0-9]+}}(%esp)
1164 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1165 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
1166 ; X87-NEXT: movl %ebp, %esp
1167 ; X87-NEXT: popl %ebp
1168 ; X87-NEXT: .cfi_def_cfa %esp, 4
1170 %result = call i32 @llvm.experimental.constrained.fptoui.i32.f64(double %x,
1171 metadata !"fpexcept.strict") #0
1175 define i64 @fptoui_f64toi64(double %x) #0 {
1176 ; SSE-X86-LABEL: fptoui_f64toi64:
1178 ; SSE-X86-NEXT: pushl %ebp
1179 ; SSE-X86-NEXT: .cfi_def_cfa_offset 8
1180 ; SSE-X86-NEXT: .cfi_offset %ebp, -8
1181 ; SSE-X86-NEXT: movl %esp, %ebp
1182 ; SSE-X86-NEXT: .cfi_def_cfa_register %ebp
1183 ; SSE-X86-NEXT: andl $-8, %esp
1184 ; SSE-X86-NEXT: subl $16, %esp
1185 ; SSE-X86-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
1186 ; SSE-X86-NEXT: movsd {{.*#+}} xmm1 = mem[0],zero
1187 ; SSE-X86-NEXT: comisd %xmm0, %xmm1
1188 ; SSE-X86-NEXT: jbe .LBB18_2
1189 ; SSE-X86-NEXT: # %bb.1:
1190 ; SSE-X86-NEXT: xorpd %xmm1, %xmm1
1191 ; SSE-X86-NEXT: .LBB18_2:
1192 ; SSE-X86-NEXT: subsd %xmm1, %xmm0
1193 ; SSE-X86-NEXT: movsd %xmm0, {{[0-9]+}}(%esp)
1194 ; SSE-X86-NEXT: setbe %al
1195 ; SSE-X86-NEXT: fldl {{[0-9]+}}(%esp)
1196 ; SSE-X86-NEXT: wait
1197 ; SSE-X86-NEXT: fnstcw {{[0-9]+}}(%esp)
1198 ; SSE-X86-NEXT: movzwl {{[0-9]+}}(%esp), %ecx
1199 ; SSE-X86-NEXT: orl $3072, %ecx # imm = 0xC00
1200 ; SSE-X86-NEXT: movw %cx, {{[0-9]+}}(%esp)
1201 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
1202 ; SSE-X86-NEXT: fistpll {{[0-9]+}}(%esp)
1203 ; SSE-X86-NEXT: fldcw {{[0-9]+}}(%esp)
1204 ; SSE-X86-NEXT: movzbl %al, %edx
1205 ; SSE-X86-NEXT: shll $31, %edx
1206 ; SSE-X86-NEXT: xorl {{[0-9]+}}(%esp), %edx
1207 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
1208 ; SSE-X86-NEXT: movl %ebp, %esp
1209 ; SSE-X86-NEXT: popl %ebp
1210 ; SSE-X86-NEXT: .cfi_def_cfa %esp, 4
1211 ; SSE-X86-NEXT: retl
1213 ; SSE-X64-LABEL: fptoui_f64toi64:
1215 ; SSE-X64-NEXT: movsd {{.*#+}} xmm2 = mem[0],zero
1216 ; SSE-X64-NEXT: comisd %xmm2, %xmm0
1217 ; SSE-X64-NEXT: xorpd %xmm1, %xmm1
1218 ; SSE-X64-NEXT: jb .LBB18_2
1219 ; SSE-X64-NEXT: # %bb.1:
1220 ; SSE-X64-NEXT: movapd %xmm2, %xmm1
1221 ; SSE-X64-NEXT: .LBB18_2:
1222 ; SSE-X64-NEXT: subsd %xmm1, %xmm0
1223 ; SSE-X64-NEXT: cvttsd2si %xmm0, %rcx
1224 ; SSE-X64-NEXT: setae %al
1225 ; SSE-X64-NEXT: movzbl %al, %eax
1226 ; SSE-X64-NEXT: shlq $63, %rax
1227 ; SSE-X64-NEXT: xorq %rcx, %rax
1228 ; SSE-X64-NEXT: retq
1230 ; AVX1-X86-LABEL: fptoui_f64toi64:
1231 ; AVX1-X86: # %bb.0:
1232 ; AVX1-X86-NEXT: pushl %ebp
1233 ; AVX1-X86-NEXT: .cfi_def_cfa_offset 8
1234 ; AVX1-X86-NEXT: .cfi_offset %ebp, -8
1235 ; AVX1-X86-NEXT: movl %esp, %ebp
1236 ; AVX1-X86-NEXT: .cfi_def_cfa_register %ebp
1237 ; AVX1-X86-NEXT: andl $-8, %esp
1238 ; AVX1-X86-NEXT: subl $8, %esp
1239 ; AVX1-X86-NEXT: vmovsd {{.*#+}} xmm0 = mem[0],zero
1240 ; AVX1-X86-NEXT: vmovsd {{.*#+}} xmm1 = mem[0],zero
1241 ; AVX1-X86-NEXT: vcomisd %xmm0, %xmm1
1242 ; AVX1-X86-NEXT: jbe .LBB18_2
1243 ; AVX1-X86-NEXT: # %bb.1:
1244 ; AVX1-X86-NEXT: vxorpd %xmm1, %xmm1, %xmm1
1245 ; AVX1-X86-NEXT: .LBB18_2:
1246 ; AVX1-X86-NEXT: vsubsd %xmm1, %xmm0, %xmm0
1247 ; AVX1-X86-NEXT: vmovsd %xmm0, (%esp)
1248 ; AVX1-X86-NEXT: fldl (%esp)
1249 ; AVX1-X86-NEXT: fisttpll (%esp)
1250 ; AVX1-X86-NEXT: wait
1251 ; AVX1-X86-NEXT: setbe %al
1252 ; AVX1-X86-NEXT: movzbl %al, %edx
1253 ; AVX1-X86-NEXT: shll $31, %edx
1254 ; AVX1-X86-NEXT: xorl {{[0-9]+}}(%esp), %edx
1255 ; AVX1-X86-NEXT: movl (%esp), %eax
1256 ; AVX1-X86-NEXT: movl %ebp, %esp
1257 ; AVX1-X86-NEXT: popl %ebp
1258 ; AVX1-X86-NEXT: .cfi_def_cfa %esp, 4
1259 ; AVX1-X86-NEXT: retl
1261 ; AVX1-X64-LABEL: fptoui_f64toi64:
1262 ; AVX1-X64: # %bb.0:
1263 ; AVX1-X64-NEXT: vmovsd {{.*#+}} xmm1 = mem[0],zero
1264 ; AVX1-X64-NEXT: vcomisd %xmm1, %xmm0
1265 ; AVX1-X64-NEXT: vxorpd %xmm2, %xmm2, %xmm2
1266 ; AVX1-X64-NEXT: jb .LBB18_2
1267 ; AVX1-X64-NEXT: # %bb.1:
1268 ; AVX1-X64-NEXT: vmovapd %xmm1, %xmm2
1269 ; AVX1-X64-NEXT: .LBB18_2:
1270 ; AVX1-X64-NEXT: vsubsd %xmm2, %xmm0, %xmm0
1271 ; AVX1-X64-NEXT: vcvttsd2si %xmm0, %rcx
1272 ; AVX1-X64-NEXT: setae %al
1273 ; AVX1-X64-NEXT: movzbl %al, %eax
1274 ; AVX1-X64-NEXT: shlq $63, %rax
1275 ; AVX1-X64-NEXT: xorq %rcx, %rax
1276 ; AVX1-X64-NEXT: retq
1278 ; AVX512-X86-LABEL: fptoui_f64toi64:
1279 ; AVX512-X86: # %bb.0:
1280 ; AVX512-X86-NEXT: pushl %ebp
1281 ; AVX512-X86-NEXT: .cfi_def_cfa_offset 8
1282 ; AVX512-X86-NEXT: .cfi_offset %ebp, -8
1283 ; AVX512-X86-NEXT: movl %esp, %ebp
1284 ; AVX512-X86-NEXT: .cfi_def_cfa_register %ebp
1285 ; AVX512-X86-NEXT: andl $-8, %esp
1286 ; AVX512-X86-NEXT: subl $8, %esp
1287 ; AVX512-X86-NEXT: vmovsd {{.*#+}} xmm0 = mem[0],zero
1288 ; AVX512-X86-NEXT: vmovsd {{.*#+}} xmm1 = mem[0],zero
1289 ; AVX512-X86-NEXT: xorl %edx, %edx
1290 ; AVX512-X86-NEXT: vcomisd %xmm0, %xmm1
1291 ; AVX512-X86-NEXT: setbe %dl
1292 ; AVX512-X86-NEXT: kmovw %edx, %k1
1293 ; AVX512-X86-NEXT: vmovsd %xmm1, %xmm1, %xmm1 {%k1} {z}
1294 ; AVX512-X86-NEXT: vsubsd %xmm1, %xmm0, %xmm0
1295 ; AVX512-X86-NEXT: vmovsd %xmm0, (%esp)
1296 ; AVX512-X86-NEXT: fldl (%esp)
1297 ; AVX512-X86-NEXT: fisttpll (%esp)
1298 ; AVX512-X86-NEXT: wait
1299 ; AVX512-X86-NEXT: shll $31, %edx
1300 ; AVX512-X86-NEXT: xorl {{[0-9]+}}(%esp), %edx
1301 ; AVX512-X86-NEXT: movl (%esp), %eax
1302 ; AVX512-X86-NEXT: movl %ebp, %esp
1303 ; AVX512-X86-NEXT: popl %ebp
1304 ; AVX512-X86-NEXT: .cfi_def_cfa %esp, 4
1305 ; AVX512-X86-NEXT: retl
1307 ; AVX512-X64-LABEL: fptoui_f64toi64:
1308 ; AVX512-X64: # %bb.0:
1309 ; AVX512-X64-NEXT: vcvttsd2usi %xmm0, %rax
1310 ; AVX512-X64-NEXT: retq
1312 ; X87-LABEL: fptoui_f64toi64:
1314 ; X87-NEXT: pushl %ebp
1315 ; X87-NEXT: .cfi_def_cfa_offset 8
1316 ; X87-NEXT: .cfi_offset %ebp, -8
1317 ; X87-NEXT: movl %esp, %ebp
1318 ; X87-NEXT: .cfi_def_cfa_register %ebp
1319 ; X87-NEXT: andl $-8, %esp
1320 ; X87-NEXT: subl $16, %esp
1321 ; X87-NEXT: fldl 8(%ebp)
1322 ; X87-NEXT: flds {{\.?LCPI[0-9]+_[0-9]+}}
1323 ; X87-NEXT: fcom %st(1)
1325 ; X87-NEXT: fnstsw %ax
1326 ; X87-NEXT: xorl %edx, %edx
1327 ; X87-NEXT: # kill: def $ah killed $ah killed $ax
1329 ; X87-NEXT: setbe %al
1331 ; X87-NEXT: jbe .LBB18_2
1332 ; X87-NEXT: # %bb.1:
1333 ; X87-NEXT: fstp %st(1)
1335 ; X87-NEXT: .LBB18_2:
1336 ; X87-NEXT: fstp %st(0)
1337 ; X87-NEXT: fsubrp %st, %st(1)
1339 ; X87-NEXT: fnstcw {{[0-9]+}}(%esp)
1340 ; X87-NEXT: movzwl {{[0-9]+}}(%esp), %ecx
1341 ; X87-NEXT: orl $3072, %ecx # imm = 0xC00
1342 ; X87-NEXT: movw %cx, {{[0-9]+}}(%esp)
1343 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1344 ; X87-NEXT: fistpll {{[0-9]+}}(%esp)
1345 ; X87-NEXT: fldcw {{[0-9]+}}(%esp)
1346 ; X87-NEXT: movb %al, %dl
1347 ; X87-NEXT: shll $31, %edx
1348 ; X87-NEXT: xorl {{[0-9]+}}(%esp), %edx
1349 ; X87-NEXT: movl {{[0-9]+}}(%esp), %eax
1350 ; X87-NEXT: movl %ebp, %esp
1351 ; X87-NEXT: popl %ebp
1352 ; X87-NEXT: .cfi_def_cfa %esp, 4
1354 %result = call i64 @llvm.experimental.constrained.fptoui.i64.f64(double %x,
1355 metadata !"fpexcept.strict") #0
1359 attributes #0 = { strictfp }