# HG changeset patch # User Tom Rodriguez # Date 1429834672 25200 # Node ID 5d7a2915c96cf9e64a6865d369020cac7d7ca108 # Parent ec894427332d73c253ce884deb2a121291857842 Check for placeholder bci even when asserts are disabled diff -r ec894427332d -r 5d7a2915c96c graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotDebugInfoBuilder.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotDebugInfoBuilder.java Thu Apr 23 12:55:54 2015 -0700 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotDebugInfoBuilder.java Thu Apr 23 17:17:52 2015 -0700 @@ -26,6 +26,7 @@ import com.oracle.graal.api.code.*; import com.oracle.graal.api.meta.*; +import com.oracle.graal.compiler.common.*; import com.oracle.graal.compiler.gen.*; import com.oracle.graal.graph.*; import com.oracle.graal.nodes.*; @@ -62,7 +63,10 @@ @Override protected BytecodeFrame computeFrameForState(FrameState state) { - assert !isPlaceholderBci(state.bci) || state.bci == BytecodeFrame.BEFORE_BCI : BytecodeFrame.getPlaceholderBciName(state.bci); + if (isPlaceholderBci(state.bci) && state.bci != BytecodeFrame.BEFORE_BCI) { + // This is really a hard error since an incorrect state could crash hotspot + throw GraalInternalError.shouldNotReachHere("Invalid state " + BytecodeFrame.getPlaceholderBciName(state.bci) + " " + state); + } return super.computeFrameForState(state); } }