Fix Polly after SCEV port to new pass manager

This fixes compilation after LLVM commit r245193.

llvm-svn: 245211
This commit is contained in:
Tobias Grosser 2015-08-17 10:57:08 +00:00
parent 607b8b26e9
commit c5bcf246d1
6 changed files with 19 additions and 19 deletions

View File

@ -1030,7 +1030,7 @@ bool ScopDetection::runOnFunction(llvm::Function &F) {
return false;
AA = &getAnalysis<AliasAnalysis>();
SE = &getAnalysis<ScalarEvolution>();
SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
Region *TopRegion = RI->getTopLevelRegion();
releaseMemory();
@ -1092,7 +1092,7 @@ void polly::ScopDetection::verifyAnalysis() const {
void ScopDetection::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<LoopInfoWrapperPass>();
AU.addRequired<ScalarEvolution>();
AU.addRequired<ScalarEvolutionWrapperPass>();
// We also need AA and RegionInfo when we are verifying analysis.
AU.addRequiredTransitive<AliasAnalysis>();
AU.addRequiredTransitive<RegionInfoPass>();
@ -1125,6 +1125,6 @@ INITIALIZE_PASS_BEGIN(ScopDetection, "polly-detect",
INITIALIZE_AG_DEPENDENCY(AliasAnalysis);
INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass);
INITIALIZE_PASS_DEPENDENCY(RegionInfoPass);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolution);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass);
INITIALIZE_PASS_END(ScopDetection, "polly-detect",
"Polly - Detect static control parts (SCoPs)", false, false)

View File

@ -2007,7 +2007,7 @@ ScopInfo::~ScopInfo() {
void ScopInfo::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<LoopInfoWrapperPass>();
AU.addRequired<RegionInfoPass>();
AU.addRequired<ScalarEvolution>();
AU.addRequired<ScalarEvolutionWrapperPass>();
AU.addRequired<ScopDetection>();
AU.addRequired<TempScopInfo>();
AU.addRequired<AliasAnalysis>();
@ -2018,7 +2018,7 @@ bool ScopInfo::runOnRegion(Region *R, RGPassManager &RGM) {
LoopInfo &LI = getAnalysis<LoopInfoWrapperPass>().getLoopInfo();
AliasAnalysis &AA = getAnalysis<AliasAnalysis>();
ScopDetection &SD = getAnalysis<ScopDetection>();
ScalarEvolution &SE = getAnalysis<ScalarEvolution>();
ScalarEvolution &SE = getAnalysis<ScalarEvolutionWrapperPass>().getSE();
TempScop *tempScop = getAnalysis<TempScopInfo>().getTempScop();
@ -2073,7 +2073,7 @@ INITIALIZE_PASS_BEGIN(ScopInfo, "polly-scops",
INITIALIZE_AG_DEPENDENCY(AliasAnalysis);
INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass);
INITIALIZE_PASS_DEPENDENCY(RegionInfoPass);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolution);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass);
INITIALIZE_PASS_DEPENDENCY(ScopDetection);
INITIALIZE_PASS_DEPENDENCY(TempScopInfo);
INITIALIZE_PASS_END(ScopInfo, "polly-scops",

View File

@ -476,7 +476,7 @@ bool TempScopInfo::runOnRegion(Region *R, RGPassManager &RGM) {
Function *F = R->getEntry()->getParent();
DT = &getAnalysis<DominatorTreeWrapperPass>().getDomTree();
PDT = &getAnalysis<PostDominatorTree>();
SE = &getAnalysis<ScalarEvolution>();
SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
LI = &getAnalysis<LoopInfoWrapperPass>().getLoopInfo();
AA = &getAnalysis<AliasAnalysis>();
TD = &F->getParent()->getDataLayout();
@ -492,7 +492,7 @@ void TempScopInfo::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequiredTransitive<DominatorTreeWrapperPass>();
AU.addRequiredTransitive<PostDominatorTree>();
AU.addRequiredTransitive<LoopInfoWrapperPass>();
AU.addRequiredTransitive<ScalarEvolution>();
AU.addRequiredTransitive<ScalarEvolutionWrapperPass>();
AU.addRequiredTransitive<ScopDetection>();
AU.addRequiredID(IndependentBlocksID);
AU.addRequired<AliasAnalysis>();
@ -523,7 +523,7 @@ INITIALIZE_PASS_DEPENDENCY(DominatorTreeWrapperPass);
INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass);
INITIALIZE_PASS_DEPENDENCY(PostDominatorTree);
INITIALIZE_PASS_DEPENDENCY(RegionInfoPass);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolution);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass);
INITIALIZE_PASS_END(TempScopInfo, "polly-analyze-ir",
"Polly - Analyse the LLVM-IR in the detected regions",
false, false)

