]> granicus.if.org Git - llvm/commit
[GlobalISel][AArch64] Use getConstantVRegValWithLookThrough for selectArithImmed
authorJessica Paquette <jpaquette@apple.com>
Wed, 3 Jul 2019 17:46:23 +0000 (17:46 +0000)
committerJessica Paquette <jpaquette@apple.com>
Wed, 3 Jul 2019 17:46:23 +0000 (17:46 +0000)
commit11cb153503d777c4bf39816761e6cedaf19c1369
treeb9dd16fa80cbab35181c4fac840f632d521e979f
parent707ccb57df33e9f8e869a0094bb7c5f614fb1fbc
[GlobalISel][AArch64] Use getConstantVRegValWithLookThrough for selectArithImmed

Instead of just stopping to see if we have a G_CONSTANT, instead, look through
G_TRUNCs, G_SEXTs, and G_ZEXTs.

This gives an average ~1.3% code size improvement on CINT2000 at -O3.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@365063 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AArch64/AArch64InstructionSelector.cpp
test/CodeGen/AArch64/GlobalISel/select-cmp.mir
test/CodeGen/AArch64/GlobalISel/select-jump-table-brjt.mir