[RDA] Switch isSafeToMove iterators
authorSam Parker <sam.parker@arm.com>
Mon, 28 Sep 2020 14:46:56 +0000 (15:46 +0100)
committerSam Parker <sam.parker@arm.com>
Wed, 30 Sep 2020 07:10:48 +0000 (08:10 +0100)
commit700f93e92b6d4cdbab66133f75c143c9677f2d41
treeb546b90fc7a8dc1e0c893ac39b89bfd5382472a3
parent195c22f2733cf923b932412f0fe212f4ef397d2c
[RDA] Switch isSafeToMove iterators

So forwards is forwards and backwards is reverse. Also add a check
so that we know the instructions are in the expected order.

Differential Revision: https://reviews.llvm.org/D88419
llvm/lib/CodeGen/ReachingDefAnalysis.cpp
llvm/test/CodeGen/Thumb2/LowOverheadLoops/it-block-mov.mir
llvm/test/CodeGen/Thumb2/LowOverheadLoops/lstp-insertion-position.mir
llvm/test/CodeGen/Thumb2/LowOverheadLoops/mov-operand.ll
llvm/test/CodeGen/Thumb2/LowOverheadLoops/move-def-before-start.mir
llvm/test/CodeGen/Thumb2/LowOverheadLoops/move-start-after-def.mir