overflow_helpers.h

Include dependency graph for overflow_helpers.h:

digraph {
    graph [bgcolor="#00000000"]
    node [shape=rectangle style=filled fillcolor="#FFFFFF" font=Helvetica padding=2]
    edge [color="#1414CE"]
    "3" [label="stdbool.h" tooltip="stdbool.h"]
    "19" [label="stdatomic.h" tooltip="stdatomic.h"]
    "4" [label="stdint.h" tooltip="stdint.h"]
    "6" [label="stdlib.h" tooltip="stdlib.h"]
    "13" [label="utils.h" tooltip="utils.h"]
    "1" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h" fillcolor="#BFBFBF"]
    "10" [label="term_typedef.h" tooltip="term_typedef.h"]
    "14" [label="stddef.h" tooltip="stddef.h"]
    "11" [label="limits.h" tooltip="limits.h"]
    "15" [label="refc_binary.h" tooltip="refc_binary.h"]
    "7" [label="string.h" tooltip="string.h"]
    "2" [label="term.h" tooltip="term.h"]
    "9" [label="erl_nif.h" tooltip="erl_nif.h"]
    "17" [label="resources.h" tooltip="resources.h"]
    "18" [label="smp.h" tooltip="smp.h"]
    "8" [label="memory.h" tooltip="memory.h"]
    "5" [label="stdio.h" tooltip="stdio.h"]
    "16" [label="list.h" tooltip="list.h"]
    "12" [label="inttypes.h" tooltip="inttypes.h"]
    "13" -> "14" [dir=forward tooltip="include"]
    "1" -> "2" [dir=forward tooltip="include"]
    "1" -> "4" [dir=forward tooltip="include"]
    "10" -> "11" [dir=forward tooltip="include"]
    "10" -> "12" [dir=forward tooltip="include"]
    "10" -> "4" [dir=forward tooltip="include"]
    "15" -> "3" [dir=forward tooltip="include"]
    "15" -> "6" [dir=forward tooltip="include"]
    "15" -> "16" [dir=forward tooltip="include"]
    "15" -> "17" [dir=forward tooltip="include"]
    "15" -> "18" [dir=forward tooltip="include"]
    "2" -> "3" [dir=forward tooltip="include"]
    "2" -> "4" [dir=forward tooltip="include"]
    "2" -> "5" [dir=forward tooltip="include"]
    "2" -> "6" [dir=forward tooltip="include"]
    "2" -> "7" [dir=forward tooltip="include"]
    "2" -> "8" [dir=forward tooltip="include"]
    "2" -> "15" [dir=forward tooltip="include"]
    "2" -> "13" [dir=forward tooltip="include"]
    "2" -> "10" [dir=forward tooltip="include"]
    "9" -> "10" [dir=forward tooltip="include"]
    "17" -> "6" [dir=forward tooltip="include"]
    "17" -> "9" [dir=forward tooltip="include"]
    "17" -> "16" [dir=forward tooltip="include"]
    "17" -> "8" [dir=forward tooltip="include"]
    "18" -> "3" [dir=forward tooltip="include"]
    "18" -> "19" [dir=forward tooltip="include"]
    "8" -> "9" [dir=forward tooltip="include"]
    "8" -> "10" [dir=forward tooltip="include"]
    "8" -> "13" [dir=forward tooltip="include"]
    "8" -> "4" [dir=forward tooltip="include"]
    "8" -> "6" [dir=forward tooltip="include"]
}

This graph shows which files directly or indirectly include overflow_helpers.h:

digraph {
    graph [bgcolor="#00000000"]
    node [shape=rectangle style=filled fillcolor="#FFFFFF" font=Helvetica padding=2]
    edge [color="#1414CE"]
    "2" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bif.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bif.c"]
    "1" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h" fillcolor="#BFBFBF"]
    "1" -> "2" [dir=back tooltip="include"]
}

Defines

BUILTIN_ADD_OVERFLOW
BUILTIN_ADD_OVERFLOW_INT
BUILTIN_ADD_OVERFLOW_INT64
BUILTIN_SUB_OVERFLOW
BUILTIN_SUB_OVERFLOW_INT
BUILTIN_SUB_OVERFLOW_INT64
BUILTIN_MUL_OVERFLOW
BUILTIN_MUL_OVERFLOW_INT
BUILTIN_MUL_OVERFLOW_INT64

Functions

static inline int atomvm_add_overflow(avm_int_t a, avm_int_t b, avm_int_t *res)
static inline int atomvm_add_overflow_int(avm_int_t a, avm_int_t b, avm_int_t *res)
static inline int atomvm_add_overflow_int64(avm_int64_t a, avm_int64_t b, avm_int64_t *res)
static inline int atomvm_sub_overflow(avm_int_t a, avm_int_t b, avm_int_t *res)
static inline int atomvm_sub_overflow_int(avm_int_t a, avm_int_t b, avm_int_t *res)
static inline int atomvm_sub_overflow_int64(avm_int64_t a, avm_int64_t b, avm_int64_t *res)
static inline int atomvm_mul_overflow_int(avm_int_t a, avm_int_t b, avm_int_t *res)
static inline int atomvm_mul_overflow_int64(avm_int64_t a, avm_int64_t b, avm_int64_t *res)
static inline int atomvm_mul_overflow(avm_int_t a, avm_int_t b, avm_int_t *res)