]> granicus.if.org Git - llvm/commit
[ARM] Add support for the MVE long shift instructions
authorSam Tebbs <sam.tebbs@arm.com>
Fri, 28 Jun 2019 15:43:31 +0000 (15:43 +0000)
committerSam Tebbs <sam.tebbs@arm.com>
Fri, 28 Jun 2019 15:43:31 +0000 (15:43 +0000)
commita71ac42554f035a7554c332a593a9ea7c70a15f0
treef28d8a4b4e00feb4128660eaec88d692dbab18e8
parentcdc939779e850103f5958c242b146c83f860eb26
[ARM] Add support for the MVE long shift instructions

MVE adds the lsll, lsrl and asrl instructions, which perform a shift on a 64 bit value separated into two 32 bit registers.

The Expand64BitShift function is modified to accept ISD::SHL, ISD::SRL and ISD::SRA and convert it into the appropriate opcode in ARMISD. An SHL is converted into an lsll, an SRL is converted into an lsrl for the immediate form and a negation and lsll for the register form, and SRA is converted into an asrl.

test/CodeGen/ARM/shift_parts.ll is added to test the logic of emitting these instructions.

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

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