DF = getAnalysisToUpdate<DominanceFrontier>();
DT = getAnalysisToUpdate<DominatorTree>();
currentLoop = L;
+ Function *F = currentLoop->getHeader()->getParent();
bool Changed = false;
do {
assert(currentLoop->isLCSSAForm());
Changed |= processCurrentLoop();
} while(redoLoop);
+ if (Changed) {
+ // FIXME: Reconstruct dom info, because it is not preserved properly.
+ if (DT)
+ DT->runOnFunction(*F);
+ if (DF)
+ DF->runOnFunction(*F);
+ }
return Changed;
}
UnswitchNontrivialCondition(LoopCond, Val, currentLoop);
}
- // FIXME: Reconstruct dom info, because it is not preserved properly.
- if (DT)
- DT->runOnFunction(*F);
- if (DF)
- DF->runOnFunction(*F);
return true;
}