summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2007-03-26 23:45:51 +0000
committerReid Spencer <rspencer@reidspencer.com>2007-03-26 23:45:51 +0000
commit441486c17257ab555b2a1b15d8c323e7ea51b31a (patch)
tree6309c8f8b3444a7a55762d5b93729ca0c820ffaf /llvm/lib/Transforms/Scalar/InstructionCombining.cpp
parent4398e242dd588e3fd054d93da7b7354fb2a86e39 (diff)
downloadbcm5719-llvm-441486c17257ab555b2a1b15d8c323e7ea51b31a.tar.gz
bcm5719-llvm-441486c17257ab555b2a1b15d8c323e7ea51b31a.zip
For PR1271:
Fix another incorrectly converted shift mask. llvm-svn: 35371
Diffstat (limited to 'llvm/lib/Transforms/Scalar/InstructionCombining.cpp')
-rw-r--r--llvm/lib/Transforms/Scalar/InstructionCombining.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
index 3c06558d15b..b7c14c6f003 100644
--- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
+++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
@@ -5887,7 +5887,7 @@ Instruction *InstCombiner::FoldShiftByConstant(Value *Op0, ConstantInt *Op1,
BinaryOperator::createShl(X, ConstantInt::get(Ty, ShiftDiff));
InsertNewInstBefore(Shift, I);
- APInt Mask(APInt::getHighBitsSet(TypeBits, TypeBits - ShiftAmt2));
+ APInt Mask(APInt::getLowBitsSet(TypeBits, TypeBits - ShiftAmt2));
return BinaryOperator::createAnd(Shift, ConstantInt::get(Mask));
}
OpenPOWER on IntegriCloud