comparison truffle/com.oracle.truffle.api/src/com/oracle/truffle/api/nodes/RootNode.java @ 22245:c1f9d1ea057c

Truffle/Instrumentation: remove an indirection in a call from RootNode to having instrumentation applied.
author Michael Van De Vanter <michael.van.de.vanter@oracle.com>
date Wed, 23 Sep 2015 17:23:57 -0700
parents f78c72e2e0b6
children 0fb3522e5b72
comparison
equal deleted inserted replaced
22244:3c73d029b651 22245:c1f9d1ea057c
158 * the correct <code>ExecutionContext</code> to be determined for a <code>RootNode</code> (and 158 * the correct <code>ExecutionContext</code> to be determined for a <code>RootNode</code> (and
159 * so also for a {@link RootCallTarget} and a {@link FrameInstance} obtained from the call 159 * so also for a {@link RootCallTarget} and a {@link FrameInstance} obtained from the call
160 * stack) without prior knowledge of the language it has come from. 160 * stack) without prior knowledge of the language it has come from.
161 * 161 *
162 * Used for instance to determine the language of a <code>RootNode<code>: 162 * Used for instance to determine the language of a <code>RootNode<code>:
163 * 163 *
164 * <pre> 164 * <pre>
165 * <code> 165 * <code>
166 * rootNode.getExecutionContext().getLanguageShortName(); 166 * rootNode.getExecutionContext().getLanguageShortName();
167 * </code> </pre> 167 * </code> </pre>
168 * 168 *
184 return context.getCompilerOptions(); 184 return context.getCompilerOptions();
185 } 185 }
186 } 186 }
187 187
188 public final void applyInstrumentation() { 188 public final void applyInstrumentation() {
189 super.probeAST(this); 189 Node.ACCESSOR.probeAST(this);
190 } 190 }
191 191
192 /** 192 /**
193 * Helper method to create a root node that always returns the same value. Certain operations 193 * Helper method to create a root node that always returns the same value. Certain operations
194 * (especially {@link com.oracle.truffle.api.interop inter-operability} API) require return of 194 * (especially {@link com.oracle.truffle.api.interop inter-operability} API) require return of