opcodesswitch.h

Include dependency graph for opcodesswitch.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"]
    "32" [label="bif.h" tooltip="bif.h"]
    "18" [label="stdatomic.h" tooltip="stdatomic.h"]
    "33" [label="bitstring.h" tooltip="bitstring.h"]
    "5" [label="atom.h" tooltip="atom.h"]
    "40" [label="trace.h" tooltip="trace.h"]
    "13" [label="assert.h" tooltip="assert.h"]
    "19" [label="synclist.h" tooltip="synclist.h"]
    "35" [label="defaultatoms.h" tooltip="defaultatoms.h"]
    "4" [label="stdint.h" tooltip="stdint.h"]
    "6" [label="stdlib.h" tooltip="stdlib.h"]
    "31" [label="valueshashtable.h" tooltip="valueshashtable.h"]
    "38" [label="scheduler.h" tooltip="scheduler.h"]
    "30" [label="exportedfunction.h" tooltip="exportedfunction.h"]
    "9" [label="context.h" tooltip="context.h"]
    "24" [label="utils.h" tooltip="utils.h"]
    "7" [label="atom_table.h" tooltip="atom_table.h"]
    "12" [label="term_typedef.h" tooltip="term_typedef.h"]
    "25" [label="stddef.h" tooltip="stddef.h"]
    "14" [label="limits.h" tooltip="limits.h"]
    "39" [label="stacktrace.h" tooltip="stacktrace.h"]
    "26" [label="refc_binary.h" tooltip="refc_binary.h"]
    "22" [label="string.h" tooltip="string.h"]
    "29" [label="mailbox.h" tooltip="mailbox.h"]
    "2" [label="module.h" tooltip="module.h"]
    "21" [label="term.h" tooltip="term.h"]
    "11" [label="erl_nif.h" tooltip="erl_nif.h"]
    "37" [label="opcodes.h" tooltip="opcodes.h"]
    "27" [label="resources.h" tooltip="resources.h"]
    "17" [label="smp.h" tooltip="smp.h"]
    "8" [label="atomshashtable.h" tooltip="atomshashtable.h"]
    "36" [label="nifs.h" tooltip="nifs.h"]
    "1" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/opcodesswitch.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/opcodesswitch.h" fillcolor="#BFBFBF"]
    "34" [label="debug.h" tooltip="debug.h"]
    "10" [label="globalcontext.h" tooltip="globalcontext.h"]
    "23" [label="memory.h" tooltip="memory.h"]
    "20" [label="stdio.h" tooltip="stdio.h"]
    "28" [label="timer_list.h" tooltip="timer_list.h"]
    "16" [label="list.h" tooltip="list.h"]
    "15" [label="inttypes.h" tooltip="inttypes.h"]
    "32" -> "3" [dir=forward tooltip="include"]
    "32" -> "5" [dir=forward tooltip="include"]
    "32" -> "9" [dir=forward tooltip="include"]
    "32" -> "30" [dir=forward tooltip="include"]
    "32" -> "2" [dir=forward tooltip="include"]
    "33" -> "21" [dir=forward tooltip="include"]
    "33" -> "3" [dir=forward tooltip="include"]
    "33" -> "4" [dir=forward tooltip="include"]
    "5" -> "4" [dir=forward tooltip="include"]
    "5" -> "6" [dir=forward tooltip="include"]
    "19" -> "16" [dir=forward tooltip="include"]
    "19" -> "20" [dir=forward tooltip="include"]
    "19" -> "17" [dir=forward tooltip="include"]
    "35" -> "10" [dir=forward tooltip="include"]
    "38" -> "9" [dir=forward tooltip="include"]
    "38" -> "10" [dir=forward tooltip="include"]
    "30" -> "21" [dir=forward tooltip="include"]
    "9" -> "10" [dir=forward tooltip="include"]
    "9" -> "16" [dir=forward tooltip="include"]
    "9" -> "29" [dir=forward tooltip="include"]
    "9" -> "17" [dir=forward tooltip="include"]
    "9" -> "21" [dir=forward tooltip="include"]
    "9" -> "28" [dir=forward tooltip="include"]
    "24" -> "25" [dir=forward tooltip="include"]
    "7" -> "5" [dir=forward tooltip="include"]
    "12" -> "13" [dir=forward tooltip="include"]
    "12" -> "14" [dir=forward tooltip="include"]
    "12" -> "15" [dir=forward tooltip="include"]
    "12" -> "4" [dir=forward tooltip="include"]
    "39" -> "9" [dir=forward tooltip="include"]
    "39" -> "2" [dir=forward tooltip="include"]
    "39" -> "21" [dir=forward tooltip="include"]
    "26" -> "3" [dir=forward tooltip="include"]
    "26" -> "6" [dir=forward tooltip="include"]
    "26" -> "16" [dir=forward tooltip="include"]
    "26" -> "27" [dir=forward tooltip="include"]
    "26" -> "17" [dir=forward tooltip="include"]
    "29" -> "3" [dir=forward tooltip="include"]
    "29" -> "16" [dir=forward tooltip="include"]
    "29" -> "17" [dir=forward tooltip="include"]
    "29" -> "12" [dir=forward tooltip="include"]
    "29" -> "24" [dir=forward tooltip="include"]
    "2" -> "3" [dir=forward tooltip="include"]
    "2" -> "4" [dir=forward tooltip="include"]
    "2" -> "5" [dir=forward tooltip="include"]
    "2" -> "7" [dir=forward tooltip="include"]
    "2" -> "8" [dir=forward tooltip="include"]
    "2" -> "9" [dir=forward tooltip="include"]
    "2" -> "30" [dir=forward tooltip="include"]
    "2" -> "10" [dir=forward tooltip="include"]
    "2" -> "21" [dir=forward tooltip="include"]
    "2" -> "31" [dir=forward tooltip="include"]
    "21" -> "3" [dir=forward tooltip="include"]
    "21" -> "4" [dir=forward tooltip="include"]
    "21" -> "20" [dir=forward tooltip="include"]
    "21" -> "6" [dir=forward tooltip="include"]
    "21" -> "22" [dir=forward tooltip="include"]
    "21" -> "23" [dir=forward tooltip="include"]
    "21" -> "26" [dir=forward tooltip="include"]
    "21" -> "24" [dir=forward tooltip="include"]
    "21" -> "12" [dir=forward tooltip="include"]
    "11" -> "12" [dir=forward tooltip="include"]
    "27" -> "6" [dir=forward tooltip="include"]
    "27" -> "11" [dir=forward tooltip="include"]
    "27" -> "16" [dir=forward tooltip="include"]
    "27" -> "23" [dir=forward tooltip="include"]
    "17" -> "3" [dir=forward tooltip="include"]
    "17" -> "18" [dir=forward tooltip="include"]
    "8" -> "5" [dir=forward tooltip="include"]
    "36" -> "5" [dir=forward tooltip="include"]
    "36" -> "9" [dir=forward tooltip="include"]
    "36" -> "30" [dir=forward tooltip="include"]
    "1" -> "2" [dir=forward tooltip="include"]
    "1" -> "13" [dir=forward tooltip="include"]
    "1" -> "22" [dir=forward tooltip="include"]
    "1" -> "32" [dir=forward tooltip="include"]
    "1" -> "33" [dir=forward tooltip="include"]
    "1" -> "34" [dir=forward tooltip="include"]
    "1" -> "35" [dir=forward tooltip="include"]
    "1" -> "30" [dir=forward tooltip="include"]
    "1" -> "36" [dir=forward tooltip="include"]
    "1" -> "37" [dir=forward tooltip="include"]
    "1" -> "38" [dir=forward tooltip="include"]
    "1" -> "24" [dir=forward tooltip="include"]
    "1" -> "29" [dir=forward tooltip="include"]
    "1" -> "39" [dir=forward tooltip="include"]
    "1" -> "40" [dir=forward tooltip="include"]
    "34" -> "9" [dir=forward tooltip="include"]
    "10" -> "4" [dir=forward tooltip="include"]
    "10" -> "5" [dir=forward tooltip="include"]
    "10" -> "7" [dir=forward tooltip="include"]
    "10" -> "11" [dir=forward tooltip="include"]
    "10" -> "16" [dir=forward tooltip="include"]
    "10" -> "17" [dir=forward tooltip="include"]
    "10" -> "19" [dir=forward tooltip="include"]
    "10" -> "21" [dir=forward tooltip="include"]
    "10" -> "28" [dir=forward tooltip="include"]
    "23" -> "11" [dir=forward tooltip="include"]
    "23" -> "12" [dir=forward tooltip="include"]
    "23" -> "24" [dir=forward tooltip="include"]
    "23" -> "4" [dir=forward tooltip="include"]
    "23" -> "6" [dir=forward tooltip="include"]
    "28" -> "3" [dir=forward tooltip="include"]
    "28" -> "4" [dir=forward tooltip="include"]
    "28" -> "16" [dir=forward tooltip="include"]
}

