Skip to main content

Module opcodes

Module opcodes 

Source
Expand description

EVM opcode mnemonics, for naming the instructions of legacy bytecode.

Legacy source maps carry no mnemonics, so adapting one to the ETHDebug model means naming each instruction from its byte. The table is the opcode set REVM knows, so the names match what an execution backend records for the same steps and a JUMPDEST in an artifact is a JUMPDEST in a trace. A byte with no mnemonic is an invalid instruction.

Functionsยง

immediate_size
The number of immediate bytes following opcode in legacy bytecode: n for PUSHn and zero for everything else.
mnemonic
The mnemonic of opcode, or None for a byte that is not an instruction.