[PATCH] D44919: [LoopUnroll][NFC] Remove redundant canPeel check
Max Kazantsev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 27 02:45:44 PDT 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rL328615: [LoopUnroll][NFC] Remove redundant canPeel check (authored by mkazantsev, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D44919?vs=139891&id=139896#toc
Repository:
rL LLVM
https://reviews.llvm.org/D44919
Files:
llvm/trunk/lib/Transforms/Utils/LoopUnrollPeel.cpp
Index: llvm/trunk/lib/Transforms/Utils/LoopUnrollPeel.cpp
===================================================================
--- llvm/trunk/lib/Transforms/Utils/LoopUnrollPeel.cpp
+++ llvm/trunk/lib/Transforms/Utils/LoopUnrollPeel.cpp
@@ -473,8 +473,8 @@
bool llvm::peelLoop(Loop *L, unsigned PeelCount, LoopInfo *LI,
ScalarEvolution *SE, DominatorTree *DT,
AssumptionCache *AC, bool PreserveLCSSA) {
- if (!canPeel(L))
- return false;
+ assert(PeelCount > 0 && "Attempt to peel out zero iterations?");
+ assert(canPeel(L) && "Attempt to peel a loop which is not peelable?");
LoopBlocksDFS LoopBlocks(L);
LoopBlocks.perform(LI);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44919.139896.patch
Type: text/x-patch
Size: 687 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180327/7785b3f3/attachment.bin>
More information about the llvm-commits
mailing list