mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-15 22:28:18 +00:00
Don't forget to remove phi nodes from the value numbering table after we collapse them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61358 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1313,6 +1313,8 @@ bool GVN::processInstruction(Instruction *I,
|
|||||||
p->replaceAllUsesWith(constVal);
|
p->replaceAllUsesWith(constVal);
|
||||||
if (isa<PointerType>(constVal->getType()))
|
if (isa<PointerType>(constVal->getType()))
|
||||||
MD->invalidateCachedPointerInfo(constVal);
|
MD->invalidateCachedPointerInfo(constVal);
|
||||||
|
VN.erase(p);
|
||||||
|
|
||||||
toErase.push_back(p);
|
toErase.push_back(p);
|
||||||
} else {
|
} else {
|
||||||
localAvail[I->getParent()]->table.insert(std::make_pair(num, I));
|
localAvail[I->getParent()]->table.insert(std::make_pair(num, I));
|
||||||
|
Reference in New Issue
Block a user