Class BaseOSRRootNode
java.lang.Object
com.oracle.truffle.api.nodes.Node
com.oracle.truffle.api.nodes.ExecutableNode
com.oracle.truffle.api.nodes.RootNode
com.oracle.truffle.runtime.BaseOSRRootNode
- All Implemented Interfaces:
com.oracle.truffle.api.nodes.NodeInterface, Cloneable
public abstract class BaseOSRRootNode
extends com.oracle.truffle.api.nodes.RootNode
Base class for on-stack replaced (OSR) root nodes.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.oracle.truffle.api.nodes.Node
com.oracle.truffle.api.nodes.Node.Child, com.oracle.truffle.api.nodes.Node.Children -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.oracle.truffle.api.nodes.NodeInterfaceNot adopted by the OSRRootNode; belongs to another RootNode. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedBaseOSRRootNode(com.oracle.truffle.api.TruffleLanguage<?> language, com.oracle.truffle.api.frame.FrameDescriptor frameDescriptor, com.oracle.truffle.api.nodes.NodeInterface loopNode) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanfinal Objectexecute(com.oracle.truffle.api.frame.VirtualFrame frame) protected abstract ObjectexecuteOSR(com.oracle.truffle.api.frame.VirtualFrame frame) Entrypoint for OSR root nodes.protected com.oracle.truffle.api.frame.VirtualFramegetFrame(com.oracle.truffle.api.frame.VirtualFrame frame) Returns the effective execution frame for this OSR root.protected booleanisCaptureFramesForTrace(boolean compiledFrame) protected final booleanprepareForCompilation(boolean rootCompilation, int compilationTier, boolean lastTier) Methods inherited from class com.oracle.truffle.api.nodes.RootNode
cloneUninitialized, computeSize, copy, createConstantNode, findAsynchronousFrames, findBytecodeIndex, findInstrumentableCallNode, getCallTarget, getFrameDescriptor, getName, getParentFrameDescriptor, getQualifiedName, isCaptureFramesForTrace, isCaptureFramesForTrace, isCloneUninitializedSupported, isCloningAllowed, isInstrumentable, isInternal, isSameFrame, isTrivial, prepareForAOT, prepareForCall, prepareForInstrumentation, translateStackTraceElementMethods inherited from class com.oracle.truffle.api.nodes.ExecutableNode
getLanguage, getLanguageInfoMethods inherited from class com.oracle.truffle.api.nodes.Node
accept, adoptChildren, atomic, atomic, deepCopy, getChildren, getCost, getDebugProperties, getDescription, getEncapsulatingSourceSection, getLock, getParent, getRootNode, getSourceSection, insert, insert, isAdoptable, isSafelyReplaceableBy, notifyInserted, onReplace, replace, replace, reportPolymorphicSpecialize, reportReplace, toString
-
Field Details
-
loopNode
protected com.oracle.truffle.api.nodes.NodeInterface loopNodeNot adopted by the OSRRootNode; belongs to another RootNode. OptimizedCallTarget treats OSRRootNodes specially, skipping adoption of child nodes. This loop node instance is also used by the compiler to find the real root node e.g. for the truffle guest safepoint location. See TruffleSafepointInsertionPhase#skipOSRRoot.
-
-
Constructor Details
-
BaseOSRRootNode
protected BaseOSRRootNode(com.oracle.truffle.api.TruffleLanguage<?> language, com.oracle.truffle.api.frame.FrameDescriptor frameDescriptor, com.oracle.truffle.api.nodes.NodeInterface loopNode)
-
-
Method Details
-
execute
- Specified by:
executein classcom.oracle.truffle.api.nodes.RootNode
-
prepareForCompilation
protected final boolean prepareForCompilation(boolean rootCompilation, int compilationTier, boolean lastTier) - Overrides:
prepareForCompilationin classcom.oracle.truffle.api.nodes.RootNode
-
isCaptureFramesForTrace
protected boolean isCaptureFramesForTrace(boolean compiledFrame) - Overrides:
isCaptureFramesForTracein classcom.oracle.truffle.api.nodes.RootNode
-
countsTowardsStackTraceLimit
protected boolean countsTowardsStackTraceLimit()- Overrides:
countsTowardsStackTraceLimitin classcom.oracle.truffle.api.nodes.RootNode
-
getFrame
protected com.oracle.truffle.api.frame.VirtualFrame getFrame(com.oracle.truffle.api.frame.VirtualFrame frame) Returns the effective execution frame for this OSR root.The frame passed to
execute(VirtualFrame)may differ from the frame used byexecuteOSR(VirtualFrame)to execute guest code. The returned frame is used for operations that should reflect the effective execution frame, such as attaching lazy exception stack trace information. -
executeOSR
Entrypoint for OSR root nodes.
-