Module program

Module program 

Source

Modules§

asm

Macros§

build_static_dispatch_table_jam_v1
build_static_dispatch_table_latest32
build_static_dispatch_table_latest64
build_static_dispatch_table_revive_v1

Structs§

FrameInfo
ISA_JamV1
ISA_Latest32
ISA_Latest64
ISA_ReviveV1
Imports
ImportsIter
InstructionFormat
Instructions
JumpTable
JumpTableIter
LineProgram
A line program state machine.
ParsedInstruction
ProgramBlob
A partially deserialized PolkaVM program.
ProgramCounter
ProgramExport
ProgramMemoryInfo
ProgramParseError
ProgramParts
ProgramSymbol
RawReg
RegionInfo
Debug information about a given region of bytecode.

Enums§

EstimateInterpreterMemoryUsageArgs
FrameKind
Instruction
InstructionSetKind
LineProgramOp
Opcode
Reg
SourceLocation
The source location.

Constants§

BITMASK_MAX
BLOB_LEN_OFFSET
BLOB_LEN_SIZE
BLOB_MAGIC
The magic bytes with which every program blob must start with.
INTERPRETER_CACHE_ENTRY_SIZE
INTERPRETER_CACHE_RESERVED_ENTRIES
INTERPRETER_FLATMAP_ENTRY_SIZE
MAX_INSTRUCTION_LENGTH
SECTION_CODE_AND_JUMP_TABLE
SECTION_END_OF_FILE
SECTION_EXPORTS
SECTION_IMPORTS
SECTION_MEMORY_CONFIG
SECTION_OPT_DEBUG_LINE_PROGRAMS
SECTION_OPT_DEBUG_LINE_PROGRAM_RANGES
SECTION_OPT_DEBUG_STRINGS
SECTION_RO_DATA
SECTION_RW_DATA
VERSION_DEBUG_LINE_PROGRAM_V1

Traits§

InstructionSet
InstructionVisitor
OpcodeVisitor
The lowest level visitor; dispatches directly on opcode numbers.
ParsingVisitor

Functions§

find_start_of_basic_block
get_bit_for_offset
interpreter_calculate_cache_num_entries
interpreter_calculate_cache_size
is_jump_target_valid
Returns whether a jump to a given offset is allowed.
read_args_imm
read_args_imm2
read_args_offset
read_args_reg_imm
read_args_reg_imm2
read_args_reg_imm64
read_args_reg_imm_offset
read_args_regs2
read_args_regs3
read_args_regs2_imm
read_args_regs2_imm2
read_args_regs2_offset

Type Aliases§

BlobLen
The blob length is the length of the blob itself encoded as an 64bit LE integer. By embedding this metadata into the header, program blobs stay opaque, however this information can still easily be retrieved. Found at offset 5 after the magic bytes and version number.