[llvm-commits] [polly] r144281 - /polly/trunk/lib/RegisterPasses.cpp
Tobias Grosser
grosser at fim.uni-passau.de
Thu Nov 10 04:45:07 PST 2011
Author: grosser
Date: Thu Nov 10 06:45:07 2011
New Revision: 144281
URL: http://llvm.org/viewvc/llvm-project?rev=144281&view=rev
Log:
Add a workaround to fix SCoPs rejected because of 'region not simple'
Modified:
polly/trunk/lib/RegisterPasses.cpp
Modified: polly/trunk/lib/RegisterPasses.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/RegisterPasses.cpp?rev=144281&r1=144280&r2=144281&view=diff
==============================================================================
--- polly/trunk/lib/RegisterPasses.cpp (original)
+++ polly/trunk/lib/RegisterPasses.cpp Thu Nov 10 06:45:07 2011
@@ -114,10 +114,19 @@
PM.add(polly::createCodePreparationPass());
PM.add(polly::createRegionSimplifyPass());
- // FIXME: Needed as RegionSimplifyPass destroys the canonical form of
- // induction variables (It changes the order of the operands in the
- // PHI nodes).
+ // FIXME: The next two passes should not be necessary here. They are currently
+ // because of two problems:
+ //
+ // 1. The RegionSimplifyPass destroys the canonical form of induction
+ // variables,as it produces PHI nodes with incorrectly ordered
+ // operands. To fix this we run IndVarSimplify.
+ //
+ // 2. IndVarSimplify does not preserve the region information and
+ // the regioninfo pass does currently not recover simple regions.
+ // As a result we need to run the RegionSimplify pass again to
+ // recover them
PM.add(llvm::createIndVarSimplifyPass());
+ PM.add(polly::createRegionSimplifyPass());
if (PollyViewer)
PM.add(polly::createDOTViewerPass());
More information about the llvm-commits
mailing list