1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-02-01 05:01:59 +01:00

Implement method

llvm-svn: 13036
This commit is contained in:
Chris Lattner 2004-04-18 06:54:48 +00:00
parent b17c6d4732
commit 08232425a0

View File

@ -326,6 +326,18 @@ Loop *LoopInfo::removeLoop(iterator I) {
return L;
}
/// removeBlock - This method completely removes BB from all data structures,
/// including all of the Loop objects it is nested in and our mapping from
/// BasicBlocks to loops.
void LoopInfo::removeBlock(BasicBlock *BB) {
std::map<BasicBlock *, Loop*>::iterator I = BBMap.find(BB);
if (I != BBMap.end()) {
for (Loop *L = I->second; L; L = L->getParentLoop())
L->removeBlockFromLoop(BB);
BBMap.erase(I);
}
}
//===----------------------------------------------------------------------===//