# HG changeset patch # User Gilles Duboscq # Date 1337348963 -7200 # Node ID bd5624f040676ec10aae3949d591a04b846d8b98 # Parent 79f12805362b87be3c26998ff44e1788055859ae do not canonicalize scaled indexedlocation nodes if target is not available diff -r 79f12805362b -r bd5624f04067 graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/IndexedLocationNode.java --- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/IndexedLocationNode.java Fri May 18 15:48:38 2012 +0200 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/extended/IndexedLocationNode.java Fri May 18 15:49:23 2012 +0200 @@ -72,7 +72,10 @@ CiConstant constantIndex = index.asConstant(); if (constantIndex != null && constantIndex.kind.stackKind().isInt()) { long constantIndexLong = constantIndex.asInt(); - if (indexScalingEnabled && tool.target() != null) { + if (indexScalingEnabled) { + if (tool.target() == null) { + return this; + } constantIndexLong *= tool.target().sizeInBytes(getValueKind()); } constantIndexLong += displacement();