[llvm] [InstCombine] Simplify a complex OR to XOR (PR #75129)

Fujun Han via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 13 00:42:54 PST 2023


Peter9606 wrote:

> I think (and (add x, 32), 48) can be replaced with (and (xor x, 32), 48). Is that optimization alone enough to trigger the rest?

@topperc  If I understand correctlly, your suggestion can be formalized as https://alive2.llvm.org/ce/z/aoJPsn, right?

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


More information about the llvm-commits mailing list