[PATCH] [Polly][Fix] Dead memory accesses should not confuse RTC generation

Andreas Simbuerger simbuerg at fim.uni-passau.de
Mon Oct 6 05:28:21 PDT 2014


================
Comment at: lib/Analysis/ScopInfo.cpp:1278
@@ +1277,3 @@
+      // Skip accesses with an empty domain as they will never be executed.
+      isl_set *MADomain = MA->getStatement()->getDomain();
+      bool MADomainEmpty = isl_set_is_empty(MADomain);
----------------
You are iterating over all memory accesses of one statement, so I assume MA->getStatement() is always equal to Stmt, right?
With that in mind, you can do the empty check outside this loop and skip the whole loop, if true.

http://reviews.llvm.org/D5623






More information about the llvm-commits mailing list