Mercurial > hg > graal-jvmci-8
changeset 10813:3d6bd17da6e1
fix problem in PEReadEliminationClosure (could lead to unschedulable graph)
author | Lukas Stadler <lukas.stadler@jku.at> |
---|---|
date | Thu, 18 Jul 2013 17:16:16 +0200 |
parents | dd95ee93c893 |
children | 8b0c8fbbfa1c |
files | graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/PEReadEliminationClosure.java |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/PEReadEliminationClosure.java Thu Jul 18 17:15:32 2013 +0200 +++ b/graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/PEReadEliminationClosure.java Thu Jul 18 17:16:16 2013 +0200 @@ -69,12 +69,13 @@ ValueNode object = GraphUtil.unproxify(store.object()); ValueNode cachedValue = state.getReadCache(object, store.field()); - if (state.getScalarAlias(store.value()) == cachedValue) { + ValueNode value = state.getScalarAlias(store.value()); + if (value == cachedValue) { effects.deleteFixedNode(store); deleted = true; } state.killReadCache(store.field()); - state.addReadCache(object, store.field(), store.value()); + state.addReadCache(object, store.field(), value); } else if (node instanceof MemoryCheckpoint.Single) { METRIC_MEMORYCHECKOINT.increment(); LocationIdentity identity = ((MemoryCheckpoint.Single) node).getLocationIdentity();