Compute whether a signed add of LHS and RHS can overflow.
Declared in <llvm/Transforms/InstCombine/InstCombiner.h>
OverflowResult
computeOverflowForSignedAdd(
WithCache<Value const*> const& LHS,
WithCache<Value const*> const& RHS,
Instruction const* CxtI) const;
Whether the signed add can overflow.
| Name | Description |
|---|---|
| LHS | Left-hand operand of the add. |
| RHS | Right-hand operand of the add. |
| CxtI | Optional context instruction for local analysis. |