[PATCH] D33806: Move GVNHoist to the right position in the new pass manager pipeline
Davide Italiano via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 1 15:17:37 PDT 2017
davide created this revision.
Herald added a reviewer: dberlin.
GVNHoist was moved as part of simplification passes for the current pass manager (but not for the new), so they're now out-of-sync.
https://reviews.llvm.org/D33806
Files:
lib/Passes/PassBuilder.cpp
Index: lib/Passes/PassBuilder.cpp
===================================================================
--- lib/Passes/PassBuilder.cpp
+++ lib/Passes/PassBuilder.cpp
@@ -309,6 +309,10 @@
// Catch trivial redundancies
FPM.addPass(EarlyCSEPass());
+ // Hoisting of scalars and load expressions.
+ if (EnableGVNHoist)
+ FPM.addPass(GVNHoistPass());
+
// Speculative execution if the target has divergent branches; otherwise nop.
FPM.addPass(SpeculativeExecutionPass());
@@ -473,8 +477,6 @@
EarlyFPM.addPass(SROA());
EarlyFPM.addPass(EarlyCSEPass());
EarlyFPM.addPass(LowerExpectIntrinsicPass());
- if (EnableGVNHoist)
- EarlyFPM.addPass(GVNHoistPass());
MPM.addPass(createModuleToFunctionPassAdaptor(std::move(EarlyFPM)));
// Interprocedural constant propagation now that basic cleanup has occured
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D33806.101123.patch
Type: text/x-patch
Size: 835 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170601/49e17a45/attachment.bin>
More information about the llvm-commits
mailing list