[llvm] [InstCombine] Canonicalize `switch(X^C)` expressions to `switch(X)` (PR #143677)

Antonio Frighetto via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 13 01:52:22 PDT 2025


antoniofrighetto wrote:

> Do we need to check whether the condition is only used by the switch? Absorbing constants into switch cases may not be profitable if the condition is also used in other places...

Sounds reasonable to me.

https://github.com/llvm/llvm-project/pull/143677


More information about the llvm-commits mailing list