diff options
Diffstat (limited to 'polly/lib')
-rw-r--r-- | polly/lib/Analysis/ScopDetection.cpp | 6 | ||||
-rw-r--r-- | polly/lib/Analysis/ScopInfo.cpp | 6 | ||||
-rw-r--r-- | polly/lib/Analysis/TempScopInfo.cpp | 6 | ||||
-rw-r--r-- | polly/lib/CodeGen/CodeGeneration.cpp | 8 | ||||
-rw-r--r-- | polly/lib/Transform/IndependentBlocks.cpp | 8 |
5 files changed, 25 insertions, 9 deletions
diff --git a/polly/lib/Analysis/ScopDetection.cpp b/polly/lib/Analysis/ScopDetection.cpp index 34e19648a0b..6cc8f6a1a74 100644 --- a/polly/lib/Analysis/ScopDetection.cpp +++ b/polly/lib/Analysis/ScopDetection.cpp @@ -1064,7 +1064,7 @@ bool ScopDetection::runOnFunction(llvm::Function &F) { if (!DetectUnprofitable && LI->empty()) return false; - AA = &getAnalysis<AliasAnalysis>(); + AA = &getAnalysis<AAResultsWrapperPass>().getAAResults(); SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE(); Region *TopRegion = RI->getTopLevelRegion(); @@ -1129,7 +1129,7 @@ void ScopDetection::getAnalysisUsage(AnalysisUsage &AU) const { AU.addRequired<LoopInfoWrapperPass>(); AU.addRequired<ScalarEvolutionWrapperPass>(); // We also need AA and RegionInfo when we are verifying analysis. - AU.addRequiredTransitive<AliasAnalysis>(); + AU.addRequiredTransitive<AAResultsWrapperPass>(); AU.addRequiredTransitive<RegionInfoPass>(); AU.setPreservesAll(); } @@ -1157,7 +1157,7 @@ Pass *polly::createScopDetectionPass() { return new ScopDetection(); } INITIALIZE_PASS_BEGIN(ScopDetection, "polly-detect", "Polly - Detect static control parts (SCoPs)", false, false); -INITIALIZE_AG_DEPENDENCY(AliasAnalysis); +INITIALIZE_PASS_DEPENDENCY(AAResultsWrapperPass); INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass); INITIALIZE_PASS_DEPENDENCY(RegionInfoPass); INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass); diff --git a/polly/lib/Analysis/ScopInfo.cpp b/polly/lib/Analysis/ScopInfo.cpp index acb44c91326..be2e2977e22 100644 --- a/polly/lib/Analysis/ScopInfo.cpp +++ b/polly/lib/Analysis/ScopInfo.cpp @@ -2354,13 +2354,13 @@ void ScopInfo::getAnalysisUsage(AnalysisUsage &AU) const { AU.addRequired<ScalarEvolutionWrapperPass>(); AU.addRequired<ScopDetection>(); AU.addRequired<TempScopInfo>(); - AU.addRequired<AliasAnalysis>(); + AU.addRequired<AAResultsWrapperPass>(); AU.setPreservesAll(); } bool ScopInfo::runOnRegion(Region *R, RGPassManager &RGM) { LoopInfo &LI = getAnalysis<LoopInfoWrapperPass>().getLoopInfo(); - AliasAnalysis &AA = getAnalysis<AliasAnalysis>(); + AliasAnalysis &AA = getAnalysis<AAResultsWrapperPass>().getAAResults(); ScopDetection &SD = getAnalysis<ScopDetection>(); ScalarEvolution &SE = getAnalysis<ScalarEvolutionWrapperPass>().getSE(); DominatorTree &DT = getAnalysis<DominatorTreeWrapperPass>().getDomTree(); @@ -2397,7 +2397,7 @@ Pass *polly::createScopInfoPass() { return new ScopInfo(); } INITIALIZE_PASS_BEGIN(ScopInfo, "polly-scops", "Polly - Create polyhedral description of Scops", false, false); -INITIALIZE_AG_DEPENDENCY(AliasAnalysis); +INITIALIZE_PASS_DEPENDENCY(AAResultsWrapperPass); INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass); INITIALIZE_PASS_DEPENDENCY(RegionInfoPass); INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass); diff --git a/polly/lib/Analysis/TempScopInfo.cpp b/polly/lib/Analysis/TempScopInfo.cpp index 0467b6c97f8..c3afa017723 100644 --- a/polly/lib/Analysis/TempScopInfo.cpp +++ b/polly/lib/Analysis/TempScopInfo.cpp @@ -385,7 +385,7 @@ bool TempScopInfo::runOnRegion(Region *R, RGPassManager &RGM) { Function *F = R->getEntry()->getParent(); SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE(); LI = &getAnalysis<LoopInfoWrapperPass>().getLoopInfo(); - AA = &getAnalysis<AliasAnalysis>(); + AA = &getAnalysis<AAResultsWrapperPass>().getAAResults(); TD = &F->getParent()->getDataLayout(); ZeroOffset = SE->getConstant(TD->getIntPtrType(F->getContext()), 0); @@ -400,7 +400,7 @@ void TempScopInfo::getAnalysisUsage(AnalysisUsage &AU) const { AU.addRequiredTransitive<ScalarEvolutionWrapperPass>(); AU.addRequiredTransitive<ScopDetection>(); AU.addRequiredID(IndependentBlocksID); - AU.addRequired<AliasAnalysis>(); + AU.addRequired<AAResultsWrapperPass>(); AU.setPreservesAll(); } @@ -422,7 +422,7 @@ Pass *polly::createTempScopInfoPass() { return new TempScopInfo(); } INITIALIZE_PASS_BEGIN(TempScopInfo, "polly-analyze-ir", "Polly - Analyse the LLVM-IR in the detected regions", false, false); -INITIALIZE_AG_DEPENDENCY(AliasAnalysis); +INITIALIZE_PASS_DEPENDENCY(AAResultsWrapperPass); INITIALIZE_PASS_DEPENDENCY(LoopInfoWrapperPass); INITIALIZE_PASS_DEPENDENCY(RegionInfoPass); INITIALIZE_PASS_DEPENDENCY(ScalarEvolutionWrapperPass); diff --git a/polly/lib/CodeGen/CodeGeneration.cpp b/polly/lib/CodeGen/CodeGeneration.cpp index 0be2eab3870..b8e40087226 100644 --- a/polly/lib/CodeGen/CodeGeneration.cpp +++ b/polly/lib/CodeGen/CodeGeneration.cpp @@ -30,7 +30,11 @@ #include "llvm/IR/Module.h" #include "llvm/IR/Verifier.h" #include "llvm/Support/Debug.h" +#include "llvm/Analysis/AliasAnalysis.h" +#include "llvm/Analysis/BasicAliasAnalysis.h" +#include "llvm/Analysis/GlobalsModRef.h" #include "llvm/Analysis/PostDominators.h" +#include "llvm/Analysis/ScalarEvolutionAliasAnalysis.h" using namespace polly; using namespace llvm; @@ -169,12 +173,16 @@ public: AU.addPreserved<DependenceInfo>(); + AU.addPreserved<AAResultsWrapperPass>(); + AU.addPreserved<BasicAAWrapperPass>(); AU.addPreserved<LoopInfoWrapperPass>(); AU.addPreserved<DominatorTreeWrapperPass>(); + AU.addPreserved<GlobalsAAWrapperPass>(); AU.addPreserved<PostDominatorTree>(); AU.addPreserved<IslAstInfo>(); AU.addPreserved<ScopDetection>(); AU.addPreserved<ScalarEvolutionWrapperPass>(); + AU.addPreserved<SCEVAAWrapperPass>(); // FIXME: We do not yet add regions for the newly generated code to the // region tree. diff --git a/polly/lib/Transform/IndependentBlocks.cpp b/polly/lib/Transform/IndependentBlocks.cpp index 779f87c40c8..4908b8a875d 100644 --- a/polly/lib/Transform/IndependentBlocks.cpp +++ b/polly/lib/Transform/IndependentBlocks.cpp @@ -16,10 +16,14 @@ #include "polly/Options.h" #include "polly/ScopDetection.h" #include "polly/Support/ScopHelper.h" +#include "llvm/Analysis/AliasAnalysis.h" +#include "llvm/Analysis/BasicAliasAnalysis.h" #include "llvm/Analysis/DominanceFrontier.h" +#include "llvm/Analysis/GlobalsModRef.h" #include "llvm/Analysis/LoopInfo.h" #include "llvm/Analysis/PostDominators.h" #include "llvm/Analysis/RegionInfo.h" +#include "llvm/Analysis/ScalarEvolutionAliasAnalysis.h" #include "llvm/Analysis/ValueTracking.h" #include "llvm/IR/IntrinsicInst.h" #include "llvm/Support/CommandLine.h" @@ -309,8 +313,11 @@ bool IndependentBlocks::areAllBlocksIndependent(const Region *R) const { void IndependentBlocks::getAnalysisUsage(AnalysisUsage &AU) const { // FIXME: If we set preserves cfg, the cfg only passes do not need to // be "addPreserved"? + AU.addPreserved<AAResultsWrapperPass>(); + AU.addPreserved<BasicAAWrapperPass>(); AU.addPreserved<DominatorTreeWrapperPass>(); AU.addPreserved<DominanceFrontier>(); + AU.addPreserved<GlobalsAAWrapperPass>(); AU.addPreserved<PostDominatorTree>(); AU.addRequired<RegionInfoPass>(); AU.addPreserved<RegionInfoPass>(); @@ -318,6 +325,7 @@ void IndependentBlocks::getAnalysisUsage(AnalysisUsage &AU) const { AU.addPreserved<LoopInfoWrapperPass>(); AU.addRequired<ScalarEvolutionWrapperPass>(); AU.addPreserved<ScalarEvolutionWrapperPass>(); + AU.addPreserved<SCEVAAWrapperPass>(); AU.addRequired<ScopDetection>(); AU.addPreserved<ScopDetection>(); } |