forked from OSchip/llvm-project
parent
741f8d666f
commit
73e53f510a
|
@ -1967,8 +1967,11 @@ bool IndVarSimplify::runOnLoop(Loop *L, LPPassManager &LPM) {
|
||||||
// loop exit test instruction.
|
// loop exit test instruction.
|
||||||
if (IU && NewICmp) {
|
if (IU && NewICmp) {
|
||||||
ICmpInst *NewICmpInst = dyn_cast<ICmpInst>(NewICmp);
|
ICmpInst *NewICmpInst = dyn_cast<ICmpInst>(NewICmp);
|
||||||
if (NewICmpInst)
|
if (NewICmpInst) {
|
||||||
IU->AddUsersIfInteresting(cast<Instruction>(NewICmpInst->getOperand(0)));
|
SmallPtrSet<Loop*,16> SimpleLoopNests;
|
||||||
|
IU->AddUsersIfInteresting(cast<Instruction>(NewICmpInst->getOperand(0)),
|
||||||
|
SimpleLoopNests);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// Clean up dead instructions.
|
// Clean up dead instructions.
|
||||||
Changed |= DeleteDeadPHIs(L->getHeader());
|
Changed |= DeleteDeadPHIs(L->getHeader());
|
||||||
|
|
Loading…
Reference in New Issue