# HG changeset patch # User Gilles Duboscq # Date 1329475064 -3600 # Node ID 73f935f28920ea535dbf24c3de7ef3cbe050e660 # Parent 3b632ae14d47b991c2e05ef57e1ec75dec313a00 in esa mode, check that values in stateAfter are all ready after LIRGen of a ValudeNode diff -r 3b632ae14d47 -r 73f935f28920 graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/gen/LIRGenerator.java --- a/graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/gen/LIRGenerator.java Thu Feb 16 19:29:32 2012 +0100 +++ b/graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/gen/LIRGenerator.java Fri Feb 17 11:37:44 2012 +0100 @@ -396,6 +396,7 @@ if (stateAfter != null) { lastState = stateAfter; assert checkStartOperands(instr, lastState); + checkStateReady(lastState); if (GraalOptions.TraceLIRGeneratorLevel >= 2) { TTY.println("STATE CHANGE"); if (GraalOptions.TraceLIRGeneratorLevel >= 3) { @@ -424,6 +425,15 @@ } } + private void checkStateReady(FrameState state) { + for (int i = 0; i < state.valuesSize(); i++) { + ValueNode v = state.valueAt(i); + if (v != null && !(v instanceof VirtualObjectNode)) { + assert operand(v) != null : "Value " + v + " in " + state + " is not ready!"; + } + } + } + private static boolean endsWithJump(Block block) { if (block.lir.size() == 0) { return false;