[PATCH] D43795: [New PM][IRCE] port of Inductive Range Check Elimination pass to the new pass manager
Fedor Sergeev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 26 16:19:19 PST 2018
fedor.sergeev created this revision.
fedor.sergeev added reviewers: chandlerc, mkazantsev.
Herald added a subscriber: mehdi_amini.
There are two nontrivial details here:
- Loop structure update interface is quite different with new pass manager, so the code to add new loops was factored out
- BranchProbabilityInfo is not a loop analysis, so it can not be just getResult'ed from within the loop pass. It cant even be queried through getCachedResult as LoopCanonicalization sequence (e.g. LoopSimplify) might invalidate BPI results.
This was solved by adding BPI to LoopStandardAnalysisResults and making it "optional" by querying it first in FunctionToLoopPassAdaptor to see if it was initially added.
All the IRCE tests got their corresponding new-pass-manager variant enabled.
They all use -passes="require<branch-prob>,irce" due to the aforementioned BPI issue.
Repository:
rL LLVM
https://reviews.llvm.org/D43795
Files:
include/llvm/Analysis/LoopAnalysisManager.h
include/llvm/InitializePasses.h
include/llvm/Transforms/Scalar/InductiveRangeCheckElimination.h
include/llvm/Transforms/Scalar/LoopPassManager.h
lib/Passes/PassBuilder.cpp
lib/Passes/PassRegistry.def
lib/Transforms/Scalar/InductiveRangeCheckElimination.cpp
lib/Transforms/Scalar/LoopDistribute.cpp
lib/Transforms/Scalar/LoopLoadElimination.cpp
lib/Transforms/Scalar/Scalar.cpp
lib/Transforms/Vectorize/LoopVectorize.cpp
test/Transforms/IRCE/add-metadata-pre-post-loops.ll
test/Transforms/IRCE/bad-loop-structure.ll
test/Transforms/IRCE/bad_expander.ll
test/Transforms/IRCE/bug-loop-varying-upper-limit.ll
test/Transforms/IRCE/bug-mismatched-types.ll
test/Transforms/IRCE/clamp.ll
test/Transforms/IRCE/conjunctive-checks.ll
test/Transforms/IRCE/correct-loop-info.ll
test/Transforms/IRCE/decrementing-loop.ll
test/Transforms/IRCE/empty_ranges.ll
test/Transforms/IRCE/eq_ne.ll
test/Transforms/IRCE/low-becount.ll
test/Transforms/IRCE/multiple-access-no-preloop.ll
test/Transforms/IRCE/not-likely-taken.ll
test/Transforms/IRCE/only-lower-check.ll
test/Transforms/IRCE/only-upper-check.ll
test/Transforms/IRCE/pre_post_loops.ll
test/Transforms/IRCE/range_intersect_miscompile.ll
test/Transforms/IRCE/ranges_of_different_types.ll
test/Transforms/IRCE/single-access-no-preloop.ll
test/Transforms/IRCE/single-access-with-preloop.ll
test/Transforms/IRCE/skip-profitability-checks.ll
test/Transforms/IRCE/stride_more_than_1.ll
test/Transforms/IRCE/unhandled.ll
test/Transforms/IRCE/unsigned_comparisons_ugt.ll
test/Transforms/IRCE/unsigned_comparisons_ult.ll
test/Transforms/IRCE/with-parent-loops.ll
unittests/Transforms/Scalar/LoopPassManagerTest.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D43795.136006.patch
Type: text/x-patch
Size: 33258 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180227/97b9636e/attachment.bin>
More information about the llvm-commits
mailing list