[polly] r280558 - Dependences: Only create flat StmtSchedule in presence of reductions

Tobias Grosser via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 2 16:40:16 PDT 2016

Author: grosser
Date: Fri Sep  2 18:40:15 2016
New Revision: 280558

URL: http://llvm.org/viewvc/llvm-project?rev=280558&view=rev
Dependences: Only create flat StmtSchedule in presence of reductions

Without reductions we do not need a flat union_map schedule describing
the computation we want to perform, but can work purely on the schedule
tree. This reduces the dependence computation and scheduling time from 33ms
to 25ms. Another 30% reduction.


Modified: polly/trunk/lib/Analysis/DependenceInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Analysis/DependenceInfo.cpp?rev=280558&r1=280557&r2=280558&view=diff
--- polly/trunk/lib/Analysis/DependenceInfo.cpp (original)
+++ polly/trunk/lib/Analysis/DependenceInfo.cpp Fri Sep  2 18:40:15 2016
@@ -173,7 +173,7 @@ static void collectInfo(Scop &S, isl_uni
         *Write = isl_union_map_add_map(*Write, accdom);
-    if (Level == Dependences::AL_Statement)
+    if (!ReductionBaseValues.empty() && Level == Dependences::AL_Statement)
       *StmtSchedule = isl_union_map_add_map(*StmtSchedule, Stmt.getSchedule());

More information about the llvm-commits mailing list