View File

@ -115,7 +115,7 @@ public:
LI = &getAnalysis<LoopInfoWrapperPass>().getLoopInfo();
DT = &getAnalysis<DominatorTreeWrapperPass>().getDomTree();
SE = &getAnalysis<ScalarEvolution>();
SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
DL = &S.getRegion().getEntry()->getParent()->getParent()->getDataLayout();
RI = &getAnalysis<RegionInfoPass>().getRegionInfo();
Region *R = &S.getRegion();
@ -162,7 +162,7 @@ public:
AU.addRequired<DominatorTreeWrapperPass>();
AU.addRequired<IslAstInfo>();
AU.addRequired<RegionInfoPass>();
AU.addRequired<ScalarEvolution>();
AU.addRequired<ScalarEvolutionWrapperPass>();
AU.addRequired<ScopDetection>();
AU.addRequired<ScopInfo>();
AU.addRequired<LoopInfoWrapperPass>();
@ -174,7 +174,7 @@ public:
AU.addPreserved<PostDominatorTree>();
AU.addPreserved<IslAstInfo>();
AU.addPreserved<ScopDetection>();
AU.addPreserved<ScalarEvolution>();
AU.addPreserved<ScalarEvolutionWrapperPass>();
// FIXME: We do not yet add regions for the newly generated code to the
// region tree.
@ -196,7 +196,7 @@ INITIALIZE_PASS_DEPENDENCY(DependenceInfo);
INITIALIZE_PASS_DEPENDENCY(DominatorTreeWrapperPass);
INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass);
INITIALIZE_PASS_DEPENDENCY(RegionInfoPass);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolution);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass);
INITIALIZE_PASS_DEPENDENCY(ScopDetection);
INITIALIZE_PASS_END(CodeGeneration, "polly-codegen",
"Polly - Create LLVM-IR from SCoPs", false, false)

View File

@ -66,7 +66,7 @@ CodePreparation::~CodePreparation() { clear(); }
void CodePreparation::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<LoopInfoWrapperPass>();
AU.addRequired<ScalarEvolution>();
AU.addRequired<ScalarEvolutionWrapperPass>();
AU.addPreserved<LoopInfoWrapperPass>();
AU.addPreserved<RegionInfoPass>();
@ -76,7 +76,7 @@ void CodePreparation::getAnalysisUsage(AnalysisUsage &AU) const {
bool CodePreparation::runOnFunction(Function &F) {
LI = &getAnalysis<LoopInfoWrapperPass>().getLoopInfo();
SE = &getAnalysis<ScalarEvolution>();
SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
splitEntryBlockForAlloca(&F.getEntryBlock(), this);

View File

@ -477,8 +477,8 @@ void IndependentBlocks::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addPreserved<RegionInfoPass>();
AU.addRequired<LoopInfoWrapperPass>();
AU.addPreserved<LoopInfoWrapperPass>();
AU.addRequired<ScalarEvolution>();
AU.addPreserved<ScalarEvolution>();
AU.addRequired<ScalarEvolutionWrapperPass>();
AU.addPreserved<ScalarEvolutionWrapperPass>();
AU.addRequired<ScopDetection>();
AU.addPreserved<ScopDetection>();
}
@ -490,7 +490,7 @@ bool IndependentBlocks::runOnFunction(llvm::Function &F) {
RI = &getAnalysis<RegionInfoPass>().getRegionInfo();
LI = &getAnalysis<LoopInfoWrapperPass>().getLoopInfo();
SD = &getAnalysis<ScopDetection>();
SE = &getAnalysis<ScalarEvolution>();
SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
AllocaBlock = &F.getEntryBlock();
@ -521,7 +521,7 @@ INITIALIZE_PASS_BEGIN(IndependentBlocks, "polly-independent",
"Polly - Create independent blocks", false, false);
INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass);
INITIALIZE_PASS_DEPENDENCY(RegionInfoPass);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolution);
INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass);
INITIALIZE_PASS_DEPENDENCY(ScopDetection);
INITIALIZE_PASS_END(IndependentBlocks, "polly-independent",
"Polly - Create independent blocks", false, false)