changeset 23303:2d339ccb8de3

Exclude tracing in NFI calls in Truffle compilations
author Christian Wimmer <christian.wimmer@oracle.com>
date Tue, 12 Jan 2016 17:56:53 -0800
parents e3a4aa73dd8e
children 996bbeada100
files graal/com.oracle.graal.truffle.hotspot/src/com/oracle/graal/truffle/hotspot/nfi/HotSpotNativeFunctionHandle.java
diffstat 1 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.truffle.hotspot/src/com/oracle/graal/truffle/hotspot/nfi/HotSpotNativeFunctionHandle.java	Wed Jan 13 16:44:42 2016 +0100
+++ b/graal/com.oracle.graal.truffle.hotspot/src/com/oracle/graal/truffle/hotspot/nfi/HotSpotNativeFunctionHandle.java	Tue Jan 12 17:56:53 2016 -0800
@@ -68,9 +68,13 @@
     public Object call(Object... args) {
         assert checkArgs(args);
         try {
-            traceCall(args);
+            if (CompilerDirectives.inInterpreter()) {
+                traceCall(args);
+            }
             Object res = code.executeVarargs(args, null, null);
-            traceResult(res);
+            if (CompilerDirectives.inInterpreter()) {
+                traceResult(res);
+            }
             return res;
         } catch (InvalidInstalledCodeException e) {
             CompilerDirectives.transferToInterpreter();