diff options
| author | Chris Lattner <sabre@nondot.org> | 2004-10-22 04:53:16 +0000 | 
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2004-10-22 04:53:16 +0000 | 
| commit | 5c3c21e10a84c73671bda1ca497fe3208d5fab5c (patch) | |
| tree | 2caa61882531bcd45353302075245b689b6b1e40 /llvm/lib | |
| parent | 35572eb6f98edd24e630c6bc9023b08443cc5841 (diff) | |
| download | bcm5719-llvm-5c3c21e10a84c73671bda1ca497fe3208d5fab5c.tar.gz bcm5719-llvm-5c3c21e10a84c73671bda1ca497fe3208d5fab5c.zip | |
Fix a bug Nate noticed, where we miscompiled a simple testcase
llvm-svn: 17157
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/InstructionCombining.cpp | 2 | 
1 files changed, 1 insertions, 1 deletions
| diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp index 3119e570440..61acad04f32 100644 --- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp @@ -1285,7 +1285,7 @@ Instruction *InstCombiner::OptAndOp(Instruction *Op,          Constant *AllOne = ConstantIntegral::getAllOnesValue(AndRHS->getType());          Constant *ShrMask = ConstantExpr::getUShr(AllOne, OpRHS);          Constant *CI = ConstantExpr::getAnd(AndRHS, ShrMask); -        if (CI == ShrMask) {          // Masking out bits shifted in. +        if (CI == AndRHS) {          // Masking out bits shifted in.            // Make the argument unsigned.            Value *ShVal = Op->getOperand(0);            ShVal = InsertCastBefore(ShVal, | 

