Mercurial > hg > truffle
changeset 6963:dd0dd0321e2a
throw BailoutException instead of GraalInternalError when encountering request for OSR compilation at a point where the expression stack is not empty
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Sun, 18 Nov 2012 22:45:43 +0100 |
parents | e9f69041ac38 |
children | 2cb439954abf e35077f6d2a2 |
files | graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompilationTask.java graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/phases/OnStackReplacementPhase.java |
diffstat | 2 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompilationTask.java Sun Nov 18 21:30:35 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/CompilationTask.java Sun Nov 18 22:45:43 2012 +0100 @@ -115,7 +115,7 @@ try { final boolean printCompilation = GraalOptions.PrintCompilation && !TTY.isSuppressed(); if (printCompilation) { - TTY.println(String.format("%-6d Graal %-70s %-45s %-50s %s...", id, method.getDeclaringClass().getName(), method.getName(), method.getSignature(), entryBCI == StructuredGraph.INVOCATION_ENTRY_BCI ? "" : "(OSR) ")); + TTY.println(String.format("%-6d Graal %-70s %-45s %-50s %s...", id, method.getDeclaringClass().getName(), method.getName(), method.getSignature(), entryBCI == StructuredGraph.INVOCATION_ENTRY_BCI ? "" : "(OSR@" + entryBCI + ") ")); } CompilationResult result = null;
--- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/phases/OnStackReplacementPhase.java Sun Nov 18 21:30:35 2012 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/phases/OnStackReplacementPhase.java Sun Nov 18 22:45:43 2012 +0100 @@ -27,6 +27,7 @@ import com.oracle.graal.api.meta.*; import com.oracle.graal.debug.*; import com.oracle.graal.graph.*; +import com.oracle.graal.graph.Node.*; import com.oracle.graal.graph.iterators.*; import com.oracle.graal.loop.*; import com.oracle.graal.nodes.*; @@ -61,7 +62,7 @@ throw new BailoutException("osr with locks not supported"); } if (osr.stateAfter().stackSize() != 0) { - throw new GraalInternalError("osr with stack entries not supported"); + throw new BailoutException("osr with stack entries not supported: " + osr.stateAfter().toString(Verbosity.Debugger)); } LoopEx osrLoop = null; LoopsData loops = new LoopsData(graph);