[ARM][GlobalISel] Legalize narrow scalar ops by widening
authorDiana Picus <diana.picus@linaro.org>
Thu, 11 May 2017 09:45:57 +0000 (09:45 +0000)
committerDiana Picus <diana.picus@linaro.org>
Thu, 11 May 2017 09:45:57 +0000 (09:45 +0000)
commit9cfbc6d94f6d7ae4c64c88fac3263301ab75e381
tree002332afd27f7510c6e39557a5397719227c793d
parent0550581070abf6a509f969b149b683da1b297921
[ARM][GlobalISel] Legalize narrow scalar ops by widening

This is the same as r292827 for AArch64: we widen 8- and 16-bit ADD, SUB
and MUL to 32 bits since we only have TableGen patterns for 32 bits.
See the commit message for r292827 for more details.

At this point we could just remove some of the tests for regbankselect
and instruction-select, since we're not going to see any narrow
operations at those levels anymore. Instead I decided to update them
with G_ANYEXT/G_TRUNC operations, so we can validate the full sequences
generated by the legalizer.

llvm-svn: 302782
llvm/lib/Target/ARM/ARMLegalizerInfo.cpp
llvm/test/CodeGen/ARM/GlobalISel/arm-instruction-select.mir
llvm/test/CodeGen/ARM/GlobalISel/arm-legalizer.mir
llvm/test/CodeGen/ARM/GlobalISel/arm-regbankselect.mir