[#llvm-operator_minus-0e] = xref:llvm.adoc[llvm]::operator‐ :relfileprefix: ../ :mrdocs: Unary minus operators == Synopses Declared in `<llvm/ADT/DynamicAPInt.h>` Negate an APInt. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/APInt.adoc[APInt] xref:llvm/operator_minus-03.adoc[operator‐](xref:llvm/APInt.adoc[APInt] v); ---- [.small]#xref:llvm/operator_minus-03.adoc[_» more..._]# Subtract a 64‐bit value from an APInt. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/APInt.adoc[APInt] xref:llvm/operator_minus-0c.adoc[operator‐]( xref:llvm/APInt.adoc[APInt] a, uint64_t RHS); ---- [.small]#xref:llvm/operator_minus-0c.adoc[_» more..._]# Subtract two APInts. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/APInt.adoc[APInt] xref:llvm/operator_minus-0dd.adoc[operator‐]( xref:llvm/APInt.adoc[APInt] a, xref:llvm/APInt.adoc[APInt] const& b); ---- [.small]#xref:llvm/operator_minus-0dd.adoc[_» more..._]# Returns `A` minus `B.` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/DynamicAPInt.adoc[DynamicAPInt] xref:llvm/operator_minus-01.adoc[operator‐]( int64_t A, xref:llvm/DynamicAPInt.adoc[DynamicAPInt] const& B); ---- [.small]#xref:llvm/operator_minus-01.adoc[_» more..._]# Subtract an APInt from a 64‐bit value. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/APInt.adoc[APInt] xref:llvm/operator_minus-02.adoc[operator‐]( uint64_t LHS, xref:llvm/APInt.adoc[APInt] b); ---- [.small]#xref:llvm/operator_minus-02.adoc[_» more..._]# Subtract that prefers moving from `b.` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/APInt.adoc[APInt] xref:llvm/operator_minus-083.adoc[operator‐]( xref:llvm/APInt.adoc[APInt] const& a, xref:llvm/APInt.adoc[APInt]&& b); ---- [.small]#xref:llvm/operator_minus-083.adoc[_» more..._]# Returns `A` minus `B.` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/DynamicAPInt.adoc[DynamicAPInt] xref:llvm/operator_minus-0d2.adoc[operator‐]( xref:llvm/DynamicAPInt.adoc[DynamicAPInt] const& A, int64_t B); ---- [.small]#xref:llvm/operator_minus-0d2.adoc[_» more..._]# Return the saturating difference of `LHS` and `RHS.` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- xref:llvm/InstructionCost.adoc[InstructionCost] xref:llvm/operator_minus-088.adoc[operator‐]( xref:llvm/InstructionCost.adoc[InstructionCost] const& LHS, xref:llvm/InstructionCost.adoc[InstructionCost] const& RHS); ---- [.small]#xref:llvm/operator_minus-088.adoc[_» more..._]# Return the difference of `L` and `R` using saturating arithmetic. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class DigitsT> xref:llvm/ScaledNumber.adoc[ScaledNumber<DigitsT>] xref:llvm/operator_minus-0b.adoc[operator‐]( xref:llvm/ScaledNumber.adoc[ScaledNumber<DigitsT>] const& L, xref:llvm/ScaledNumber.adoc[ScaledNumber<DigitsT>] const& R); ---- [.small]#xref:llvm/operator_minus-0b.adoc[_» more..._]# Return a sparse bit vector with bits of `LHS` that are clear in `RHS.` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<unsigned int ElementSize> xref:llvm/SparseBitVector.adoc[SparseBitVector<ElementSize>] xref:llvm/operator_minus-09.adoc[operator‐]( xref:llvm/SparseBitVector.adoc[SparseBitVector<ElementSize>] const& LHS, xref:llvm/SparseBitVector.adoc[SparseBitVector<ElementSize>] const& RHS); ---- [.small]#xref:llvm/operator_minus-09.adoc[_» more..._]# == Return Value * The negation of `v.` * The difference of `a` and `RHS.` * The difference of `a` and `b.` * Difference of `A` and `B.` * The difference of `LHS` and `b.` * The saturating difference of `LHS` and `RHS.` * Difference of `L` and `R.` * New vector equal to `LHS` intersected with the complement of `RHS.` == Parameters [cols="1,4"] |=== | Name| Description | *v* | Value to negate | *a* | Left‐hand APInt | *RHS* | Right‐hand 64‐bit value | *b* | Right‐hand operand | *A* | Left‐hand operand. | *B* | Right‐hand operand. | *LHS* | Left‐hand 64‐bit value | *L* | Left‐hand scaled number. | *R* | Right‐hand scaled number. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#