diff graal/GraalCompiler/src/com/sun/c1x/alloc/EdgeMoveOptimizer.java @ 2707:7ed72769d51a

exception handling related changes: * changed blockPredecessors to list of Instructions, instead of Blocks * removed explicit predecessor management in BlockBegin, now using predecessors from Graph structure * replaced generated LIR exception entries with exception dispatch chains in IR * added Unwind and ExceptionDispatch instructions * removed ExceptionEntry flag in BlockBegin and all code depending on it * removed exceptionHandler list from Instruction, replaced by exception Edge on Invoke and Throw * replaced list of ExceptionHandlers with single exception edge in debug info misc: * changed GraphvizPrinter layout (smaller ports on large nodes) * removed defunct run config
author Lukas Stadler <lukas.stadler@jku.at>
date Wed, 18 May 2011 18:09:20 +0200
parents 6ab73784566a
children c1ce2a53d6c3
line wrap: on
line diff
--- a/graal/GraalCompiler/src/com/sun/c1x/alloc/EdgeMoveOptimizer.java	Fri May 13 17:09:20 2011 -0700
+++ b/graal/GraalCompiler/src/com/sun/c1x/alloc/EdgeMoveOptimizer.java	Wed May 18 18:09:20 2011 +0200
@@ -66,7 +66,7 @@
         for (int i = blockList.size() - 1; i >= 1; i--) {
             BlockBegin block = blockList.get(i);
 
-            if (block.numberOfPreds() > 1 && !block.checkBlockFlag(BlockBegin.BlockFlag.ExceptionEntry)) {
+            if (block.numberOfPreds() > 1) {
                 optimizer.optimizeMovesAtBlockEnd(block);
             }
             if (block.numberOfSux() == 2) {
@@ -122,11 +122,10 @@
 
         int numPreds = block.numberOfPreds();
         assert numPreds > 1 : "do not call otherwise";
-        assert !block.checkBlockFlag(BlockBegin.BlockFlag.ExceptionEntry) : "exception handlers not allowed";
 
         // setup a list with the LIR instructions of all predecessors
         for (int i = 0; i < numPreds; i++) {
-            BlockBegin pred = block.predAt(i).begin();
+            BlockBegin pred = block.predAt(i).block();
             List<LIRInstruction> predInstructions = pred.lir().instructionsList();
 
             if (pred.numberOfSux() != 1) {
@@ -231,8 +230,7 @@
                 // the same blocks.
                 return;
             }
-            assert sux.predAt(0).begin() == block : "invalid control flow";
-            assert !sux.checkBlockFlag(BlockBegin.BlockFlag.ExceptionEntry) : "exception handlers not allowed";
+            assert sux.predAt(0).block() == block : "invalid control flow";
 
             // ignore the label at the beginning of the block
             List<LIRInstruction> seq = suxInstructions.subList(1, suxInstructions.size());