public class JNICallTrampolineMethod extends CustomSubstitutionMethod
NativeType CallStatic
The jmethodID
values that we pass out are the addresses of JNIAccessibleMethod
objects, which are made immutable so that they are never moved by the garbage collector. The
trampoline simply jumps to the address of a specific call wrapper that is stored in a
field
of the object. The wrappers then take care of spilling
callee-saved registers, transitioning from native to Java and back, obtaining the arguments in a
particular form (varargs, array, va_list) and boxing/unboxing object handles as necessary.
original
Constructor and Description |
---|
JNICallTrampolineMethod(jdk.vm.ci.meta.ResolvedJavaMethod original,
jdk.vm.ci.meta.ResolvedJavaField callWrapperField,
boolean nonVirtual) |
Modifier and Type | Method and Description |
---|---|
org.graalvm.compiler.nodes.StructuredGraph |
buildGraph(org.graalvm.compiler.debug.DebugContext debug,
jdk.vm.ci.meta.ResolvedJavaMethod method,
com.oracle.graal.pointsto.meta.HostedProviders providers,
com.oracle.graal.pointsto.infrastructure.GraphProvider.Purpose purpose) |
CompileQueue.CompileFunction |
createCustomCompileFunction() |
CompileQueue.ParseFunction |
createCustomParseFunction() |
int |
getModifiers() |
allowRuntimeCompilation, asStackTraceElement, canBeInlined, canBeStaticallyBound, getAnnotation, getAnnotations, getCode, getCodeSize, getConstantPool, getDeclaredAnnotations, getDeclaringClass, getEncoding, getExceptionHandlers, getGenericParameterTypes, getJavaMethod, getLineNumberTable, getLocalVariableTable, getMaxLocals, getMaxStackSize, getName, getOriginal, getParameterAnnotations, getParameters, getProfilingInfo, getSignature, getSpeculationLog, hasNeverInlineDirective, isBridge, isClassInitializer, isConstructor, isDefault, isInVirtualMethodTable, isSynthetic, isVarArgs, reprofile, shouldBeInlined
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getParameterAnnotation, getParameterAnnotations, getProfilingInfo, hasBytecodes, hasReceiver, isFinal, isJavaLangObjectInit, toParameterTypes
isAbstract, isConcrete, isFinalFlagSet, isInterface, isNative, isPackagePrivate, isPrivate, isProtected, isPublic, isStatic, isStrict, isSynchronized, isTransient, isVolatile
getAnnotationsByType, getDeclaredAnnotation, getDeclaredAnnotationsByType, isAnnotationPresent
public JNICallTrampolineMethod(jdk.vm.ci.meta.ResolvedJavaMethod original, jdk.vm.ci.meta.ResolvedJavaField callWrapperField, boolean nonVirtual)
public int getModifiers()
getModifiers
in interface jdk.vm.ci.meta.ModifiersProvider
getModifiers
in class CustomSubstitutionMethod
public org.graalvm.compiler.nodes.StructuredGraph buildGraph(org.graalvm.compiler.debug.DebugContext debug, jdk.vm.ci.meta.ResolvedJavaMethod method, com.oracle.graal.pointsto.meta.HostedProviders providers, com.oracle.graal.pointsto.infrastructure.GraphProvider.Purpose purpose)
public CompileQueue.ParseFunction createCustomParseFunction()
public CompileQueue.CompileFunction createCustomCompileFunction()