5 Commits

Author SHA1 Message Date
Roman Lebedev
d73383c145
Revert "[InstCombine] Fold nested selects"
One of these two changes is exposing (or causing) some more miscompiles.
A reproducer is in progress, so reverting until resolved.

This reverts commit 9ddff66d0c9c3e18d56e6b20aa26a2a8cdfb6d2b.
2022-12-20 18:36:42 +03:00
Roman Lebedev
254b5e7869
[NFC][InstCombine] Move nested-select testcase into proper place, adjust comment 2022-12-17 16:38:24 +03:00
Roman Lebedev
79909c031d
[NFC][InstCombine] fold-nested-selects: fix profitability check
We'd check the cost of the wrong 'cond', after potentially skipping `not`.
2022-12-13 01:03:38 +03:00
Roman Lebedev
9ddff66d0c
[InstCombine] Fold nested selects
https://alive2.llvm.org/ce/z/GjCXkB
https://alive2.llvm.org/ce/z/Guz2tt

Fixes https://github.com/llvm/llvm-project/issues/59393
2022-12-11 01:00:31 +03:00
Roman Lebedev
c94d104413
[NFC][InstCombine] Add tests for nested select folding
https://github.com/llvm/llvm-project/issues/59393
2022-12-11 00:59:33 +03:00