[X86] Enable 8-bit OR with disjoint bits to convert to LEA
authorCraig Topper <craig.topper@intel.com>
Tue, 5 Mar 2019 18:37:33 +0000 (18:37 +0000)
committerCraig Topper <craig.topper@intel.com>
Tue, 5 Mar 2019 18:37:33 +0000 (18:37 +0000)
commit572e94ca023a292dde836b070763f010273444f9
treeb9eac8768bb2d2a9253f2a70916faaaaa60db6b4
parentbb322e79c16c5a372a1f257327e29feddcb2bc04
[X86] Enable 8-bit OR with disjoint bits to convert to LEA

We already support 8-bits adds in convertToThreeAddress. But we can also support 8-bit OR if the bits are disjoint. We already do this for 16/32/64.

Differential Revision: https://reviews.llvm.org/D58863

llvm-svn: 355423
16 files changed:
llvm/lib/Target/X86/X86InstrCompiler.td
llvm/lib/Target/X86/X86InstrFoldTables.cpp
llvm/lib/Target/X86/X86InstrInfo.cpp
llvm/lib/Target/X86/X86InstrInfo.h
llvm/lib/Target/X86/X86MCInstLower.cpp
llvm/lib/Target/X86/X86MacroFusion.cpp
llvm/test/CodeGen/X86/bitreverse.ll
llvm/test/CodeGen/X86/bool-math.ll
llvm/test/CodeGen/X86/fshl.ll
llvm/test/CodeGen/X86/select.ll
llvm/test/CodeGen/X86/select_const.ll
llvm/test/CodeGen/X86/unfold-masked-merge-scalar-constmask-innerouter.ll
llvm/test/CodeGen/X86/unfold-masked-merge-scalar-constmask-interleavedbits.ll
llvm/test/CodeGen/X86/unfold-masked-merge-scalar-constmask-interleavedbytehalves.ll
llvm/test/CodeGen/X86/unfold-masked-merge-scalar-constmask-lowhigh.ll
llvm/test/CodeGen/X86/vector-bitreverse.ll