Enum OpcodeDispatcher.DispatchResult
- java.lang.Object
-
- java.lang.Enum<OpcodeDispatcher.DispatchResult>
-
- com.tonic.analysis.execution.dispatch.OpcodeDispatcher.DispatchResult
-
- All Implemented Interfaces:
Serializable,Comparable<OpcodeDispatcher.DispatchResult>
- Enclosing class:
- OpcodeDispatcher
public static enum OpcodeDispatcher.DispatchResult extends Enum<OpcodeDispatcher.DispatchResult>
Outcome of a dispatch step, directing the interpreter's next action.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ATHROWAnathrowwas executed; the thrown reference is on the stack and needs handler lookup.BRANCHControl transfers to the branch target the dispatcher left on the context.CHECKCASTA cast check was performed; the dispatcher already applied it, so no follow-up is needed.CONSTANT_DYNAMICA dynamic constant was loaded and the interpreter must run its bootstrap method to produce the value.CONTINUEThe instruction finished in place and the program counter already advanced; nothing more is owed by the interpreter.FIELD_GETA field read is pending and must be serviced against the heap before execution resumes.FIELD_PUTA field write is pending and must be serviced against the heap before execution resumes.INSTANCEOFA type test was performed; the dispatcher already pushed its result.INVOKEA call was reached; the interpreter must resolve the target and push a new frame.INVOKE_DYNAMICAn invokedynamic call site was reached; the interpreter must link it through its bootstrap method before the call can proceed.METHOD_HANDLEA method handle constant was loaded and the interpreter must materialize it from the handle info left on the context.METHOD_TYPEAMethodTypeconstant was loaded and the interpreter must materialize it from the descriptor left on the context.NEW_ARRAYAn array must be allocated, covering the primitive, reference, and multi-dimensional forms; the dimension counts are left on the context.NEW_OBJECTAn instance must be allocated for the pendingnew, before its constructor runs.RETURNThe current frame completes and hands its return value, if any, to the caller.THROWThe interpreter must raise an exception it detected itself, such as a division by zero, rather than one the code threw explicitly.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static OpcodeDispatcher.DispatchResultvalueOf(String name)Returns the enum constant of this type with the specified name.static OpcodeDispatcher.DispatchResult[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
CONTINUE
public static final OpcodeDispatcher.DispatchResult CONTINUE
The instruction finished in place and the program counter already advanced; nothing more is owed by the interpreter.
-
BRANCH
public static final OpcodeDispatcher.DispatchResult BRANCH
Control transfers to the branch target the dispatcher left on the context.
-
INVOKE
public static final OpcodeDispatcher.DispatchResult INVOKE
A call was reached; the interpreter must resolve the target and push a new frame.
-
INVOKE_DYNAMIC
public static final OpcodeDispatcher.DispatchResult INVOKE_DYNAMIC
An invokedynamic call site was reached; the interpreter must link it through its bootstrap method before the call can proceed.
-
CONSTANT_DYNAMIC
public static final OpcodeDispatcher.DispatchResult CONSTANT_DYNAMIC
A dynamic constant was loaded and the interpreter must run its bootstrap method to produce the value.
-
METHOD_HANDLE
public static final OpcodeDispatcher.DispatchResult METHOD_HANDLE
A method handle constant was loaded and the interpreter must materialize it from the handle info left on the context.
-
METHOD_TYPE
public static final OpcodeDispatcher.DispatchResult METHOD_TYPE
AMethodTypeconstant was loaded and the interpreter must materialize it from the descriptor left on the context.
-
RETURN
public static final OpcodeDispatcher.DispatchResult RETURN
The current frame completes and hands its return value, if any, to the caller.
-
THROW
public static final OpcodeDispatcher.DispatchResult THROW
The interpreter must raise an exception it detected itself, such as a division by zero, rather than one the code threw explicitly.
-
ATHROW
public static final OpcodeDispatcher.DispatchResult ATHROW
Anathrowwas executed; the thrown reference is on the stack and needs handler lookup.
-
FIELD_GET
public static final OpcodeDispatcher.DispatchResult FIELD_GET
A field read is pending and must be serviced against the heap before execution resumes.
-
FIELD_PUT
public static final OpcodeDispatcher.DispatchResult FIELD_PUT
A field write is pending and must be serviced against the heap before execution resumes.
-
NEW_OBJECT
public static final OpcodeDispatcher.DispatchResult NEW_OBJECT
An instance must be allocated for the pendingnew, before its constructor runs.
-
NEW_ARRAY
public static final OpcodeDispatcher.DispatchResult NEW_ARRAY
An array must be allocated, covering the primitive, reference, and multi-dimensional forms; the dimension counts are left on the context.
-
CHECKCAST
public static final OpcodeDispatcher.DispatchResult CHECKCAST
A cast check was performed; the dispatcher already applied it, so no follow-up is needed.
-
INSTANCEOF
public static final OpcodeDispatcher.DispatchResult INSTANCEOF
A type test was performed; the dispatcher already pushed its result.
-
-
Method Detail
-
values
public static OpcodeDispatcher.DispatchResult[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (OpcodeDispatcher.DispatchResult c : OpcodeDispatcher.DispatchResult.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static OpcodeDispatcher.DispatchResult valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
-