[polly] r276622 - IslNodeBuilder: Make finalize() virtual
Tobias Grosser via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 25 02:15:57 PDT 2016
Author: grosser
Date: Mon Jul 25 04:15:57 2016
New Revision: 276622
URL: http://llvm.org/viewvc/llvm-project?rev=276622&view=rev
Log:
IslNodeBuilder: Make finalize() virtual
This allows the finalization routine of the IslNodeBuilder to be overwritten
by derived classes. Being here, we also drop the unnecessary 'Scop' postfix
and the unnecessary 'Scop' parameter.
Modified:
polly/trunk/include/polly/CodeGen/IslNodeBuilder.h
polly/trunk/lib/CodeGen/CodeGeneration.cpp
polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp
Modified: polly/trunk/include/polly/CodeGen/IslNodeBuilder.h
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/include/polly/CodeGen/IslNodeBuilder.h?rev=276622&r1=276621&r2=276622&view=diff
==============================================================================
--- polly/trunk/include/polly/CodeGen/IslNodeBuilder.h (original)
+++ polly/trunk/include/polly/CodeGen/IslNodeBuilder.h Mon Jul 25 04:15:57 2016
@@ -58,10 +58,10 @@ public:
/// @brief Preload all memory loads that are invariant.
bool preloadInvariantLoads();
- /// @brief Finalize code generation for the SCoP @p S.
+ /// @brief Finalize code generation.
///
/// @see BlockGenerator::finalizeSCoP(Scop &S)
- void finalizeSCoP(Scop &S) { BlockGen.finalizeSCoP(S); }
+ virtual void finalize() { BlockGen.finalizeSCoP(S); }
IslExprBuilder &getExprBuilder() { return ExprBuilder; }
Modified: polly/trunk/lib/CodeGen/CodeGeneration.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/CodeGeneration.cpp?rev=276622&r1=276621&r2=276622&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/CodeGeneration.cpp (original)
+++ polly/trunk/lib/CodeGen/CodeGeneration.cpp Mon Jul 25 04:15:57 2016
@@ -203,8 +203,7 @@ public:
Builder.SetInsertPoint(&StartBlock->front());
NodeBuilder.create(AstRoot);
-
- NodeBuilder.finalizeSCoP(S);
+ NodeBuilder.finalize();
fixRegionInfo(EnteringBB->getParent(), R->getParent());
}
Modified: polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp?rev=276622&r1=276621&r2=276622&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp (original)
+++ polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp Mon Jul 25 04:15:57 2016
@@ -1326,7 +1326,7 @@ public:
NodeBuilder.addParameters(S->getContext());
Builder.SetInsertPoint(&*StartBlock->begin());
NodeBuilder.create(Root);
- NodeBuilder.finalizeSCoP(*S);
+ NodeBuilder.finalize();
}
bool runOnScop(Scop &CurrentScop) override {
More information about the llvm-commits
mailing list