Mercurial > hg > truffle
changeset 12659:55b23f75d3b0
Add graph parameter to ConvertNode smart constructor.
author | Roland Schatz <roland.schatz@oracle.com> |
---|---|
date | Mon, 04 Nov 2013 12:17:37 +0100 |
parents | ef6745a4597a |
children | a2b1ee69ce46 |
files | graal/com.oracle.graal.loop/src/com/oracle/graal/loop/DerivedOffsetInductionVariable.java graal/com.oracle.graal.loop/src/com/oracle/graal/loop/DerivedScaledInductionVariable.java graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/calc/ConvertNode.java |
diffstat | 3 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.loop/src/com/oracle/graal/loop/DerivedOffsetInductionVariable.java Mon Nov 04 11:40:33 2013 +0100 +++ b/graal/com.oracle.graal.loop/src/com/oracle/graal/loop/DerivedOffsetInductionVariable.java Mon Nov 04 12:17:37 2013 +0100 @@ -93,7 +93,7 @@ @Override public ValueNode extremumNode(boolean assumePositiveTripCount, Kind kind) { - return op(base.extremumNode(assumePositiveTripCount, kind), ConvertNode.convert(kind, offset)); + return op(base.extremumNode(assumePositiveTripCount, kind), ConvertNode.convert(graph(), kind, offset)); } @Override
--- a/graal/com.oracle.graal.loop/src/com/oracle/graal/loop/DerivedScaledInductionVariable.java Mon Nov 04 11:40:33 2013 +0100 +++ b/graal/com.oracle.graal.loop/src/com/oracle/graal/loop/DerivedScaledInductionVariable.java Mon Nov 04 12:17:37 2013 +0100 @@ -103,7 +103,7 @@ @Override public ValueNode extremumNode(boolean assumePositiveTripCount, Kind kind) { - return IntegerArithmeticNode.mul(graph(), base.extremumNode(assumePositiveTripCount, kind), ConvertNode.convert(kind, scale)); + return IntegerArithmeticNode.mul(graph(), base.extremumNode(assumePositiveTripCount, kind), ConvertNode.convert(graph(), kind, scale)); } @Override
--- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/calc/ConvertNode.java Mon Nov 04 11:40:33 2013 +0100 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/calc/ConvertNode.java Mon Nov 04 12:17:37 2013 +0100 @@ -274,11 +274,11 @@ gen.setResult(this, gen.emitConvert(from, to, gen.operand(value()))); } - public static ValueNode convert(Kind toKind, ValueNode value) { + public static ValueNode convert(StructuredGraph graph, Kind toKind, ValueNode value) { Kind fromKind = value.kind(); if (fromKind == toKind) { return value; } - return value.graph().unique(new ConvertNode(fromKind, toKind, value)); + return graph.unique(new ConvertNode(fromKind, toKind, value)); } }