aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2008-11-30 12:41:09 +0000
committerBill Wendling <isanbard@gmail.com>2008-11-30 12:41:09 +0000
commit7c7048ecc688d57d10689009719dc2513a03250e (patch)
treee7589a383e6de9c02fa7ec6bc9daa38cacf2f250
parent6e1783fb4aec3a9a489e37c91dfc7a649383864e (diff)
Forgot one remaining call to getSExtValue().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60289 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Transforms/Scalar/InstructionCombining.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/InstructionCombining.cpp b/lib/Transforms/Scalar/InstructionCombining.cpp
index 93510f0593..8716e9a8a6 100644
--- a/lib/Transforms/Scalar/InstructionCombining.cpp
+++ b/lib/Transforms/Scalar/InstructionCombining.cpp
@@ -2968,7 +2968,7 @@ Instruction *InstCombiner::visitSDiv(BinaryOperator &I) {
if (Value *LHSNeg = dyn_castNegVal(Op0)) {
if (ConstantInt *CI = dyn_cast<ConstantInt>(LHSNeg)) {
ConstantInt *CINeg = cast<ConstantInt>(ConstantExpr::getNeg(CI));
- APInt CINegAPI(CINeg->getBitWidth(), CINeg->getSExtValue(), true);
+ APInt CINegAPI(CINeg->getValue());
if ((CI->getValue().isNegative() && CINegAPI.slt(TwoToExp - 1)) ||
(CI->getValue().isNonNegative() && CINegAPI.sgt(TwoToExp*NegOne)))