LoopIndexSplit needs to inform the loop pass manager of the instructions it is
authorOwen Anderson <resistor@mac.com>
Tue, 14 Apr 2009 01:04:19 +0000 (01:04 +0000)
committerOwen Anderson <resistor@mac.com>
Tue, 14 Apr 2009 01:04:19 +0000 (01:04 +0000)
deleting, not just the basic block.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@69011 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Scalar/LoopIndexSplit.cpp

index a8cfaaf3b84bac8806642f99b403d43daad55f22..9f5f2cfd39d807082f3e8130ee8071818efd5eed 100644 (file)
@@ -695,6 +695,7 @@ void LoopIndexSplit::removeBlocks(BasicBlock *DeadBB, Loop *LP,
       Instruction *I = BBI;
       ++BBI;
       I->replaceAllUsesWith(UndefValue::get(I->getType()));
+      LPM->deleteSimpleAnalysisValue(I, LP);
       I->eraseFromParent();
     }
     DT->eraseNode(BB);