Mercurial > hg > truffle
changeset 11335:ccbbb7dbca69
Make sure the created ProxyNode is of PhiType.Guard.
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Fri, 16 Aug 2013 21:40:42 +0200 |
parents | 7f713aad89de |
children | e99a5d7c3deb |
files | graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/ProxyNode.java graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ConvertDeoptimizeToGuardPhase.java |
diffstat | 2 files changed, 5 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/ProxyNode.java Fri Aug 16 21:23:30 2013 +0200 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/ProxyNode.java Fri Aug 16 21:40:42 2013 +0200 @@ -103,6 +103,10 @@ } } + public static ProxyNode forGuard(ValueNode value, AbstractBeginNode exit, StructuredGraph graph) { + return graph.unique(new ProxyNode(value, exit, PhiType.Guard, null)); + } + public static ProxyNode forValue(ValueNode value, AbstractBeginNode exit, StructuredGraph graph) { return graph.unique(new ProxyNode(value, exit, PhiType.Value, null)); }
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ConvertDeoptimizeToGuardPhase.java Fri Aug 16 21:23:30 2013 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ConvertDeoptimizeToGuardPhase.java Fri Aug 16 21:40:42 2013 +0200 @@ -94,7 +94,7 @@ // Rewire to the fixed guard. if (survivingSuccessor instanceof LoopExitNode) { if (proxyGuard == null) { - proxyGuard = ProxyNode.forValue(guard, survivingSuccessor, graph); + proxyGuard = ProxyNode.forGuard(guard, survivingSuccessor, graph); } n.replaceFirstInput(survivingSuccessor, proxyGuard); } else {