Mercurial > hg > truffle
diff graal/GraalCompiler/src/com/sun/c1x/graph/CriticalEdgeFinder.java @ 2788:df4c5254c5cc
Towards goto removal.
author | Thomas Wuerthinger <thomas@wuerthinger.net> |
---|---|
date | Wed, 25 May 2011 14:33:44 +0200 |
parents | 79dda81dd337 |
children | aeccd2af4e9e |
line wrap: on
line diff
--- a/graal/GraalCompiler/src/com/sun/c1x/graph/CriticalEdgeFinder.java Wed May 25 12:20:08 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/graph/CriticalEdgeFinder.java Wed May 25 14:33:44 2011 +0200 @@ -108,7 +108,10 @@ newSucc.getInstructions().add(e); // link predecessor to new block - ((BlockEnd) source.getInstructions().get(source.getInstructions().size() - 1)).successors().replace(target.getInstructions().get(0), newSucc.getInstructions().get(0)); +// if (source.getInstructions().size() > 0) { + source.getInstructions().get(source.getInstructions().size() - 1).successors().replace(target.getInstructions().get(0), newSucc.getInstructions().get(0)); +// } + source.substituteSuccessor(target, newSucc); target.substitutePredecessor(source, newSucc);