mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-27 16:17:17 +00:00
Add ability to remove nodes from DominatorTree, for when a BasicBlock
is being removed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30270 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -399,6 +399,14 @@ public:
|
|||||||
N->setIDom(NewIDom);
|
N->setIDom(NewIDom);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// removeNode - Removes a node from the dominator tree. Block must not
|
||||||
|
/// dominate any other blocks. Invalidates any node pointing to removed
|
||||||
|
/// block.
|
||||||
|
void removeNode(BasicBlock *BB) {
|
||||||
|
assert(getNode(BB) && "Removing node that isn't in dominator tree.");
|
||||||
|
Nodes.erase(BB);
|
||||||
|
}
|
||||||
|
|
||||||
/// print - Convert to human readable form
|
/// print - Convert to human readable form
|
||||||
///
|
///
|
||||||
virtual void print(std::ostream &OS, const Module* = 0) const;
|
virtual void print(std::ostream &OS, const Module* = 0) const;
|
||||||
|
Reference in New Issue
Block a user