public class SubstrateInstalledCodeImpl extends jdk.vm.ci.code.InstalledCode implements SubstrateInstalledCode
SubstrateInstalledCode
, so no code within Substrate VM must assume that
this is the only representation of runtime compiled code.
Metadata for the code is maintained by the class CodeInfo
.SubstrateInstalledCode.Factory
Constructor and Description |
---|
SubstrateInstalledCodeImpl(SharedRuntimeMethod method) |
SubstrateInstalledCodeImpl(String name,
SharedRuntimeMethod method) |
Modifier and Type | Method and Description |
---|---|
void |
clearAddress()
This method is called during code uninstallation.
|
Object |
executeVarargs(Object... args) |
byte[] |
getCode() |
jdk.vm.ci.meta.ResolvedJavaMethod |
getMethod()
Returns the last method object passed to
SubstrateInstalledCode.setAddress(long, jdk.vm.ci.meta.ResolvedJavaMethod) . |
SubstrateSpeculationLog |
getSpeculationLog() |
long |
getStart() |
void |
invalidate()
Invalidates this installed code and deoptimizes all live invocations, after which both
SubstrateInstalledCode.isValid() and SubstrateInstalledCode.isAlive() return false . |
void |
invalidateWithoutDeoptimization()
Currently not supported.
|
void |
setAddress(long address,
jdk.vm.ci.meta.ResolvedJavaMethod method)
Called during code installation: initialize this instance with the given address where its
instructions are, and the method it was compiled from.
|
void |
setCompilationId(org.graalvm.compiler.core.common.CompilationIdentifier id)
Sets the identifier of the compilation that resulted in this code, which can be used to
provide additional information in
SubstrateInstalledCode.getName() . |
getAddress, getEntryPoint, getName, getVersion, isAlive, isValid
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getAddress, getEntryPoint, getName, isAlive, isValid
public SubstrateInstalledCodeImpl(SharedRuntimeMethod method)
public SubstrateInstalledCodeImpl(String name, SharedRuntimeMethod method)
public jdk.vm.ci.meta.ResolvedJavaMethod getMethod()
SubstrateInstalledCode
SubstrateInstalledCode.setAddress(long, jdk.vm.ci.meta.ResolvedJavaMethod)
. The return value might be
passed as the argument to future calls to SubstrateInstalledCode.setAddress(long, jdk.vm.ci.meta.ResolvedJavaMethod)
.
May return null
if the subclass does not have a use for the method object (also not
in SubstrateInstalledCode.setAddress(long, jdk.vm.ci.meta.ResolvedJavaMethod)
) and therefore no need to retain it. Expected to return null
if SubstrateInstalledCode.setAddress(long, jdk.vm.ci.meta.ResolvedJavaMethod)
has never been called, or after SubstrateInstalledCode.clearAddress()
has been called.
getMethod
in interface SubstrateInstalledCode
public void setAddress(long address, jdk.vm.ci.meta.ResolvedJavaMethod method)
SubstrateInstalledCode
SubstrateInstalledCode.getAddress()
and
SubstrateInstalledCode.getEntryPoint()
return the given address, and SubstrateInstalledCode.isValid()
and
SubstrateInstalledCode.isAlive()
return true
.setAddress
in interface SubstrateInstalledCode
public void clearAddress()
SubstrateInstalledCode
SubstrateInstalledCode.invalidate()
instead.
Reset this instance so that SubstrateInstalledCode.getAddress()
and SubstrateInstalledCode.getEntryPoint()
return 0, and
SubstrateInstalledCode.isValid()
and SubstrateInstalledCode.isAlive()
return false
.
clearAddress
in interface SubstrateInstalledCode
public void invalidate()
SubstrateInstalledCode
SubstrateInstalledCode.isValid()
and SubstrateInstalledCode.isAlive()
return false
.invalidate
in interface SubstrateInstalledCode
invalidate
in class jdk.vm.ci.code.InstalledCode
public void invalidateWithoutDeoptimization()
InstalledCode.entryPoint
(such as, at the end of
InstalledCode.getEntryPoint()
), and the invocation of the entry point that was read.invalidateWithoutDeoptimization
in interface SubstrateInstalledCode
public SubstrateSpeculationLog getSpeculationLog()
getSpeculationLog
in interface SubstrateInstalledCode
public void setCompilationId(org.graalvm.compiler.core.common.CompilationIdentifier id)
SubstrateInstalledCode
SubstrateInstalledCode.getName()
.setCompilationId
in interface SubstrateInstalledCode
public long getStart()
getStart
in class jdk.vm.ci.code.InstalledCode
public byte[] getCode()
getCode
in class jdk.vm.ci.code.InstalledCode