Mercurial > hg > truffle
changeset 5137:09f66048738e
Added new decorate methods to the Debug class.
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Wed, 21 Mar 2012 13:49:34 +0100 |
parents | 8f4f0ebffca2 |
children | 4d8ebb0fc484 |
files | graal/com.oracle.graal.debug/src/com/oracle/graal/debug/Debug.java graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompilationTask.java graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/VMToCompilerImpl.java |
diffstat | 3 files changed, 17 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.debug/src/com/oracle/graal/debug/Debug.java Wed Mar 21 13:13:47 2012 +0100 +++ b/graal/com.oracle.graal.debug/src/com/oracle/graal/debug/Debug.java Wed Mar 21 13:49:34 2012 +0100 @@ -55,6 +55,22 @@ return ENABLED && DebugScope.getInstance().isLogEnabled(); } + public static Runnable decorateDebugRoot(Runnable runnable, String name, DebugConfig config) { + return runnable; + } + + public static <T> Callable<T> decorateDebugRoot(Callable<T> callable, String name, DebugConfig config) { + return callable; + } + + public static Runnable decorateScope(Runnable runnable, String name, Object... context) { + return runnable; + } + + public static <T> Callable<T> decorateScope(Callable<T> callable, String name, Object... context) { + return callable; + } + public static void sandbox(String name, Runnable runnable) { if (ENABLED) { DebugScope.getInstance().scope(name, runnable, null, true, new Object[0]);
--- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompilationTask.java Wed Mar 21 13:13:47 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompilationTask.java Wed Mar 21 13:49:34 2012 +0100 @@ -28,7 +28,6 @@ import com.oracle.graal.compiler.phases.*; import com.oracle.graal.compiler.phases.PhasePlan.*; import com.oracle.graal.debug.*; -import com.oracle.graal.hotspot.snippets.*; import com.oracle.graal.java.*; import com.oracle.max.cri.ci.*; import com.oracle.max.cri.ri.*;
--- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/VMToCompilerImpl.java Wed Mar 21 13:13:47 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/VMToCompilerImpl.java Wed Mar 21 13:49:34 2012 +0100 @@ -40,7 +40,6 @@ import com.oracle.graal.hotspot.ri.*; import com.oracle.graal.hotspot.server.*; import com.oracle.graal.hotspot.snippets.*; -import com.oracle.graal.java.*; import com.oracle.graal.snippets.*; /** @@ -276,7 +275,7 @@ } } - CompilationTask task = CompilationTask.create(compiler, getDefaultPhasePlan(), method); + Runnable task = CompilationTask.create(compiler, getDefaultPhasePlan(), method); if (blocking) { task.run(); } else {