changeset 21646:645f170013a4

Fix in the scheduler for proxy node handling.
author Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
date Mon, 01 Jun 2015 22:14:34 +0200
parents 7eb156f30b61
children 1c76a5662753 99fe8116f3e8
files graal/com.oracle.graal.phases/src/com/oracle/graal/phases/schedule/SchedulePhase.java
diffstat 1 files changed, 17 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.phases/src/com/oracle/graal/phases/schedule/SchedulePhase.java	Mon Jun 01 22:13:10 2015 +0200
+++ b/graal/com.oracle.graal.phases/src/com/oracle/graal/phases/schedule/SchedulePhase.java	Mon Jun 01 22:14:34 2015 +0200
@@ -658,18 +658,23 @@
                             stack.push(input);
                         }
                     }
+                } else if (current instanceof ProxyNode) {
+                    ProxyNode proxyNode = (ProxyNode) current;
+                    for (Node input : proxyNode.inputs()) {
+                        if (input != proxyNode.proxyPoint()) {
+                            stack.push(input);
+                        }
+                    }
+                } else if (current instanceof FrameState) {
+                    for (Node input : current.inputs()) {
+                        if (input instanceof StateSplit && ((StateSplit) input).stateAfter() == current) {
+                            // Ignore the cycle.
+                        } else {
+                            stack.push(input);
+                        }
+                    }
                 } else {
-                    if (current instanceof FrameState) {
-                        for (Node input : current.inputs()) {
-                            if (input instanceof StateSplit && ((StateSplit) input).stateAfter() == current) {
-                                // Ignore the cycle.
-                            } else {
-                                stack.push(input);
-                            }
-                        }
-                    } else {
-                        current.pushInputs(stack);
-                    }
+                    current.pushInputs(stack);
                 }
             } else {
 
@@ -683,7 +688,7 @@
                         for (Node input : current.inputs()) {
                             Block inputEarliest = nodeToBlock.get(input);
                             if (inputEarliest == null) {
-                                assert current instanceof FrameState && input instanceof StateSplit && ((StateSplit) input).stateAfter() == current;
+                                assert current instanceof FrameState && input instanceof StateSplit && ((StateSplit) input).stateAfter() == current : current;
                             } else {
                                 assert inputEarliest != null;
                                 if (inputEarliest.getEndNode() == input) {