[X86] Teach constant hoisting that ANDs with 64-bit immediates in the range 0x8000000...
authorCraig Topper <craig.topper@gmail.com>
Tue, 6 Oct 2015 02:50:24 +0000 (02:50 +0000)
committerCraig Topper <craig.topper@gmail.com>
Tue, 6 Oct 2015 02:50:24 +0000 (02:50 +0000)
commit50bf4331f44b1cee0fcab3050d3b3d41ffa3a6ad
treeb50e4db783fd58635daa8ac3eb4da9a151ddaebf
parenta1a1f2a090e3394b926531e6ecd46cd81ea1d113
[X86] Teach constant hoisting that ANDs with 64-bit immediates in the range 0x80000000-0xffffffff can be handled cheaply and don't need to be hoisted.

Most importantly, this keeps constant hoisting from preventing instruction selections ability to turn an AND with 0xffffffff into a move into a 32-bit subregister.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@249370 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86TargetTransformInfo.cpp
test/CodeGen/X86/constant-hoisting-and.ll [new file with mode: 0644]