diff options
author | Leonard Chan <leonardchan@google.com> | 2018-10-16 17:35:41 +0000 |
---|---|---|
committer | Leonard Chan <leonardchan@google.com> | 2018-10-16 17:35:41 +0000 |
commit | 699b3b54da2f483228544234e5ed375aa81acd9f (patch) | |
tree | 145a229fe95f4d87fbd99ae1ee8fc2e912876d04 /llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp | |
parent | d3ff1ecfde95549db960aaca4848f7436ca28431 (diff) | |
download | bcm5719-llvm-699b3b54da2f483228544234e5ed375aa81acd9f.tar.gz bcm5719-llvm-699b3b54da2f483228544234e5ed375aa81acd9f.zip |
[Intrinsic] Signed Saturation Addition Intrinsic
Add an intrinsic that takes 2 integers and perform saturation addition on them.
This is a part of implementing fixed point arithmetic in clang where some of
the more complex operations will be implemented as intrinsics.
Differential Revision: https://reviews.llvm.org/D53053
llvm-svn: 344629
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp b/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp index 58d86e8e52e..2c1a4942f68 100644 --- a/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp @@ -386,6 +386,7 @@ SDValue VectorLegalizer::LegalizeOp(SDValue Op) { case ISD::SMUL_LOHI: case ISD::UMUL_LOHI: case ISD::FCANONICALIZE: + case ISD::SADDSAT: Action = TLI.getOperationAction(Node->getOpcode(), Node->getValueType(0)); break; case ISD::FP_ROUND_INREG: |