[ARM] Ensure we do not attempt to create lsll #0
commita35e525184069ad5852ddf14bcef334c5c3e0ac9
authorDavid Green <david.green@arm.com>
Wed, 25 Sep 2019 10:16:48 +0000 (25 10:16 +0000)
committerDavid Green <david.green@arm.com>
Wed, 25 Sep 2019 10:16:48 +0000 (25 10:16 +0000)
treeeb37359e201793aa0ed4d5d89f70094cbca5bf90
parentbf355ffd89d51cae09bf5dbd1abe736afe4aee58
[ARM] Ensure we do not attempt to create lsll #0

During legalisation we can end up with some pretty strange nodes, like shifts
of 0. We need to make sure we don't try to make long shifts of these, ending up
with invalid assembly instructions. A long shift with a zero immediate actually
encodes a shift by 32.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@372839 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMISelLowering.cpp
lib/Target/ARM/ARMInstrMVE.td
lib/Target/ARM/ARMInstrThumb2.td
test/CodeGen/Thumb2/lsll0.ll [new file with mode: 0644]