public abstract class AnalysisMethod extends AnalysisElement implements WrappedJavaMethod, GraphProvider, OriginalMethodProvider
AnalysisElement.ElementReachableNotification, AnalysisElement.MethodOverrideReachableNotification, AnalysisElement.SubtypeReachableNotificationGraphProvider.Purpose| Modifier and Type | Field and Description |
|---|---|
protected AnalysisMethod[] |
implementations
All concrete methods that can actually be called when calling this method.
|
ResolvedJavaMethod |
wrapped |
| Constructor and Description |
|---|
AnalysisMethod(AnalysisUniverse universe,
ResolvedJavaMethod wrapped) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
allowRuntimeCompilation()
Returns true if a graph can be provided for
GraphProvider.Purpose.PREPARE_RUNTIME_COMPILATION. |
StackTraceElement |
asStackTraceElement(int bci) |
org.graalvm.compiler.nodes.StructuredGraph |
buildGraph(org.graalvm.compiler.debug.DebugContext debug,
ResolvedJavaMethod method,
HostedProviders providers,
GraphProvider.Purpose purpose) |
boolean |
canBeInlined() |
boolean |
canBeStaticallyBound() |
void |
cleanupAfterAnalysis() |
org.graalvm.compiler.nodes.StructuredGraph |
decodeAnalyzedGraph(org.graalvm.compiler.debug.DebugContext debug,
Iterable<org.graalvm.compiler.nodes.EncodedGraph.EncodedNodeReference> nodeReferences)
Returns the
Graal IR for the method that has been processed by the
static analysis. |
AnalysisParsedGraph |
ensureGraphParsed(BigBang bb)
Ensures that the method has been parsed, i.e., that the
Graal IR for
the method is available. |
boolean |
equals(Object obj) |
Set<AnalysisMethod> |
getCallers()
Get the set of all callers for this method, as inferred by the static analysis.
|
byte[] |
getCode() |
int |
getCodeSize() |
ConstantPool |
getConstantPool() |
AnalysisType |
getDeclaringClass() |
jdk.vm.ci.meta.Constant |
getEncoding() |
Object |
getEntryPointData() |
ExceptionHandler[] |
getExceptionHandlers() |
Type[] |
getGenericParameterTypes() |
int |
getId() |
AnalysisMethod[] |
getImplementations() |
abstract List<jdk.vm.ci.code.BytecodePosition> |
getInvokeLocations()
Get the list of all invoke locations for this method, as inferred by the static analysis.
|
abstract Iterable<? extends InvokeInfo> |
getInvokes() |
Executable |
getJavaMethod() |
LineNumberTable |
getLineNumberTable() |
LocalVariableTable |
getLocalVariableTable() |
int |
getMaxLocals() |
int |
getMaxStackSize() |
int |
getModifiers() |
String |
getName() |
Annotation[][] |
getParameterAnnotations() |
Parameter[] |
getParameters() |
abstract StackTraceElement[] |
getParsingContext() |
ProfilingInfo |
getProfilingInfo(boolean includeNormal,
boolean includeOSR) |
String |
getQualifiedName() |
WrappedSignature |
getSignature() |
SpeculationLog |
getSpeculationLog() |
ResolvedJavaMethod |
getWrapped() |
int |
hashCode() |
boolean |
hasNeverInlineDirective() |
boolean |
isBridge() |
boolean |
isClassInitializer() |
boolean |
isConstructor() |
boolean |
isDefault() |
boolean |
isDirectRootMethod()
Returns true if the method is marked as direct root.
|
boolean |
isEntryPoint() |
boolean |
isImplementationInvoked()
Returns true if the method body can ever be executed.
|
boolean |
isIntrinsicMethod() |
boolean |
isInVirtualMethodTable(ResolvedJavaType resolved) |
boolean |
isInvoked()
Returns true if this method is ever used as the target of a call site.
|
boolean |
isReachable() |
boolean |
isSimplyImplementationInvoked() |
boolean |
isSimplyInvoked() |
boolean |
isSynthetic() |
boolean |
isTriggered()
Return true if reachability handlers should be executed for this element.
|
boolean |
isVarArgs() |
boolean |
isVirtualRootMethod()
Returns true if the method is marked as virtual root.
|
protected void |
notifyMethodOverride(AnalysisMethod override) |
void |
onReachable() |
boolean |
registerAsDirectRootMethod()
Registers this method as a direct (special or static) root for the analysis.
|
void |
registerAsEntryPoint(Object newEntryPointData) |
boolean |
registerAsImplementationInvoked() |
void |
registerAsInlined() |
void |
registerAsIntrinsicMethod()
Registers this method as intrinsified to Graal nodes via a
graph
builder plugin. |
boolean |
registerAsInvoked() |
boolean |
registerAsVirtualRootMethod()
Registers this method as a virtual root for the analysis.
|
void |
registerOverrideReachabilityNotification(AnalysisElement.MethodOverrideReachableNotification notification) |
void |
reprofile() |
protected AnalysisMethod |
resolveInType(AnalysisType holder)
Resolves this method in the provided type, but only if the type or any of its subtypes is
marked as instantiated.
|
protected AnalysisMethod |
resolveInType(AnalysisType holder,
boolean holderOrSubtypeInstantiated) |
void |
setAnalyzedGraph(org.graalvm.compiler.nodes.EncodedGraph analyzedGraph) |
boolean |
shouldBeInlined() |
abstract void |
startTrackInvocations() |
String |
toString() |
notifyReachabilityCallback, notifyReachabilityCallbacks, registerReachabilityNotificationgetAnnotationRootgetAnnotation, getAnnotations, getDeclaredAnnotation, getDeclaredAnnotations, getIgnoredAnnotations, getInjectedAnnotations, getSecondaryAnnotationRoot, isAnnotationPresentgetAnnotationsByType, getDeclaredAnnotationsByTypegetJavaMethodpublic final ResolvedJavaMethod wrapped
protected AnalysisMethod[] implementations
public AnalysisMethod(AnalysisUniverse universe, ResolvedJavaMethod wrapped)
public String getQualifiedName()
public void cleanupAfterAnalysis()
public abstract void startTrackInvocations()
public abstract Iterable<? extends InvokeInfo> getInvokes()
public abstract StackTraceElement[] getParsingContext()
public int getId()
public void registerAsIntrinsicMethod()
graph
builder plugin. Such a method is treated similar to an invoked method. For example, method
resolution must be able to find the method (otherwise the intrinsification would not work).public void registerAsEntryPoint(Object newEntryPointData)
public boolean registerAsInvoked()
public boolean registerAsImplementationInvoked()
public void registerAsInlined()
public Set<AnalysisMethod> getCallers()
public abstract List<jdk.vm.ci.code.BytecodePosition> getInvokeLocations()
public boolean isEntryPoint()
public Object getEntryPointData()
public boolean isIntrinsicMethod()
public boolean registerAsVirtualRootMethod()
AnalysisMethod.registerAsImplementationInvoked().public boolean registerAsDirectRootMethod()
public boolean isVirtualRootMethod()
public boolean isDirectRootMethod()
public boolean isSimplyInvoked()
public boolean isSimplyImplementationInvoked()
public boolean isInvoked()
public boolean isImplementationInvoked()
public boolean isReachable()
isReachable in class AnalysisElementpublic boolean isTriggered()
AnalysisElementisTriggered in class AnalysisElementpublic void onReachable()
onReachable in class AnalysisElementprotected void notifyMethodOverride(AnalysisMethod override)
public void registerOverrideReachabilityNotification(AnalysisElement.MethodOverrideReachableNotification notification)
protected AnalysisMethod resolveInType(AnalysisType holder)
protected AnalysisMethod resolveInType(AnalysisType holder, boolean holderOrSubtypeInstantiated)
public ResolvedJavaMethod getWrapped()
getWrapped in interface WrappedElementgetWrapped in interface WrappedJavaMethodpublic String getName()
public WrappedSignature getSignature()
public org.graalvm.compiler.nodes.StructuredGraph buildGraph(org.graalvm.compiler.debug.DebugContext debug,
ResolvedJavaMethod method,
HostedProviders providers,
GraphProvider.Purpose purpose)
buildGraph in interface GraphProviderpublic boolean allowRuntimeCompilation()
GraphProviderGraphProvider.Purpose.PREPARE_RUNTIME_COMPILATION. Note
that a manually generated graph must be able to provide the proper deoptimization entry
points and deoptimization frame states.allowRuntimeCompilation in interface GraphProviderpublic byte[] getCode()
public int getCodeSize()
public AnalysisType getDeclaringClass()
public int getMaxLocals()
public int getMaxStackSize()
public Parameter[] getParameters()
public int getModifiers()
public boolean isSynthetic()
public boolean isVarArgs()
public boolean isBridge()
public boolean isClassInitializer()
public boolean isConstructor()
public boolean canBeStaticallyBound()
public AnalysisMethod[] getImplementations()
public ExceptionHandler[] getExceptionHandlers()
public StackTraceElement asStackTraceElement(int bci)
public ProfilingInfo getProfilingInfo(boolean includeNormal,
boolean includeOSR)
public ConstantPool getConstantPool()
public Annotation[][] getParameterAnnotations()
public Type[] getGenericParameterTypes()
public boolean canBeInlined()
public boolean hasNeverInlineDirective()
public boolean shouldBeInlined()
public LineNumberTable getLineNumberTable()
public LocalVariableTable getLocalVariableTable()
public void reprofile()
public jdk.vm.ci.meta.Constant getEncoding()
public boolean isInVirtualMethodTable(ResolvedJavaType resolved)
public boolean isDefault()
public SpeculationLog getSpeculationLog()
public Executable getJavaMethod()
getJavaMethod in interface OriginalMethodProviderpublic AnalysisParsedGraph ensureGraphParsed(BigBang bb)
Graal IR for
the method is available.public org.graalvm.compiler.nodes.StructuredGraph decodeAnalyzedGraph(org.graalvm.compiler.debug.DebugContext debug,
Iterable<org.graalvm.compiler.nodes.EncodedGraph.EncodedNodeReference> nodeReferences)
Graal IR for the method that has been processed by the
static analysis.public void setAnalyzedGraph(org.graalvm.compiler.nodes.EncodedGraph analyzedGraph)