public class SPatchingChain extends PatchingChain<Unit>
PatchingChain
,
Serialized FormModifier and Type | Class and Description |
---|---|
protected class |
SPatchingChain.SPatchingIterator |
PatchingChain.PatchingIterator
Modifier and Type | Field and Description |
---|---|
protected Map<SUnitBox,Boolean> |
boxToNeedsPatching
Flag that indicates whether control flow falls through from the
box to the Phi node.
|
protected Map<UnitBox,Unit> |
boxToPhiNode
Map from UnitBox to the Phi node owning it.
|
protected Set<Unit> |
phiNodeSet
Set of the values of boxToPhiNode.
|
innerChain
Constructor and Description |
---|
SPatchingChain(Body aBody,
Chain<Unit> aChain) |
Modifier and Type | Method and Description |
---|---|
boolean |
add(Unit o)
Adds the given object to this Chain.
|
void |
addFirst(Unit u)
Adds the given object at the beginning of the Chain.
|
void |
addLast(Unit u)
Adds the given object at the end of the Chain.
|
protected void |
computeNeedsPatching()
NOTE: This will *miss* all the Phi nodes outside a chain.
|
protected SUnitBox |
getSBox(UnitBox box) |
void |
insertAfter(List<Unit> toInsert,
Unit point)
Inserts
toInsert in the Chain after point . |
void |
insertAfter(Unit toInsert,
Unit point)
Inserts
toInsert in the Chain after point . |
void |
insertBefore(List<Unit> toInsert,
Unit point)
Inserts
toInsert in the Chain before point . |
void |
insertBefore(Unit toInsert,
Unit point)
Inserts
toInsert in the Chain before point . |
Iterator<Unit> |
iterator()
Returns an iterator over this Chain.
|
Iterator<Unit> |
iterator(Unit u)
Returns an iterator over this Chain, starting at the given object.
|
Iterator<Unit> |
iterator(Unit head,
Unit tail)
Returns an iterator over this Chain, starting at head and reaching tail (inclusive).
|
protected void |
processPhiNode(Unit o) |
boolean |
remove(Unit obj) |
protected void |
reprocessPhiNodes() |
void |
swapWith(Unit out,
Unit in)
Replaces
out in the Chain by in . |
contains, follows, getElementsUnsorted, getFirst, getLast, getModificationCount, getNonPatchingChain, getPredOf, getSuccOf, insertAfter, insertBefore, insertBeforeNoRedirect, insertOnEdge, insertOnEdge, insertOnEdge, remove, removeFirst, removeLast, size, snapshotIterator
addAll, clear, containsAll, isEmpty, removeAll, retainAll, toArray, toArray, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addAll, clear, containsAll, equals, hashCode, isEmpty, parallelStream, removeAll, removeIf, retainAll, spliterator, stream, toArray, toArray
protected Set<Unit> phiNodeSet
public boolean add(Unit o)
PatchingChain
add
in interface Collection<Unit>
add
in class PatchingChain<Unit>
public void swapWith(Unit out, Unit in)
PatchingChain
out
in the Chain by in
.public void insertAfter(Unit toInsert, Unit point)
PatchingChain
toInsert
in the Chain after point
.insertAfter
in interface Chain<Unit>
insertAfter
in class PatchingChain<Unit>
public void insertAfter(List<Unit> toInsert, Unit point)
PatchingChain
toInsert
in the Chain after point
.insertAfter
in interface Chain<Unit>
insertAfter
in class PatchingChain<Unit>
public void insertBefore(List<Unit> toInsert, Unit point)
PatchingChain
toInsert
in the Chain before point
.insertBefore
in interface Chain<Unit>
insertBefore
in class PatchingChain<Unit>
public void insertBefore(Unit toInsert, Unit point)
PatchingChain
toInsert
in the Chain before point
.insertBefore
in interface Chain<Unit>
insertBefore
in class PatchingChain<Unit>
public void addFirst(Unit u)
PatchingChain
public void addLast(Unit u)
PatchingChain
public boolean remove(Unit obj)
protected void processPhiNode(Unit o)
protected void reprocessPhiNodes()
protected void computeNeedsPatching()
public Iterator<Unit> iterator()
PatchingChain
public Iterator<Unit> iterator(Unit u)
PatchingChain