forked from OSchip/llvm-project
[LoopRotate] Unconditionally get ScalarEvolution.
Summary: LoopRotate is a loop pass and SE should always be available. Reviewers: anemet, asbirlea Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D68573 llvm-svn: 374026
This commit is contained in:
parent
78bfe3ab94
commit
a70c526143
|
@ -96,15 +96,14 @@ public:
|
|||
auto *AC = &getAnalysis<AssumptionCacheTracker>().getAssumptionCache(F);
|
||||
auto *DTWP = getAnalysisIfAvailable<DominatorTreeWrapperPass>();
|
||||
auto *DT = DTWP ? &DTWP->getDomTree() : nullptr;
|
||||
auto *SEWP = getAnalysisIfAvailable<ScalarEvolutionWrapperPass>();
|
||||
auto *SE = SEWP ? &SEWP->getSE() : nullptr;
|
||||
auto &SE = getAnalysis<ScalarEvolutionWrapperPass>().getSE();
|
||||
const SimplifyQuery SQ = getBestSimplifyQuery(*this, F);
|
||||
Optional<MemorySSAUpdater> MSSAU;
|
||||
if (EnableMSSALoopDependency) {
|
||||
MemorySSA *MSSA = &getAnalysis<MemorySSAWrapperPass>().getMSSA();
|
||||
MSSAU = MemorySSAUpdater(MSSA);
|
||||
}
|
||||
return LoopRotation(L, LI, TTI, AC, DT, SE,
|
||||
return LoopRotation(L, LI, TTI, AC, DT, &SE,
|
||||
MSSAU.hasValue() ? MSSAU.getPointer() : nullptr, SQ,
|
||||
false, MaxHeaderSize, false);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue