--- old/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CompressionNode.java 2017-11-03 23:57:04.188241031 -0700 +++ new/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CompressionNode.java 2017-11-03 23:57:03.862226442 -0700 @@ -122,9 +122,9 @@ // We always want uncompressed constants return this; } - int stableDimension = ((ConstantNode) forValue).getStableDimension(); - boolean isDefaultStable = ((ConstantNode) forValue).isDefaultStable(); - return ConstantNode.forConstant(stamp(), convert(forValue.asConstant(), tool.getConstantReflection()), stableDimension, isDefaultStable, tool.getMetaAccess()); + + ConstantNode constant = (ConstantNode) forValue; + return ConstantNode.forConstant(stamp(), convert(constant.getValue(), tool.getConstantReflection()), constant.getStableDimension(), constant.isDefaultStable(), tool.getMetaAccess()); } else if (forValue instanceof CompressionNode) { CompressionNode other = (CompressionNode) forValue; if (op != other.op && encoding.equals(other.encoding)) { @@ -136,22 +136,22 @@ @Override public void generate(NodeLIRBuilderTool gen) { - LIRGeneratorTool hsGen = gen.getLIRGeneratorTool(); boolean nonNull; - if (getValue().stamp() instanceof AbstractObjectStamp) { - nonNull = StampTool.isPointerNonNull(getValue().stamp()); + if (value.stamp() instanceof AbstractObjectStamp) { + nonNull = StampTool.isPointerNonNull(value.stamp()); } else { // metaspace pointers are never null nonNull = true; } + LIRGeneratorTool tool = gen.getLIRGeneratorTool(); Value result; switch (op) { case Compress: - result = hsGen.emitCompress(gen.operand(getValue()), encoding, nonNull); + result = tool.emitCompress(gen.operand(value), encoding, nonNull); break; case Uncompress: - result = hsGen.emitUncompress(gen.operand(getValue()), encoding, nonNull); + result = tool.emitUncompress(gen.operand(value), encoding, nonNull); break; default: throw GraalError.shouldNotReachHere();