llvm-6502/test/CodeGen/Mips/fneg.ll
Akira Hatanaka 1cc6333161 Emit neg.s or neg.d only if -enable-no-nans-fp-math is supplied by user,
otherwise expand FNEG during legalization.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154546 91177308-0d34-0410-b5e6-96231b3b80d8
2012-04-11 22:59:08 +00:00

18 lines
374 B
LLVM

; RUN: llc < %s -march=mipsel -mcpu=mips32 | FileCheck %s
define float @foo0(i32 %a, float %d) nounwind readnone {
entry:
; CHECK-NOT: fabs.s
%sub = fsub float -0.000000e+00, %d
ret float %sub
}
define double @foo1(i32 %a, double %d) nounwind readnone {
entry:
; CHECK: foo1
; CHECK-NOT: fabs.d
; CHECK: jr
%sub = fsub double -0.000000e+00, %d
ret double %sub
}