Revert "[SimpleLoopUnswitch] unswitch selects"
authorBenjamin Kramer <benny.kra@googlemail.com>
Wed, 10 May 2023 13:11:34 +0000 (15:11 +0200)
committerBenjamin Kramer <benny.kra@googlemail.com>
Wed, 10 May 2023 13:12:21 +0000 (15:12 +0200)
commita414db1d8e3173faca024d4532a4c655a1fe02c0
treea35113be1ce7cb1e34cbb704f34f213459df0671
parent004bf170c6cbaa049601bcf92f86a9459aec2dc2
Revert "[SimpleLoopUnswitch] unswitch selects"

This reverts commit 21f226fc4591db6e98faf380137a42067c909582. Crashes on
this test case:

define void @test2() nounwind {
entry:
  br label %bb.nph

bb.nph:                                           ; preds = %entry
  %and.i13521 = and <4 x i1> undef, undef
  br label %for.body

for.body:                                         ; preds = %for.body, %bb.nph
  %or.i = select <4 x i1> %and.i13521, <4 x i32> undef, <4 x i32> undef
  br i1 false, label %for.body, label %for.end

for.end:                                          ; preds = %for.body, %entry
  ret void
}
llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp
llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-freeze.ll
llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-select.ll
llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-trivial-select.ll