# HG changeset patch # User Gilles Duboscq # Date 1304326595 -7200 # Node ID 95a9b8906b09e3639802f6fde45dfec82f3eec54 # Parent b96f9fcc53b1c8d1ecd48dedec6ca968f1df877d Add QuietBailout option to be able to mute the bailouts generated by JSRs in dacapo diff -r b96f9fcc53b1 -r 95a9b8906b09 graal/GraalCompiler/src/com/sun/c1x/C1XOptions.java --- a/graal/GraalCompiler/src/com/sun/c1x/C1XOptions.java Mon May 02 10:24:43 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/C1XOptions.java Mon May 02 10:56:35 2011 +0200 @@ -83,6 +83,7 @@ public static boolean TraceAssembler = ____; public static int TraceBytecodeParserLevel = 0; public static boolean PrintAssumptions = ____; + public static boolean QuietBailout = ____; // all optimization settings public static boolean OptLocalValueNumbering; diff -r b96f9fcc53b1 -r 95a9b8906b09 graal/GraalRuntime/src/com/oracle/graal/runtime/VMExitsNative.java --- a/graal/GraalRuntime/src/com/oracle/graal/runtime/VMExitsNative.java Mon May 02 10:24:43 2011 +0200 +++ b/graal/GraalRuntime/src/com/oracle/graal/runtime/VMExitsNative.java Mon May 02 10:56:35 2011 +0200 @@ -28,6 +28,7 @@ import com.oracle.graal.runtime.logging.*; import com.oracle.graal.runtime.server.*; +import com.sun.c1x.*; import com.sun.c1x.debug.*; import com.sun.cri.ci.*; import com.sun.cri.ri.*; @@ -83,19 +84,21 @@ } if (result.bailout() != null) { - StringWriter out = new StringWriter(); - result.bailout().printStackTrace(new PrintWriter(out)); Throwable cause = result.bailout().getCause(); - TTY.println("Bailout:\n" + out.toString()); - if (cause != null) { - Logger.info("Trace for cause: "); - for (StackTraceElement e : cause.getStackTrace()) { - String current = e.getClassName() + "::" + e.getMethodName(); - String type = ""; - if (compiledMethods.contains(current)) { - type = "compiled"; + if(!C1XOptions.QuietBailout) { + StringWriter out = new StringWriter(); + result.bailout().printStackTrace(new PrintWriter(out)); + TTY.println("Bailout:\n" + out.toString()); + if (cause != null) { + Logger.info("Trace for cause: "); + for (StackTraceElement e : cause.getStackTrace()) { + String current = e.getClassName() + "::" + e.getMethodName(); + String type = ""; + if (compiledMethods.contains(current)) { + type = "compiled"; + } + Logger.info(String.format("%-10s %3d %s", type, e.getLineNumber(), current)); } - Logger.info(String.format("%-10s %3d %s", type, e.getLineNumber(), current)); } } String s = result.bailout().getMessage(); diff -r b96f9fcc53b1 -r 95a9b8906b09 rundacapo.sh --- a/rundacapo.sh Mon May 02 10:24:43 2011 +0200 +++ b/rundacapo.sh Mon May 02 10:56:35 2011 +0200 @@ -15,4 +15,4 @@ echo "DACAPO is not defined. It must point to a SciMark benchmark directory." exit 1; fi -${JDK7}/bin/java -client -graal -XX:-C1XBailoutIsFatal -Xms1g -Xmx2g -esa -classpath ${DACAPO}/dacapo-9.12-bach.jar Harness $* +${JDK7}/bin/java -client -graal -XX:-C1XBailoutIsFatal -C1X:+QuietBailout -Xms1g -Xmx2g -esa -classpath ${DACAPO}/dacapo-9.12-bach.jar Harness $*