diff options
author | Craig Topper <craig.topper@intel.com> | 2017-07-02 01:15:51 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@intel.com> | 2017-07-02 01:15:51 +0000 |
commit | f60ab47098c4768014ac4b761a6df41cb0cc0d5e (patch) | |
tree | dc46dfe4f3fb5897153abf2e13f5b738797d2ce9 /llvm/lib/Target/X86/X86MCInstLower.cpp | |
parent | e3f7dda1fb57e8810e4757dea0fed3917666ef24 (diff) | |
download | bcm5719-llvm-f60ab47098c4768014ac4b761a6df41cb0cc0d5e.tar.gz bcm5719-llvm-f60ab47098c4768014ac4b761a6df41cb0cc0d5e.zip |
[InstCombine] Fold (a | b) ^ (~a | ~b) --> ~(a ^ b) and (a & b) ^ (~a & ~b) --> ~(a ^ b)
Summary:
I came across this while thinking about what would happen if one of the operands in this xor pattern was itself a inverted (A & ~B) ^ (~A & B)-> (A^B).
The patterns here assume that the (~a | ~b) will be demorganed to ~(a & b) first. Though I wonder if there's a multiple use case that would prevent the demorgan.
Reviewers: spatel
Reviewed By: spatel
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D34870
llvm-svn: 306967
Diffstat (limited to 'llvm/lib/Target/X86/X86MCInstLower.cpp')
0 files changed, 0 insertions, 0 deletions