More fcopysign correctness and performance fix.
authorEvan Cheng <evan.cheng@apple.com>
Wed, 23 Feb 2011 02:24:55 +0000 (02:24 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Wed, 23 Feb 2011 02:24:55 +0000 (02:24 +0000)
commite573fb32556ba8430ccd723f71233cdf56b76340
tree5a0d83b9a67c56dad00cf86a21ec6ed04e3bbfd5
parentd2a50734234a80893ad71da90d9f32032c47e000
More fcopysign correctness and performance fix.
The previous codegen for the slow path (when values are in VFP / NEON
registers) was incorrect if the source is NaN.

The new codegen uses NEON vbsl instruction to copy the sign bit. e.g.
        vmov.i32        d1, #0x80000000
        vbsl    d1, d2, d0
If NEON is not available, it uses integer instructions to copy the sign bit.
rdar://9034702

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126295 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMISelLowering.cpp
test/CodeGen/ARM/fcopysign.ll