OSDN Git Service

[LoopUnroll] Don't peel loops where the latch isn't the exiting block
authorMichael Kuperstein <mkuper@google.com>
Thu, 16 Mar 2017 21:07:48 +0000 (21:07 +0000)
committerMichael Kuperstein <mkuper@google.com>
Thu, 16 Mar 2017 21:07:48 +0000 (21:07 +0000)
commit2360eb02ec6d6f4d4f7b994687b105067850c2b0
tree32944522de4651b941fdc547da9a83847c691bd4
parent78dce2577dfbc9d790a310b4d7e24b195a44a552
[LoopUnroll] Don't peel loops where the latch isn't the exiting block

Peeling assumed this doesn't happen, but didn't check it.
This fixes PR32178.

Differential Revision: https://reviews.llvm.org/D30757

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@297993 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Utils/LoopUnrollPeel.cpp
test/Transforms/LoopUnroll/peel-loop-irreducible.ll [new file with mode: 0644]