diff options
author | Hal Finkel <hfinkel@anl.gov> | 2013-08-19 23:35:24 +0000 |
---|---|---|
committer | Hal Finkel <hfinkel@anl.gov> | 2013-08-19 23:35:24 +0000 |
commit | 1cf48ab811b341cf2ee3d7e9a9c97cf2d7b53f64 (patch) | |
tree | e7483fc0014d84dcd94f1573b160e4cafd986668 /llvm/lib/Target/PowerPC/PPCCTRLoops.cpp | |
parent | 4612fed911f5ef5c14158f960cab06fdff200dab (diff) | |
download | bcm5719-llvm-1cf48ab811b341cf2ee3d7e9a9c97cf2d7b53f64.tar.gz bcm5719-llvm-1cf48ab811b341cf2ee3d7e9a9c97cf2d7b53f64.zip |
Don't form PPC CTR-based loops around a copysignl call
copysign/copysignf never become function calls (because the SDAG expansion code
does not lower to the corresponding function call, but rather directly
implements the associated logic), but copysignl almost always is lowered into a
call to the requested libm functon (and, thus, might clobber CTR).
llvm-svn: 188727
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCCTRLoops.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCCTRLoops.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCCTRLoops.cpp b/llvm/lib/Target/PowerPC/PPCCTRLoops.cpp index 05dad8a094d..d9f132363b1 100644 --- a/llvm/lib/Target/PowerPC/PPCCTRLoops.cpp +++ b/llvm/lib/Target/PowerPC/PPCCTRLoops.cpp @@ -284,8 +284,9 @@ bool PPCCTRLoops::mightUseCTR(const Triple &TT, BasicBlock *BB) { default: return true; case LibFunc::copysign: case LibFunc::copysignf: - case LibFunc::copysignl: continue; // ISD::FCOPYSIGN is never a library call. + case LibFunc::copysignl: + return true; case LibFunc::fabs: case LibFunc::fabsf: case LibFunc::fabsl: |