# HG changeset patch # User Andreas Woess # Date 1374513437 -7200 # Node ID 669e3105804dfeb31fda76ad9fa64a1fe06123b7 # Parent e87d56a51047e7d9d775e94a7163c130817c63b4 Always insert phi nodes using graph.add. diff -r e87d56a51047 -r 669e3105804d graal/com.oracle.graal.java/src/com/oracle/graal/java/FrameStateBuilder.java --- a/graal/com.oracle.graal.java/src/com/oracle/graal/java/FrameStateBuilder.java Mon Jul 22 18:07:53 2013 +0200 +++ b/graal/com.oracle.graal.java/src/com/oracle/graal/java/FrameStateBuilder.java Mon Jul 22 19:17:17 2013 +0200 @@ -195,7 +195,7 @@ return null; } - PhiNode phi = graph.unique(new PhiNode(currentValue.kind(), block)); + PhiNode phi = graph.add(new PhiNode(currentValue.kind(), block)); for (int i = 0; i < block.phiPredecessorCount(); i++) { phi.addInput(currentValue); } @@ -290,7 +290,7 @@ } assert !block.isPhiAtMerge(value) : "phi function for this block already created"; - PhiNode phi = graph.unique(new PhiNode(value.kind(), block)); + PhiNode phi = graph.add(new PhiNode(value.kind(), block)); phi.addInput(value); return phi; } diff -r e87d56a51047 -r 669e3105804d graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/InliningUtil.java --- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/InliningUtil.java Mon Jul 22 18:07:53 2013 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/InliningUtil.java Mon Jul 22 19:17:17 2013 +0200 @@ -609,7 +609,7 @@ PhiNode returnValuePhi = null; if (invoke.asNode().kind() != Kind.Void) { - returnValuePhi = graph.unique(new PhiNode(invoke.asNode().kind(), returnMerge)); + returnValuePhi = graph.add(new PhiNode(invoke.asNode().kind(), returnMerge)); } MergeNode exceptionMerge = null; @@ -622,7 +622,7 @@ FixedNode exceptionSux = exceptionEdge.next(); graph.addBeforeFixed(exceptionSux, exceptionMerge); - exceptionObjectPhi = graph.unique(new PhiNode(Kind.Object, exceptionMerge)); + exceptionObjectPhi = graph.add(new PhiNode(Kind.Object, exceptionMerge)); exceptionMerge.setStateAfter(exceptionEdge.stateAfter().duplicateModified(invoke.stateAfter().bci, true, Kind.Object, exceptionObjectPhi)); }