author | Hal Finkel <hfinkel@anl.gov> | |
Sun, 4 Jan 2015 12:35:03 +0000 (12:35 +0000) | ||
committer | Hal Finkel <hfinkel@anl.gov> | |
Sun, 4 Jan 2015 12:35:03 +0000 (12:35 +0000) | ||
commit | d138a7bb3f49cc92d0ab81ac68c63284adce2fbf | |
tree | 9bb3df24920e8493ef1e6664b3284d745983a982 | tree | snapshot (tar.xz tar.gz zip) |
parent | 5a9cd4d44e4bd15f835aec280ea158d2c7c5a920 | commit | diff |
[PowerPC] Materialize i64 constants using bit inversion
Materializing full 64-bit constants on PPC64 can be expensive, requiring up to
5 instructions depending on the locations of the non-zero bits. Sometimes
materializing the bit-reversed constant, and then flipping the bits, requires
fewer instructions than the direct method. If so, do that instead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225132 91177308-0d34-0410-b5e6-96231b3b80d8
Materializing full 64-bit constants on PPC64 can be expensive, requiring up to
5 instructions depending on the locations of the non-zero bits. Sometimes
materializing the bit-reversed constant, and then flipping the bits, requires
fewer instructions than the direct method. If so, do that instead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225132 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/PowerPC/PPCISelDAGToDAG.cpp | diff | blob | history | |
test/CodeGen/PowerPC/constants-i64.ll | [new file with mode: 0644] | blob |