[ARM] Add qadd lowering from a sadd_sat
commit67842adc8419376f0a0bf510404c159c3231d267
authorDavid Green <david.green@arm.com>
Mon, 21 Oct 2019 12:33:46 +0000 (21 12:33 +0000)
committerDavid Green <david.green@arm.com>
Mon, 21 Oct 2019 12:33:46 +0000 (21 12:33 +0000)
treed83d5e3cde734c7dd65c047aab2bd72a6a23e64b
parent77a153c89b66734a2fffe42734d1e098d303d9c0
[ARM] Add qadd lowering from a sadd_sat

This lowers a sadd_sat to a qadd by treating it as legal. Also adds qsub at the
same time.

The qadd instruction sets the q flag, but we already have many cases where we
do not model this in llvm.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@375411 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMISelLowering.cpp
lib/Target/ARM/ARMInstrInfo.td
lib/Target/ARM/ARMInstrThumb2.td
lib/Target/ARM/ARMSubtarget.h
test/CodeGen/ARM/qdadd.ll
test/CodeGen/ARM/sadd_sat.ll
test/CodeGen/ARM/sadd_sat_plus.ll
test/CodeGen/ARM/ssub_sat.ll
test/CodeGen/ARM/ssub_sat_plus.ll