[ShrinkWrap] Refactor the handling of infinite loop in the analysis.
authorQuentin Colombet <qcolombet@apple.com>
Thu, 17 Sep 2015 23:21:34 +0000 (23:21 +0000)
committerQuentin Colombet <qcolombet@apple.com>
Thu, 17 Sep 2015 23:21:34 +0000 (23:21 +0000)
commitd68bf2b419ed0c761c412bf2a58ed2f3c71ce904
tree962beca634e34e8e4c3b4f4b7bf0f40d71a4d0ae
parent919b448c2e44c6f3923350eb7b02c41786b21704
[ShrinkWrap] Refactor the handling of infinite loop in the analysis.
- Strenghten the logic to be sure we hoist the restore point out of the current
  loop. (The fixes a bug with infinite loop, added as part of the patch.)
- Walk over the exit blocks of the current loop to conver to the desired restore
  point in one iteration of the update loop.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@247958 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/ShrinkWrap.cpp
test/CodeGen/AArch64/arm64-shrink-wrapping.ll
test/CodeGen/ARM/arm-shrink-wrapping.ll
test/CodeGen/PowerPC/ppc-shrink-wrapping.ll
test/CodeGen/X86/x86-shrink-wrapping.ll