public DirectDispatchNode(DispatchNode next, CallTarget callTarget) { this.cachedCallTarget = callTarget; this.callCachedTargetNode = Truffle.getRuntime().createDirectCallNode( this.cachedCallTarget); this.nextNode = next; }
/** @since 0.8 or earlier */ public static DirectCallNode create(CallTarget target) { return Truffle.getRuntime().createDirectCallNode(target); }
public static DirectCallNode create(CallTarget target) { return Truffle.getRuntime().createDirectCallNode(target); }
/** @since 0.8 or earlier */ public static DirectCallNode create(CallTarget target) { return Truffle.getRuntime().createDirectCallNode(target); }
public LuaDirectDispatchNode(LuaAbstractDispatchNode next, LuaFunction cachedFunction) { this.cachedMethod = cachedFunction; this.callCachedTargetNode = Truffle.getRuntime().createDirectCallNode(cachedFunction.getCallTarget()); this.cachedTargetStable = cachedFunction.getCallTargetStable(); this.nextNode = next; }
private static CachedObjectAccessNode createCachedAccess(TruffleObject receiver, Message accessTree, ObjectAccessNode next) { ForeignAccessFactory accessFactory = receiver.getForeignAccessFactory(); return new CachedObjectAccessNode(Truffle.getRuntime().createDirectCallNode(accessFactory.getAccess(accessTree)), next, accessFactory.getLanguageCheck()); }
private void initializeConditional(MaterializedFrame frame) { Node instrumentedNode = context.getInstrumentedNode(); final RootNode rootNode = instrumentedNode.getRootNode(); if (rootNode == null) { throw new IllegalStateException("Probe was disconnected from the AST."); } Source instrumentedSource = context.getInstrumentedSourceSection().getSource(); Source conditionSource; synchronized (breakpoint) { conditionSource = Source.newBuilder(instrumentedSource.getLanguage(), breakpoint.condition, "breakpoint condition").mimeType(instrumentedSource.getMimeType()).build(); if (conditionSource == null) { throw new IllegalStateException("Condition is not resolved " + rootNode); } conditionUnchanged = breakpoint.getConditionUnchanged(); } ExecutableNode snippet = breakpoint.debugger.getEnv().parseInline(conditionSource, instrumentedNode, frame); if (snippet != null) { conditionSnippet = insert(snippet); notifyInserted(snippet); } else { CallTarget callTarget = Debugger.ACCESSOR.parse(conditionSource, instrumentedNode, new String[0]); conditionCallNode = insert(Truffle.getRuntime().createDirectCallNode(callTarget)); } } }
private void initializeConditional(MaterializedFrame frame) { Node instrumentedNode = context.getInstrumentedNode(); final RootNode rootNode = instrumentedNode.getRootNode(); if (rootNode == null) { throw new IllegalStateException("Probe was disconnected from the AST."); } Source instrumentedSource = context.getInstrumentedSourceSection().getSource(); Source conditionSource; synchronized (breakpoint) { conditionSource = Source.newBuilder(breakpoint.condition).language(instrumentedSource.getLanguage()).mimeType(instrumentedSource.getMimeType()).name( "breakpoint condition").build(); if (conditionSource == null) { throw new IllegalStateException("Condition is not resolved " + rootNode); } conditionUnchanged = breakpoint.getConditionUnchanged(); } ExecutableNode snippet = breakpoint.debugger.getEnv().parseInline(conditionSource, instrumentedNode, frame); if (snippet != null) { conditionSnippet = insert(snippet); notifyInserted(snippet); } else { CallTarget callTarget = Debugger.ACCESSOR.parse(conditionSource, instrumentedNode, new String[0]); conditionCallNode = insert(Truffle.getRuntime().createDirectCallNode(callTarget)); } } }