public interface NodePlugin extends GraphBuilderPlugin
Modifier and Type | Method and Description |
---|---|
default boolean |
canChangeStackKind(GraphBuilderContext b)
If the plugin
pushes a value with a different Kind
than specified by the bytecode, it must override this method and return true . |
default boolean |
handleCheckCast(GraphBuilderContext b,
com.oracle.graal.nodes.ValueNode object,
jdk.internal.jvmci.meta.ResolvedJavaType type,
jdk.internal.jvmci.meta.JavaTypeProfile profile)
Handle the parsing of a CHECKCAST bytecode.
|
default boolean |
handleInstanceOf(GraphBuilderContext b,
com.oracle.graal.nodes.ValueNode object,
jdk.internal.jvmci.meta.ResolvedJavaType type,
jdk.internal.jvmci.meta.JavaTypeProfile profile)
Handle the parsing of a INSTANCEOF bytecode.
|
default boolean |
handleInvoke(GraphBuilderContext b,
jdk.internal.jvmci.meta.ResolvedJavaMethod method,
com.oracle.graal.nodes.ValueNode[] args)
Handle the parsing of a method invocation bytecode to a method that can be bound statically.
|
default boolean |
handleLoadField(GraphBuilderContext b,
com.oracle.graal.nodes.ValueNode object,
jdk.internal.jvmci.meta.ResolvedJavaField field)
Handle the parsing of a GETFIELD bytecode.
|
default boolean |
handleLoadIndexed(GraphBuilderContext b,
com.oracle.graal.nodes.ValueNode array,
com.oracle.graal.nodes.ValueNode index,
jdk.internal.jvmci.meta.Kind elementKind)
Handle the parsing of an array load bytecode.
|
default boolean |
handleLoadStaticField(GraphBuilderContext b,
jdk.internal.jvmci.meta.ResolvedJavaField field)
Handle the parsing of a GETSTATIC bytecode.
|
default boolean |
handleStoreField(GraphBuilderContext b,
com.oracle.graal.nodes.ValueNode object,
jdk.internal.jvmci.meta.ResolvedJavaField field,
com.oracle.graal.nodes.ValueNode value)
Handle the parsing of a PUTFIELD bytecode.
|
default boolean |
handleStoreIndexed(GraphBuilderContext b,
com.oracle.graal.nodes.ValueNode array,
com.oracle.graal.nodes.ValueNode index,
jdk.internal.jvmci.meta.Kind elementKind,
com.oracle.graal.nodes.ValueNode value)
Handle the parsing of an array store bytecode.
|
default boolean |
handleStoreStaticField(GraphBuilderContext b,
jdk.internal.jvmci.meta.ResolvedJavaField field,
com.oracle.graal.nodes.ValueNode value)
Handle the parsing of a PUTSTATIC bytecode.
|
default boolean handleInvoke(GraphBuilderContext b, jdk.internal.jvmci.meta.ResolvedJavaMethod method, com.oracle.graal.nodes.ValueNode[] args)
push
a value as the
result of the method invocation using the return kind
of the
method.b
- the contextmethod
- the statically bound, invoked methodargs
- the arguments of the method invocationdefault boolean handleLoadField(GraphBuilderContext b, com.oracle.graal.nodes.ValueNode object, jdk.internal.jvmci.meta.ResolvedJavaField field)
push
a value using the kind
of the field.b
- the contextobject
- the receiver object for the field accessfield
- the accessed fielddefault boolean handleLoadStaticField(GraphBuilderContext b, jdk.internal.jvmci.meta.ResolvedJavaField field)
push
a value using the kind
of the field.b
- the contextfield
- the accessed fielddefault boolean handleStoreField(GraphBuilderContext b, com.oracle.graal.nodes.ValueNode object, jdk.internal.jvmci.meta.ResolvedJavaField field, com.oracle.graal.nodes.ValueNode value)
b
- the contextobject
- the receiver object for the field accessfield
- the accessed fieldvalue
- the value to be stored into the fielddefault boolean handleStoreStaticField(GraphBuilderContext b, jdk.internal.jvmci.meta.ResolvedJavaField field, com.oracle.graal.nodes.ValueNode value)
b
- the contextfield
- the accessed fieldvalue
- the value to be stored into the fielddefault boolean handleLoadIndexed(GraphBuilderContext b, com.oracle.graal.nodes.ValueNode array, com.oracle.graal.nodes.ValueNode index, jdk.internal.jvmci.meta.Kind elementKind)
push
a value using the provided elementKind.b
- the contextarray
- the accessed arrayindex
- the index for the array accesselementKind
- the element kind of the accessed arraydefault boolean handleStoreIndexed(GraphBuilderContext b, com.oracle.graal.nodes.ValueNode array, com.oracle.graal.nodes.ValueNode index, jdk.internal.jvmci.meta.Kind elementKind, com.oracle.graal.nodes.ValueNode value)
b
- the contextarray
- the accessed arrayindex
- the index for the array accesselementKind
- the element kind of the accessed arrayvalue
- the value to be stored into the arraydefault boolean handleCheckCast(GraphBuilderContext b, com.oracle.graal.nodes.ValueNode object, jdk.internal.jvmci.meta.ResolvedJavaType type, jdk.internal.jvmci.meta.JavaTypeProfile profile)
push
a value with the result of the cast using
Kind.Object
.b
- the contextobject
- the object to be type checkedtype
- the type that the object is checked againstprofile
- the profiling information for the type check, or null if no profiling
information is availabledefault boolean handleInstanceOf(GraphBuilderContext b, com.oracle.graal.nodes.ValueNode object, jdk.internal.jvmci.meta.ResolvedJavaType type, jdk.internal.jvmci.meta.JavaTypeProfile profile)
push
a value with the result of the instanceof using
Kind.Int
.b
- the contextobject
- the object to be type checkedtype
- the type that the object is checked againstprofile
- the profiling information for the type check, or null if no profiling
information is availabledefault boolean canChangeStackKind(GraphBuilderContext b)
pushes
a value with a different Kind
than specified by the bytecode, it must override this method and return true
. This
disables assertion checking for value kinds.b
- the context