[PATCH] D136109: llvm-reduce: Add conditional reduction passes
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 17 13:46:28 PDT 2022
arsenm created this revision.
arsenm added reviewers: aeubanks, regehr, lebedev.ri.
Herald added a project: All.
arsenm requested review of this revision.
Herald added a subscriber: wdng.
Herald added a project: LLVM.
Copy this technique from bugpoint. Before trying to blindly
delete blocks, try to fold branch conditions. This intuitively
makes more sense for a faster reduction, since you can find
dead paths in the function to prune out before trying to bisect
blocks in source order.
Seems to provide some speedup on my multi-hour reduction samples.
This does have the potential to produce testcases with unreachable
blocks. This is already a problem with the existing block
reduction pass. I'm struggling dealing with invalid reductions
in these cases, so in the future this should probably start
deleting those. However, I do sometimes try to reduce failures
in code that becomes unreachable, so I'm not totally sure
what to do here.
https://reviews.llvm.org/D136109
Files:
llvm/test/tools/llvm-reduce/reduce-conditionals.ll
llvm/tools/llvm-reduce/DeltaManager.cpp
llvm/tools/llvm-reduce/deltas/ReduceUsingSimplifyCFG.cpp
llvm/tools/llvm-reduce/deltas/ReduceUsingSimplifyCFG.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D136109.468306.patch
Type: text/x-patch
Size: 4550 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221017/df563df3/attachment.bin>
More information about the llvm-commits
mailing list