[InstSimplify] !(X && Y) || X --> true (for poison-safe logical ops)
authorSanjay Patel <spatel@rotateright.com>
Sun, 29 Jan 2023 15:24:52 +0000 (10:24 -0500)
committerSanjay Patel <spatel@rotateright.com>
Sun, 29 Jan 2023 15:24:52 +0000 (10:24 -0500)
commit20167e8483159536c13b2cda763047cbd6d7d62c
tree318d5944dc6ca2acc09f1c5af0c1c019911c4808
parent081a4e6712f465540cbf5e5895ffaf2d51777593
[InstSimplify] !(X && Y) || X --> true (for poison-safe logical ops)

https://alive2.llvm.org/ce/z/xuvL46

This is the similar to the existing folds added with:
D138853 / f2973327496fc966c4e89597
7dbeb127eaf6
...but with the and/or swapped.
llvm/lib/Analysis/InstructionSimplify.cpp
llvm/test/Transforms/InstSimplify/select-logical.ll