mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-04 09:45:00 +00:00
[InstCombine] Use replaceOperand() in descaling
To make sure the old operand gets DCEd. NFC apart from worklist order.
This commit is contained in:
parent
34dcec4690
commit
dcd53dc437
@ -1481,7 +1481,7 @@ Value *InstCombiner::Descale(Value *Val, APInt Scale, bool &NoSignedWrap) {
|
||||
assert(Parent.first->hasOneUse() && "Drilled down when more than one use!");
|
||||
assert(Op != Parent.first->getOperand(Parent.second) &&
|
||||
"Descaling was a no-op?");
|
||||
Parent.first->setOperand(Parent.second, Op);
|
||||
replaceOperand(*Parent.first, Parent.second, Op);
|
||||
Worklist.push(Parent.first);
|
||||
|
||||
// Now work back up the expression correcting nsw flags. The logic is based
|
||||
|
Loading…
Reference in New Issue
Block a user