# HG changeset patch # User Thomas Wuerthinger # Date 1306237892 -7200 # Node ID 3b73b230b86b83cafa92efdae06041ad876091e8 # Parent 93fd92c9f8b08d80585318f5b5024c7007744c7a Removed more stateAfter usages. diff -r 93fd92c9f8b0 -r 3b73b230b86b graal/GraalCompiler/src/com/sun/c1x/alloc/LinearScan.java --- a/graal/GraalCompiler/src/com/sun/c1x/alloc/LinearScan.java Tue May 24 13:39:50 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/alloc/LinearScan.java Tue May 24 13:51:32 2011 +0200 @@ -1263,21 +1263,6 @@ } // end of instruction iteration - // (tw) Make sure that no spill store optimization is applied for phi instructions that flow into exception handlers. -// if (block.isExceptionEntry()) { -// FrameState stateBefore = block.stateBefore(); -// stateBefore.forEachLivePhi(block, new PhiProcedure() { -// @Override -// public boolean doPhi(Phi phi) { -// Interval interval = intervalFor(phi.operand()); -// if (interval != null) { -// interval.setSpillState(SpillState.NoOptimization); -// } -// return true; -// } -// }); -// } - } // end of block iteration // add the range [0, 1] to all fixed intervals. diff -r 93fd92c9f8b0 -r 3b73b230b86b graal/GraalCompiler/src/com/sun/c1x/gen/LIRGenerator.java --- a/graal/GraalCompiler/src/com/sun/c1x/gen/LIRGenerator.java Tue May 24 13:39:50 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/gen/LIRGenerator.java Tue May 24 13:51:32 2011 +0200 @@ -599,7 +599,7 @@ if (x.kind.isVoid()) { XirSnippet epilogue = xir.genEpilogue(site(x), compilation.method); if (epilogue != null) { - emitXir(epilogue, x, stateFor(x), compilation.method, false); + emitXir(epilogue, x, null, compilation.method, false); lir.returnOp(IllegalValue); } } else { @@ -607,7 +607,7 @@ CiValue result = force(x.result(), operand); XirSnippet epilogue = xir.genEpilogue(site(x), compilation.method); if (epilogue != null) { - emitXir(epilogue, x, stateFor(x, x.stateAfter()), compilation.method, false); + emitXir(epilogue, x, null, compilation.method, false); lir.returnOp(result); } } diff -r 93fd92c9f8b0 -r 3b73b230b86b graal/GraalCompiler/src/com/sun/c1x/graph/GraphBuilder.java --- a/graal/GraalCompiler/src/com/sun/c1x/graph/GraphBuilder.java Tue May 24 13:39:50 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/graph/GraphBuilder.java Tue May 24 13:51:32 2011 +0200 @@ -1167,7 +1167,7 @@ } } - private BlockEnd iterateBytecodesForBlock(Block block) { + private void iterateBytecodesForBlock(Block block) { assert frameState != null; stream.setBCI(block.startBci); @@ -1207,17 +1207,6 @@ } blockStart = false; } - - // if the method terminates, we don't need the stack anymore - if (end instanceof Return || end instanceof Throw) { - frameState.clearStack(); - } - - // connect to begin and set state - // NOTE that inlining may have changed the block we are parsing - assert end != null : "end should exist after iterating over bytecodes"; - end.setStateAfter(frameState.create(bci())); - return end; } private void traceState() { diff -r 93fd92c9f8b0 -r 3b73b230b86b graal/GraalCompiler/src/com/sun/c1x/value/FrameState.java --- a/graal/GraalCompiler/src/com/sun/c1x/value/FrameState.java Tue May 24 13:39:50 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/value/FrameState.java Tue May 24 13:51:32 2011 +0200 @@ -78,6 +78,8 @@ this.locksSize = locksSize; C1XMetrics.FrameStatesCreated++; C1XMetrics.FrameStateValuesCreated += localsSize + stackSize + locksSize; + //Exception e = new Exception(); + //e.printStackTrace(); } FrameState(int bci, Value[] locals, Value[] stack, int stackSize, ArrayList locks, Graph graph) {