MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / run_extended

Function run_extended

pulley/src/interp/tail_loop.rs:99–108  ·  view source on GitHub ↗

Same as `Interpreter::run`, except for extended opcodes.

(
    state: &mut MachineState,
    pc: UnsafeBytecodeStream,
    pc_ref: ExecutingPcRef<'_>,
)

Source from the content-addressed store, hash-verified

97
98/// Same as `Interpreter::run`, except for extended opcodes.
99fn run_extended(
100 state: &mut MachineState,
101 pc: UnsafeBytecodeStream,
102 pc_ref: ExecutingPcRef<'_>,
103) -> Done {
104 let mut i = debug(state, pc, pc_ref);
105 let Ok(opcode) = ExtendedOpcode::decode(i.bytecode());
106 let handler = EXTENDED_OPCODE_HANDLER_TABLE[opcode as usize];
107 tail_call!(handler(i.0.state, i.0.pc, i.0.executing_pc));
108}
109
110static OPCODE_HANDLER_TABLE: [Handler; Opcode::MAX as usize + 1] = {
111 macro_rules! define_opcode_handler_table {

Callers

nothing calls this directly

Calls 3

decodeFunction · 0.85
debugFunction · 0.70
bytecodeMethod · 0.45

Tested by

no test coverage detected