mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-06 01:24:35 +00:00
Rename ComputeMaskedBits to computeKnownBits. "Masked" has been
inappropriate since it lost its Mask parameter in r154011. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208811 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -979,7 +979,7 @@ Instruction *InstCombiner::visitAdd(BinaryOperator &I) {
|
||||
IntegerType *IT = cast<IntegerType>(I.getType());
|
||||
APInt LHSKnownOne(IT->getBitWidth(), 0);
|
||||
APInt LHSKnownZero(IT->getBitWidth(), 0);
|
||||
ComputeMaskedBits(XorLHS, LHSKnownZero, LHSKnownOne);
|
||||
computeKnownBits(XorLHS, LHSKnownZero, LHSKnownOne);
|
||||
if ((XorRHS->getValue() | LHSKnownZero).isAllOnesValue())
|
||||
return BinaryOperator::CreateSub(ConstantExpr::getAdd(XorRHS, CI),
|
||||
XorLHS);
|
||||
@ -1047,11 +1047,11 @@ Instruction *InstCombiner::visitAdd(BinaryOperator &I) {
|
||||
if (IntegerType *IT = dyn_cast<IntegerType>(I.getType())) {
|
||||
APInt LHSKnownOne(IT->getBitWidth(), 0);
|
||||
APInt LHSKnownZero(IT->getBitWidth(), 0);
|
||||
ComputeMaskedBits(LHS, LHSKnownZero, LHSKnownOne);
|
||||
computeKnownBits(LHS, LHSKnownZero, LHSKnownOne);
|
||||
if (LHSKnownZero != 0) {
|
||||
APInt RHSKnownOne(IT->getBitWidth(), 0);
|
||||
APInt RHSKnownZero(IT->getBitWidth(), 0);
|
||||
ComputeMaskedBits(RHS, RHSKnownZero, RHSKnownOne);
|
||||
computeKnownBits(RHS, RHSKnownZero, RHSKnownOne);
|
||||
|
||||
// No bits in common -> bitwise or.
|
||||
if ((LHSKnownZero|RHSKnownZero).isAllOnesValue())
|
||||
|
Reference in New Issue
Block a user