]> granicus.if.org Git - llvm/commit
[TargetLowering] Simplify expansion of S{ADD,SUB}O
authorRoger Ferrer Ibanez <rofirrim@gmail.com>
Mon, 30 Sep 2019 07:58:50 +0000 (07:58 +0000)
committerRoger Ferrer Ibanez <rofirrim@gmail.com>
Mon, 30 Sep 2019 07:58:50 +0000 (07:58 +0000)
commitca6e7338d6e7c00ec1d1f834b108bc8381792fa1
tree1a164f0a68cf6323bf08fa51f283e44e484e06b8
parent58649a3897bb9209daf136753c0359a5246bb9ba
[TargetLowering] Simplify expansion of S{ADD,SUB}O

ISD::SADDO uses the suggested sequence described in the section ยง2.4 of
the RISCV Spec v2.2. ISD::SSUBO uses the dual approach but checking for
(non-zero) positive.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@373187 91177308-0d34-0410-b5e6-96231b3b80d8
16 files changed:
lib/CodeGen/SelectionDAG/TargetLowering.cpp
test/CodeGen/AArch64/sadd_sat.ll
test/CodeGen/AArch64/sadd_sat_vec.ll
test/CodeGen/AArch64/ssub_sat.ll
test/CodeGen/AArch64/ssub_sat_vec.ll
test/CodeGen/AMDGPU/saddo.ll
test/CodeGen/ARM/addsubo-legalization.ll
test/CodeGen/RISCV/arith-with-overflow.ll
test/CodeGen/X86/combine-mulo.ll
test/CodeGen/X86/mulo-pow2.ll
test/CodeGen/X86/sadd_sat.ll
test/CodeGen/X86/sadd_sat_vec.ll
test/CodeGen/X86/ssub_sat.ll
test/CodeGen/X86/ssub_sat_vec.ll
test/CodeGen/X86/vec_saddo.ll
test/CodeGen/X86/vec_ssubo.ll