For PR1271:

Fix another incorrectly converted shift mask.

llvm-svn: 35371
This commit is contained in:
Reid Spencer 2007-03-26 23:45:51 +00:00
parent 4398e242dd
commit 441486c172
1 changed files with 1 additions and 1 deletions

View File

@ -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));
}