diff graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/UseTrappingNullChecksPhase.java @ 18993:480bd3b1adcd

Rename BeginNode => AbstractBeginNode.
author Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
date Wed, 28 Jan 2015 00:50:31 +0100
parents edf3a7fdd067
children a2cb19764970
line wrap: on
line diff
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/UseTrappingNullChecksPhase.java	Tue Jan 27 23:52:31 2015 +0100
+++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/UseTrappingNullChecksPhase.java	Wed Jan 28 00:50:31 2015 +0100
@@ -122,16 +122,16 @@
                     checkPredecessor(deopt, end.predecessor(), deoptimizationReason);
                 }
             }
-        } else if (predecessor instanceof BeginNode) {
+        } else if (predecessor instanceof AbstractBeginNode) {
             checkPredecessor(deopt, predecessor, deoptimizationReason);
         }
     }
 
     private static void checkPredecessor(AbstractDeoptimizeNode deopt, Node predecessor, DeoptimizationReason deoptimizationReason) {
         Node current = predecessor;
-        BeginNode branch = null;
-        while (current instanceof BeginNode) {
-            branch = (BeginNode) current;
+        AbstractBeginNode branch = null;
+        while (current instanceof AbstractBeginNode) {
+            branch = (AbstractBeginNode) current;
             if (branch.anchored().isNotEmpty()) {
                 // some input of the deopt framestate is anchored to this branch
                 return;
@@ -159,8 +159,8 @@
             metricTrappingNullCheckUnreached.increment();
         }
         IsNullNode isNullNode = (IsNullNode) condition;
-        BeginNode nonTrappingContinuation = ifNode.falseSuccessor();
-        BeginNode trappingContinuation = ifNode.trueSuccessor();
+        AbstractBeginNode nonTrappingContinuation = ifNode.falseSuccessor();
+        AbstractBeginNode trappingContinuation = ifNode.trueSuccessor();
         NullCheckNode trappingNullCheck = deopt.graph().add(new NullCheckNode(isNullNode.getValue()));
         trappingNullCheck.setStateBefore(deopt.stateBefore());
         deopt.graph().replaceSplit(ifNode, trappingNullCheck, nonTrappingContinuation);
@@ -171,7 +171,7 @@
          * then remove the Begin from the graph.
          */
         nonTrappingContinuation.replaceAtUsages(InputType.Guard, trappingNullCheck);
-        if (nonTrappingContinuation.getClass() == BeginNode.class) {
+        if (nonTrappingContinuation.getClass() == AbstractBeginNode.class) {
             FixedNode next = nonTrappingContinuation.next();
             nonTrappingContinuation.clearSuccessors();
             trappingNullCheck.setNext(next);