[PATCH] D17477: [Polly] [RFC] Allow the client of DependenceInfo to obtain dependences at different granularities.

Hongbin Zheng via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 1 17:19:11 PST 2016


etherzhhb added inline comments.

================
Comment at: lib/Analysis/DependenceInfo.cpp:793-794
@@ -772,3 +792,4 @@
 void DependenceInfo::getAnalysisUsage(AnalysisUsage &AU) const {
-  ScopPass::getAnalysisUsage(AU);
+  AU.addRequiredTransitive<ScopInfo>();
+  AU.setPreservesAll();
 }
----------------
Meinersbur wrote:
> Apart from `recomputeDependences()` the DependenceInfo did not need the Scop anymore. All results were stored in isl_* structures.
> 
> However, the analysis results without having the ScopStmt, MemoryAccess they were computed from available might be not that useful, but it is not strictly necessary. So I guess, no problem with always using `addRequiredTransitive<ScopInfo>()`. Users of DependenceInfo will have a `addRequired[Transitive]<ScopInfo>()` anyway.
> Apart from recomputeDependences() the DependenceInfo did not need the Scop anymore. All results were stored in isl_* structures.

> However, the analysis results without having the ScopStmt, MemoryAccess they were computed from available might be not that useful, but it is not strictly necessary. So I guess, no problem with always using addRequiredTransitive<ScopInfo>(). Users of DependenceInfo will have a addRequired[Transitive]<ScopInfo>() anyway.

One of the examples about using DependencesInfo without ScopStmt, MemoryAccess  is an analysis pass for memory dependencies between llvm instructions based on the access-level dependences, the end users of such a pass is interested in Scop, but llvm instructions.


http://reviews.llvm.org/D17477





More information about the llvm-commits mailing list