1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=i686-- -mcpu=i386 | FileCheck %s --check-prefix=BASE
3 ; RUN: llc < %s -mtriple=i686-- -mcpu=pentiumpro | FileCheck %s --check-prefix=CMOV
6 define float @foo(ptr %col) {
9 ; BASE-NEXT: movl {{[0-9]+}}(%esp), %eax
10 ; BASE-NEXT: flds (%eax)
11 ; BASE-NEXT: fld %st(0)
13 ; BASE-NEXT: fucom %st(1)
14 ; BASE-NEXT: fnstsw %ax
15 ; BASE-NEXT: # kill: def $ah killed $ah killed $ax
17 ; BASE-NEXT: ja .LBB0_2
19 ; BASE-NEXT: fstp %st(0)
21 ; BASE-NEXT: fxch %st(1)
23 ; BASE-NEXT: fstp %st(1)
28 ; CMOV-NEXT: movl {{[0-9]+}}(%esp), %eax
29 ; CMOV-NEXT: flds (%eax)
30 ; CMOV-NEXT: fld %st(0)
32 ; CMOV-NEXT: fucomi %st(1), %st
33 ; CMOV-NEXT: fxch %st(1)
34 ; CMOV-NEXT: fcmovnbe %st(1), %st
35 ; CMOV-NEXT: fstp %st(1)
37 %t = load float, ptr %col
38 %t16 = fcmp olt float %t, 0.0
39 %t20 = fsub float -0.000000e+00, %t
40 %ift = select i1 %t16, float %t20, float %t