Implement the sadd_with_overflow intrinsic. This is converted into
authorBill Wendling <isanbard@gmail.com>
Fri, 21 Nov 2008 02:03:52 +0000 (02:03 +0000)
committerBill Wendling <isanbard@gmail.com>
Fri, 21 Nov 2008 02:03:52 +0000 (02:03 +0000)
commit7cdc3c8ad208d9655be542fc8b082c4457af4b6e
tree2607393bf8389b129d0bf65fcd64709cd515c4d5
parentcb9a354d1323bed4043e716503226678ae520f53
Implement the sadd_with_overflow intrinsic. This is converted into
"ISD::ADDO". ISD::ADDO is lowered into a target-independent form that does the
addition and then checks if the result is less than one of the operands. (If it
is, then there was an overflow.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59779 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/SelectionDAGNodes.h
lib/CodeGen/SelectionDAG/DAGCombiner.cpp
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp