Revert "[SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions"
authorRoman Lebedev <lebedev.ri@gmail.com>
Thu, 26 Nov 2020 20:11:26 +0000 (23:11 +0300)
committerRoman Lebedev <lebedev.ri@gmail.com>
Thu, 26 Nov 2020 20:13:43 +0000 (23:13 +0300)
commitf3abd54958ab90ba7c100d3fa936a3ce0dd2ad04
tree58f67bfe52e91244195ee88bbf893138506dd217
parent1de56d6d13c083c996dfd44a32041dacae037d66
Revert "[SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions"

Many bots are unhappy, at the very least missed a few codegen tests,
and possibly this has a logic hole inducing a miscompile
(will be really awesome to have ready reproducer..)

Need to investigate.

This reverts commit 2245fb8aaa1c1f85f53f7b19a1ee3ac69b1a1dfe.
llvm/lib/Transforms/Utils/SimplifyCFG.cpp
llvm/test/Transforms/LoopUnroll/peel-loop-inner.ll
llvm/test/Transforms/SimplifyCFG/fold-branch-to-common-dest.ll