1 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -x86-asm-syntax=intel -mcpu=i486 | \
2 ; RUN: grep {fadd\\|fsub\\|fdiv\\|fmul} | not grep -i ST
4 ; Test that the load of the constant is folded into the operation.
6 double %foo_add(double %P) {
7 %tmp.1 = add double %P, 0x405EC00000000000
11 double %foo_mul(double %P) {
12 %tmp.1 = mul double %P, 0x405EC00000000000
16 double %foo_sub(double %P) {
17 %tmp.1 = sub double %P, 0x405EC00000000000
21 double %foo_subr(double %P) {
22 %tmp.1 = sub double 0x405EC00000000000, %P
26 double %foo_div(double %P) {
27 %tmp.1 = div double %P, 0x405EC00000000000
31 double %foo_divr(double %P) {
32 %tmp.1 = div double 0x405EC00000000000, %P