[InstCombine] Simplify foldOperationIntoSelectOperand() (NFCI)
authorNikita Popov <npopov@redhat.com>
Tue, 21 Mar 2023 08:59:52 +0000 (09:59 +0100)
committerNikita Popov <npopov@redhat.com>
Tue, 21 Mar 2023 09:02:29 +0000 (10:02 +0100)
commitd0de2c51c9a9fc0fedb97ee98f61ce08cb34972b
tree1905232ccab3f02341dac3293e809765bc90b43a
parent9f48562ebfe1486f9094459d1aadde25268d7ce4
[InstCombine] Simplify foldOperationIntoSelectOperand() (NFCI)

Rather than handling all instruction types separately, clone the
original instruction and replace the select operand.
llvm/lib/Transforms/InstCombine/InstructionCombining.cpp