mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-12 18:33:22 +00:00
Fix regression on 400.perlbench last night.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32486 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a898ce687a
commit
078b631ff3
@ -3112,7 +3112,7 @@ Instruction *InstCombiner::visitAnd(BinaryOperator &I) {
|
||||
} else if (CastOp->getOpcode() == Instruction::Or) {
|
||||
// Change: and (cast (or X, C1) to T), C2
|
||||
// into : trunc(C1)&C2 iff trunc(C1)&C2 == C2
|
||||
Constant *C3 = ConstantExpr::getBitCast(AndCI, I.getType());
|
||||
Constant *C3 = ConstantExpr::getTrunc(AndCI, I.getType());
|
||||
if (ConstantExpr::getAnd(C3, AndRHS) == AndRHS) // trunc(C1)&C2
|
||||
return ReplaceInstUsesWith(I, AndRHS);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user