Mercurial > hg > graal-compiler
changeset 11499:fc3a6fb4cf3d
Support for PlatformKind in PhiResolver.
author | Roland Schatz <roland.schatz@oracle.com> |
---|---|
date | Mon, 02 Sep 2013 14:15:41 +0200 |
parents | 94ec1122be13 |
children | d2f31e6ddc35 bb39b1bce748 |
files | graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/LIRGenerator.java graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/PhiResolver.java |
diffstat | 2 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/LIRGenerator.java Mon Sep 02 14:08:49 2013 +0200 +++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/LIRGenerator.java Mon Sep 02 14:15:41 2013 +0200 @@ -452,12 +452,16 @@ append(new JumpOp(getLIRBlock(merge))); } + protected PlatformKind getPhiKind(PhiNode phi) { + return phi.kind(); + } + private Value operandForPhi(PhiNode phi) { assert phi.type() == PhiType.Value : "wrong phi type: " + phi; Value result = operand(phi); if (result == null) { // allocate a variable for this phi - Variable newOperand = newVariable(phi.kind()); + Variable newOperand = newVariable(getPhiKind(phi)); setResult(phi, newOperand); return newOperand; } else {
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/PhiResolver.java Mon Sep 02 14:08:49 2013 +0200 +++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/PhiResolver.java Mon Sep 02 14:15:41 2013 +0200 @@ -230,7 +230,7 @@ private void moveToTemp(Value src) { assert isIllegal(temp); - temp = gen.newVariable(src.getKind()); + temp = gen.newVariable(src.getPlatformKind()); emitMove(temp, src); }