Top Description Methods
jdk.vm.ci.code.stack

public Interface InspectedFrame

Known Direct Implementers
jdk.vm.ci.hotspot.HotSpotStackFrameReference
Imports
jdk.vm.ci.meta.ResolvedJavaMethod

Access to the object variables in a stack frame.

Method Summary

Modifier and TypeMethod and Description
public int

Returns:

the current bytecode index
getBytecodeIndex
()

public Object
getLocal(int index)

Returns the value of the object local at index.

public ResolvedJavaMethod

Returns:

the current method
getMethod
()

public boolean
hasVirtualObjects()

Returns true if the stack frame is a compiled stack frame and there are virtual objects anywhere in the current state of the compiled method.

public boolean
isMethod(ResolvedJavaMethod method)

Checks if the current method is equal to the given method.

public boolean
isVirtual(int index)

Returns whether the local at index is a virtual object, and therefore the object returned by getLocal(int) is a copy.

public void
materializeVirtualObjects(boolean invalidateCode)

This method will materialize all virtual objects, deoptimize the stack frame and make sure that subsequent execution of the deoptimized frame uses the materialized values.

Method Detail

getBytecodeIndexback to summary
public int getBytecodeIndex()
Returns:int

the current bytecode index

getLocalback to summary
public Object getLocal(int index)

Returns the value of the object local at index. This value is a copy iff isVirtual(int) is true.

getMethodback to summary
public ResolvedJavaMethod getMethod()
Returns:ResolvedJavaMethod

the current method

hasVirtualObjectsback to summary
public boolean hasVirtualObjects()

Returns true if the stack frame is a compiled stack frame and there are virtual objects anywhere in the current state of the compiled method. This can return true even if isVirtual(int) return false for all locals.

isMethodback to summary
public boolean isMethod(ResolvedJavaMethod method)

Checks if the current method is equal to the given method. This is semantically equivalent to method.equals(getMethod()), but can be implemented more efficiently.

isVirtualback to summary
public boolean isVirtual(int index)

Returns whether the local at index is a virtual object, and therefore the object returned by getLocal(int) is a copy.

materializeVirtualObjectsback to summary
public void materializeVirtualObjects(boolean invalidateCode)

This method will materialize all virtual objects, deoptimize the stack frame and make sure that subsequent execution of the deoptimized frame uses the materialized values.

Exceptions
IllegalArgumentException:
if stack introspection does not support materialization of virtual objects for this frame
See Also
StackIntrospection#canMaterializeVirtualObjects