14#ifndef LLVM_SUPPORT_CHECKEDARITHMETIC_H 
   15#define LLVM_SUPPORT_CHECKEDARITHMETIC_H 
   27template <
typename T, 
typename F>
 
   28std::enable_if_t<std::is_integral_v<T> && 
sizeof(
T) * 8 <= 64, std::optional<T>>
 
   84std::enable_if_t<std::is_unsigned_v<T>, std::optional<T>>
 
   93std::enable_if_t<std::is_unsigned_v<T>, std::optional<T>>
 
  102std::enable_if_t<std::is_unsigned_v<T>, std::optional<T>>
 
This file implements a class to represent arbitrary precision integral constant values and operations...
 
static GCRegistry::Add< ErlangGC > A("erlang", "erlang-compatible garbage collector")
 
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
 
Class for arbitrary precision integers.
 
LLVM_ABI APInt umul_ov(const APInt &RHS, bool &Overflow) const
 
uint64_t getZExtValue() const
Get zero extended value.
 
LLVM_ABI APInt sadd_ov(const APInt &RHS, bool &Overflow) const
 
LLVM_ABI APInt uadd_ov(const APInt &RHS, bool &Overflow) const
 
LLVM_ABI APInt smul_ov(const APInt &RHS, bool &Overflow) const
 
LLVM_ABI APInt ssub_ov(const APInt &RHS, bool &Overflow) const
 
int64_t getSExtValue() const
Get sign extended value.
 
@ C
The default llvm calling convention, compatible with C.
 
This is an optimization pass for GlobalISel generic memory operations.
 
std::enable_if_t< std::is_unsigned_v< T >, std::optional< T > > checkedMulUnsigned(T LHS, T RHS)
Multiply two unsigned integers LHS and RHS.
 
std::enable_if_t< std::is_unsigned_v< T >, std::optional< T > > checkedAddUnsigned(T LHS, T RHS)
Add two unsigned integers LHS and RHS.
 
std::enable_if_t< std::is_unsigned_v< T >, std::optional< T > > checkedMulAddUnsigned(T A, T B, T C)
Multiply unsigned integers A and B, and add C to the resulting product.
 
std::enable_if_t< std::is_signed_v< T >, std::optional< T > > checkedSub(T LHS, T RHS)
Subtract two signed integers LHS and RHS.
 
std::enable_if_t< std::is_signed_v< T >, std::optional< T > > checkedAdd(T LHS, T RHS)
Add two signed integers LHS and RHS.
 
std::enable_if_t< std::is_signed_v< T >, std::optional< T > > checkedMulAdd(T A, T B, T C)
Multiply A and B, and add C to the resulting product.
 
std::enable_if_t< std::is_signed_v< T >, std::optional< T > > checkedMul(T LHS, T RHS)
Multiply two signed integers LHS and RHS.