Mercurial > hg > graal-compiler
changeset 3176:bb38f184055d
Fixed anchor creation such that exception handler blocks are recognized.
author | Thomas Wuerthinger <thomas@wuerthinger.net> |
---|---|
date | Wed, 06 Jul 2011 21:43:07 +0200 |
parents | 2de2bff9dba6 |
children | fe8423692c05 |
files | graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/schedule/Block.java |
diffstat | 1 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/schedule/Block.java Wed Jul 06 21:40:39 2011 +0200 +++ b/graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/schedule/Block.java Wed Jul 06 21:43:07 2011 +0200 @@ -95,14 +95,14 @@ firstNode.graph().start().setNext(a); this.anchor = a; } - } else if (firstNode instanceof Merge) { - Merge merge = (Merge) firstNode; - if (merge.next() instanceof Anchor) { - this.anchor = (Anchor) merge.next(); + } else if (firstNode instanceof Merge || firstNode instanceof ExceptionObject) { + FixedNodeWithNext fixedNode = (FixedNodeWithNext) firstNode; + if (fixedNode.next() instanceof Anchor) { + this.anchor = (Anchor) fixedNode.next(); } else { Anchor a = new Anchor(firstNode.graph()); - a.setNext(merge.next()); - merge.setNext(a); + a.setNext(fixedNode.next()); + fixedNode.setNext(a); this.anchor = a; } } else {