[InstCombine] add pattern matches for commuted variants of xor-to-xor
authorSanjay Patel <spatel@rotateright.com>
Sun, 23 Apr 2017 16:03:00 +0000 (16:03 +0000)
committerSanjay Patel <spatel@rotateright.com>
Sun, 23 Apr 2017 16:03:00 +0000 (16:03 +0000)
commitd13b0bfdacb84b1653245fa1d0ac66819b84cd62
tree55c1acf9b6d6ab43bd068a4b661d1a59ddc96c41
parent90818085218f23c8e2cdcc1aa68e66fb6ae7e07c
[InstCombine] add pattern matches for commuted variants of xor-to-xor

There's probably some better way to write this that eliminates the
code duplication without hurting readability, but at least this
eliminates the logic holes and is hopefully slightly more efficient
than creating new instructions.

llvm-svn: 301129
llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
llvm/test/Transforms/InstCombine/and-or-not.ll