Mercurial > hg > graal-jvmci-8
diff graal/GraalCompiler/src/com/sun/c1x/graph/GraphBuilder.java @ 2869:fc75fd3fa5e4
merge (inlining broken)
author | Lukas Stadler <lukas.stadler@jku.at> |
---|---|
date | Tue, 07 Jun 2011 19:21:23 +0200 |
parents | 5c545fef2c81 7a4e6e11877f |
children |
line wrap: on
line diff
--- a/graal/GraalCompiler/src/com/sun/c1x/graph/GraphBuilder.java Tue Jun 07 19:19:14 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/graph/GraphBuilder.java Tue Jun 07 19:21:23 2011 +0200 @@ -563,7 +563,18 @@ private void genShiftOp(CiKind kind, int opcode) { Value s = frameState.ipop(); Value x = frameState.pop(kind); - frameState.push(kind, append(new Shift(opcode, x, s, graph))); + Shift v; + switch(opcode){ + case ISHL: + case LSHL: v = new LeftShift(kind, x, s, graph); break; + case ISHR: + case LSHR: v = new RightShift(kind, x, s, graph); break; + case IUSHR: + case LUSHR: v = new UnsignedRightShift(kind, x, s, graph); break; + default: + throw new CiBailout("should not reach"); + } + frameState.push(kind, append(v)); } private void genLogicOp(CiKind kind, int opcode) { @@ -586,7 +597,7 @@ private void genCompareOp(CiKind kind, int opcode, CiKind resultKind) { Value y = frameState.pop(kind); Value x = frameState.pop(kind); - Value value = append(new Materialize(opcode, resultKind, x, y, graph)); + Value value = append(new NormalizeCompare(opcode, resultKind, x, y, graph)); if (!resultKind.isVoid()) { frameState.ipush(value); } @@ -611,7 +622,7 @@ private void ifNode(Value x, Condition cond, Value y) { assert !x.isDeleted() && !y.isDeleted(); - If ifNode = new If(x, cond, y, graph); + If ifNode = new If(new Compare(x, cond, y, graph), graph); append(ifNode); Instruction tsucc = createTargetAt(stream().readBranchDest(), frameState); ifNode.setBlockSuccessor(0, tsucc);