This graph shows which files directly or indirectly include opcodesswitch.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/context.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/context.c"]
    "3" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/module.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/module.c"]
    "1" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/opcodesswitch.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/opcodesswitch.h" fillcolor="#BFBFBF"]
    "1" -> "2" [dir=back tooltip="include"]
    "1" -> "3" [dir=back tooltip="include"]
}

Defines

MINIMUM_OTP_COMPILER_VERSION
MAXIMUM_OTP_COMPILER_VERSION
COMPACT_LITERAL
COMPACT_INTEGER
COMPACT_ATOM
COMPACT_XREG
COMPACT_YREG
COMPACT_LABEL
COMPACT_EXTENDED
COMPACT_LARGE_LITERAL
COMPACT_LARGE_INTEGER
COMPACT_LARGE_ATOM
COMPACT_LARGE_YREG
COMPACT_EXTENDED_LIST
COMPACT_EXTENDED_FP_REGISTER
COMPACT_EXTENDED_ALLOCATION_LIST
COMPACT_EXTENDED_LITERAL
COMPACT_EXTENDED_TYPED_REGISTER
COMPACT_EXTENDED_ALLOCATOR_LIST_TAG_WORDS
COMPACT_EXTENDED_ALLOCATOR_LIST_TAG_FLOATS
COMPACT_EXTENDED_ALLOCATOR_LIST_TAG_FUNS
COMPACT_LARGE_IMM_MASK
COMPACT_11BITS_VALUE
COMPACT_NBITS_VALUE
SET_ERROR(error_type_atom)
RAISE_ERROR(error_type_atom)
VM_ABORT()
DEST_REGISTER(reg)
GC_SAFE_DEST_REGISTER(reg)
T_DEST_REG(dreg)
T_DEST_REG_GC_SAFE(dreg_gc_safe)
DECODE_COMPACT_TERM(dest_term, decode_pc)
READ_DEST_REGISTER(dreg)
READ_DEST_REGISTER_GC_SAFE(dreg_gc_safe)
WRITE_REGISTER(dreg, value)
WRITE_REGISTER_GC_SAFE(dreg_gc_safe, value)
DECODE_EXTENDED_LIST_TAG(decode_pc)
DECODE_NIL(decode_pc)
DECODE_DEST_REGISTER(dreg, decode_pc)
DECODE_DEST_REGISTER_GC_SAFE(dreg_gc_safe, decode_pc)
DECODE_FP_REGISTER(freg, decode_pc)
DECODE_VALUE(val, decode_pc)
DECODE_ATOM(atom, decode_pc)
DECODE_LABEL(label, decode_pc)
DECODE_LITERAL(val, decode_pc)
DECODE_INTEGER(integer, decode_pc)
DECODE_XREG(reg, decode_pc)
DECODE_YREG(reg, decode_pc)
DECODE_ALLOCATOR_LIST(need, decode_pc)
IS_EXTENDED_ALLOCATOR(decode_pc)
IS_EXTENDED_FP_REGISTER(decode_pc)
JUMP_TO_LABEL(module, label)
JUMP_TO_ADDRESS(address)
SCHEDULE_NEXT(restore_mod, restore_to)
PROCESS_SIGNAL_MESSAGES()
PROCESS_MAYBE_TRAP_RETURN_VALUE(return_value)
PROCESS_MAYBE_TRAP_RETURN_VALUE_RESTORE_PC(return_value, rest_pc)
PROCESS_MAYBE_TRAP_RETURN_VALUE_LAST(return_value)
DO_RETURN()
HANDLE_ERROR()
VERIFY_IS_INTEGER(t, opcode_name)
VERIFY_IS_ANY_INTEGER(t, opcode_name)
VERIFY_IS_BINARY(t, opcode_name)
VERIFY_IS_MATCH_STATE(t, opcode_name)
VERIFY_IS_MATCH_OR_BINARY(t, opcode_name)
CALL_FUN(fun, args_count)
DECODE_FLAGS_LIST(flags_value, flags, opcode)
MIN(X, Y)
SWAP_KV_PAIR(I, J)
TRACE_APPLY(...)
TRACE_CALL(...)
TRACE_CALL_EXT(...)
TRACE_RETURN(...)
TRACE_SEND(...)
TRACE_RECEIVE(...)

