OSDN Git Service

[LoopInterchange] Preserve LoopInfo after interchanging.
authorFlorian Hahn <florian.hahn@arm.com>
Thu, 5 Apr 2018 09:48:45 +0000 (09:48 +0000)
committerFlorian Hahn <florian.hahn@arm.com>
Thu, 5 Apr 2018 09:48:45 +0000 (09:48 +0000)
commit49d9dfff54d21f3022d06fec5ea9d8358eaaf567
tree0e35bcd861e9547df3a869d944ca797ddd162f61
parent8caab7da3f83c8971890fa7fa1a838013f9669f1
[LoopInterchange] Preserve LoopInfo after interchanging.

LoopInterchange relies on LoopInfo being up-to-date, so we should
preserve it after interchanging. This patch updates restructureLoops to
move the BBs of the interchanged loops to the right place.

Reviewers: davide, efriedma, karthikthecool, mcrosier

Reviewed By: efriedma

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@329264 91177308-0d34-0410-b5e6-96231b3b80d8
14 files changed:
lib/Transforms/Scalar/LoopInterchange.cpp
test/Transforms/LoopInterchange/call-instructions.ll
test/Transforms/LoopInterchange/currentLimitation.ll
test/Transforms/LoopInterchange/interchange-flow-dep-outer.ll
test/Transforms/LoopInterchange/interchange-insts-between-indvar.ll
test/Transforms/LoopInterchange/interchange-no-deps.ll
test/Transforms/LoopInterchange/interchangeable.ll
test/Transforms/LoopInterchange/loop-interchange-optimization-remarks.ll
test/Transforms/LoopInterchange/not-interchanged-dependencies-1.ll
test/Transforms/LoopInterchange/not-interchanged-loop-nest-3.ll
test/Transforms/LoopInterchange/not-interchanged-tightly-nested.ll
test/Transforms/LoopInterchange/phi-ordering.ll
test/Transforms/LoopInterchange/profitability.ll
test/Transforms/LoopInterchange/reductions.ll