Mercurial > hg > graal-compiler
changeset 21235:7e9edc108b35
NodeLIRBuilder: use AbstractMergeNode#valuePhis.
author | Josef Eisl <josef.eisl@jku.at> |
---|---|
date | Tue, 05 May 2015 13:08:05 +0200 |
parents | 4e5fe228f629 |
children | 8d21d631a82d |
files | graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/NodeLIRBuilder.java |
diffstat | 1 files changed, 2 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/NodeLIRBuilder.java Tue May 05 13:07:06 2015 +0200 +++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/NodeLIRBuilder.java Tue May 05 13:08:05 2015 +0200 @@ -40,7 +40,6 @@ import com.oracle.graal.debug.*; import com.oracle.graal.debug.Debug.Scope; import com.oracle.graal.graph.*; -import com.oracle.graal.graph.iterators.*; import com.oracle.graal.lir.*; import com.oracle.graal.lir.StandardOp.JumpOp; import com.oracle.graal.lir.StandardOp.LabelOp; @@ -194,10 +193,6 @@ gen.append(op); } - private static NodeIterable<ValuePhiNode> valuePhis(AbstractMergeNode merge) { - return merge.usages().filter(ValuePhiNode.class).filter(merge::isPhiAtMerge); - } - protected LIRKind getExactPhiKind(PhiNode phi) { ArrayList<Value> values = new ArrayList<>(phi.valueCount()); for (int i = 0; i < phi.valueCount(); i++) { @@ -223,7 +218,7 @@ private Value[] createPhiIn(AbstractMergeNode merge) { List<Value> values = new ArrayList<>(); - for (ValuePhiNode phi : valuePhis(merge)) { + for (ValuePhiNode phi : merge.valuePhis()) { assert getOperand(phi) == null; Variable value = gen.newVariable(getExactPhiKind(phi)); values.add(value); @@ -234,7 +229,7 @@ private Value[] createPhiOut(AbstractMergeNode merge, AbstractEndNode pred) { List<Value> values = new ArrayList<>(); - for (PhiNode phi : valuePhis(merge)) { + for (PhiNode phi : merge.valuePhis()) { Value value = operand(phi.valueAt(pred)); assert value != null; values.add(value);