Package com.dylibso.chicory.runtime
Class InterpreterMachine
java.lang.Object
com.dylibso.chicory.runtime.InterpreterMachine
- All Implemented Interfaces:
Machine
This is responsible for holding and interpreting the Wasm code.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlong[]call(int funcId, long[] args) protected voideval(MStack stack, Instance instance, Deque<StackFrame> callStack) protected voidevalDefault(MStack stack, Instance instance, Deque<StackFrame> callStack, Instruction instruction, InterpreterMachine.Operands operands) protected static intreadMemPtr(MStack stack, InterpreterMachine.Operands operands) protected static voidverifyIndirectCall(FunctionType actual, FunctionType expected)
-
Constructor Details
-
InterpreterMachine
-
-
Method Details
-
evalDefault
protected void evalDefault(MStack stack, Instance instance, Deque<StackFrame> callStack, Instruction instruction, InterpreterMachine.Operands operands) throws ChicoryException - Throws:
ChicoryException
-
call
- Specified by:
callin interfaceMachine- Throws:
ChicoryException
-
eval
protected void eval(MStack stack, Instance instance, Deque<StackFrame> callStack) throws ChicoryException - Throws:
ChicoryException
-
readMemPtr
-
verifyIndirectCall
protected static void verifyIndirectCall(FunctionType actual, FunctionType expected) throws ChicoryException - Throws:
ChicoryException
-