Mercurial > hg > truffle
changeset 16603:5fcb220206e2
small fix in FloatingReadPhase (when handling existing phis)
author | Lukas Stadler <lukas.stadler@oracle.com> |
---|---|
date | Mon, 28 Jul 2014 15:53:07 +0200 |
parents | a4490086af4d |
children | b519954b9daf |
files | graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/FloatingReadPhase.java |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/FloatingReadPhase.java Mon Jul 28 15:53:07 2014 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/FloatingReadPhase.java Mon Jul 28 15:53:07 2014 +0200 @@ -209,7 +209,7 @@ } - private static class CollectMemoryCheckpointsClosure extends NodeIteratorClosure<Set<LocationIdentity>> { + public static class CollectMemoryCheckpointsClosure extends NodeIteratorClosure<Set<LocationIdentity>> { private final Map<LoopBeginNode, Set<LocationIdentity>> modifiedInLoops; @@ -261,7 +261,7 @@ } - private static class FloatingReadClosure extends NodeIteratorClosure<MemoryMapImpl> { + public static class FloatingReadClosure extends NodeIteratorClosure<MemoryMapImpl> { private final Map<LoopBeginNode, Set<LocationIdentity>> modifiedInLoops; private boolean createFloatingReads; @@ -372,7 +372,7 @@ Map<LocationIdentity, MemoryPhiNode> phis = new HashMap<>(); if (updateExistingPhis) { - for (MemoryPhiNode phi : loop.phis().filter(MemoryPhiNode.class)) { + for (MemoryPhiNode phi : loop.phis().filter(MemoryPhiNode.class).snapshot()) { if (modifiedLocations.contains(phi.getLocationIdentity())) { phi.values().clear(); phi.addInput(ValueNodeUtil.asNode(initialState.getLastLocationAccess(phi.getLocationIdentity())));