[LSR] Fold terminating condition not only for eq and ne.
authorMark Goncharov <mark.goncharov@syntacore.com>
Mon, 20 Mar 2023 10:42:24 +0000 (13:42 +0300)
committermga-sc <mark.goncharov@syntacore.com>
Mon, 20 Mar 2023 10:42:27 +0000 (13:42 +0300)
commite4dd7ec39f8f833a7020e9fc0f5bb152de6dc07d
tree8e0fc8f98c80da97aa6e7a1c01f9fb38d5301dff
parentf721fcb6ed0a186b8f146282467dd8420a5a36d0
[LSR] Fold terminating condition not only for eq and ne.

Add opportunity to fold any icmp instruction.
llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
llvm/test/Transforms/LoopStrengthReduce/lsr-term-fold-negative-testcase.ll
llvm/test/Transforms/LoopStrengthReduce/lsr-term-fold.ll