[PATCH] D33001: [RuntimeUnrolling] Add logic for loops with multiple exit blocks
Anna Thomas via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 9 07:36:35 PDT 2017
anna created this revision.
Runtime unrolling is done for loops with a single exit block and a
single exiting block (and this exiting block should be the latch block).
This patch adds logic to support unrolling in the presence of multiple exit
blocks (which also means multiple exiting blocks), when runtime unrolling
generates epilog blocks. A very similar logic can be applied when generating
prolog blocks as well.
One restriction on the exit blocks (other than the latch exit block)
is they should have no successors. This can alsio be extended in the future.
This patch is essentially an implementation patch. I have not added any
heuristic (in terms of branches added or code size) to decide when
this should be enabled.
https://reviews.llvm.org/D33001
Files:
lib/Transforms/Utils/LoopUnrollRuntime.cpp
test/Transforms/LoopUnroll/runtime-loop-multiple-exits.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D33001.98280.patch
Type: text/x-patch
Size: 11150 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170509/e7426c3b/attachment.bin>
More information about the llvm-commits
mailing list