Typedefs

typedef term *dreg_t

Functions

static bool sort_kv_pairs(struct kv_pair *kv, int size, GlobalContext *global)
static int get_catch_label_and_change_module(Context *ctx, Module **mod)
static COLD_FUNC void cp_to_mod_lbl_off (term cp, Context *ctx, Module **cp_mod, int *label, int *l_off)
static COLD_FUNC void dump (Context *ctx)
static term maybe_alloc_boxed_integer_fragment(Context *ctx, avm_int64_t value)
static inline term maybe_alloc_boxed_integer_fragment_helper(Context *ctx, avm_int64_t value, unsigned int bytes_count)
static term large_integer_to_term(Context *ctx, int num_bytes, const uint8_t *compact_term)
term make_fun(Context *ctx, const Module *mod, int fun_index, term argv[])
static bool maybe_call_native(Context *ctx, AtomString module_name, AtomString function_name, int arity, term *return_value)
memcpy (tmp_atom_name+1, function_name, function_len)
free(tmp_atom_name)
if (UNLIKELY(!label))
scheduler_init_ready(ctx)
return scheduler_entry_point (ctx->global)
HOT_FUNC int scheduler_entry_point (GlobalContext *glb)

Variables

int function_len = strlen(function_name)
uint8_t *tmp_atom_name = malloc(function_len + 1)
int label = module_search_exported_function(mod, tmp_atom_name, arity, ctx->global)
ctx saved_module = mod
ctx cp = module_address(mod->module_index, mod->end_instruction_ii)
ctx saved_ip = mod->labels[label]
ctx global running_schedulers   = 1
struct dreg_gc_safe_t

Public Members

term *base
int index
struct Int24

Public Members

int32_t val24
struct Int40

Public Members

int64_t val40
struct Int48

Public Members

int64_t val48
struct Int56

Public Members

int64_t val56
struct kv_pair

Public Members

term key
term value