public class SimpleDemandPointerFlowGraph extends SlowSparseNumberedGraph<Object>
Modifier and Type | Class and Description |
---|---|
protected class |
SimpleDemandPointerFlowGraph.StatementVisitor
A visitor that generates graph nodes and edges for an IR.
|
Constructor and Description |
---|
SimpleDemandPointerFlowGraph(CallGraph cg,
HeapModel heapModel,
MemoryAccessMap fam,
IClassHierarchy cha) |
Modifier and Type | Method and Description |
---|---|
protected void |
addBlockInstructionConstraints(CGNode node,
ControlFlowGraph<SSAInstruction,ISSABasicBlock> cfg,
ISSABasicBlock b,
SimpleDemandPointerFlowGraph.StatementVisitor v)
Add constraints for a particular basic block.
|
protected void |
addNodeInstructionConstraints(CGNode node,
IR ir,
DefUse du)
Add pointer flow constraints based on instructions in a given node
|
protected void |
addNodePassthruExceptionConstraints(CGNode node,
IR ir)
Add constraints to represent the flow of exceptions to the exceptional return value for this node
|
void |
addSubgraphForNode(CGNode node) |
protected HeapModel |
getHeapModel() |
int |
getPredNodeCount(Object N)
Return the number of
immediate predecessor nodes of n |
IntSet |
getPredNodeNumbers(Object node) |
Iterator<Object> |
getPredNodes(Object N)
Return an
Iterator over the immediate predecessor nodes of n
This method never returns null . |
int |
getSuccNodeCount(Object N)
Return the number of
immediate successor nodes of this Node in the Graph |
IntSet |
getSuccNodeNumbers(Object node) |
Iterator<Object> |
getSuccNodes(Object N)
Return an Iterator over the immediate successor nodes of n
|
boolean |
hasEdge(PointerKey src,
PointerKey dst) |
protected SimpleDemandPointerFlowGraph.StatementVisitor |
makeVisitor(ExplicitCallGraph.ExplicitNode node,
IR ir,
DefUse du) |
protected void |
unconditionallyAddConstraintsFromNode(CGNode node) |
copyInto, duplicate, getEdgeManager, getNodeManager, make
getMaxNumber, getNode, getNumber, iterateNodes
addEdge, addNode, containsNode, getNumberOfNodes, hasEdge, iterator, removeAllIncidentEdges, removeEdge, removeIncomingEdges, removeNode, removeNodeAndEdges, removeOutgoingEdges, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
removeNodeAndEdges
addNode, containsNode, getNumberOfNodes, iterator, removeNode
forEach, spliterator
addEdge, hasEdge, removeAllIncidentEdges, removeEdge, removeIncomingEdges, removeOutgoingEdges
public SimpleDemandPointerFlowGraph(CallGraph cg, HeapModel heapModel, MemoryAccessMap fam, IClassHierarchy cha)
public void addSubgraphForNode(CGNode node)
protected HeapModel getHeapModel()
public IntSet getPredNodeNumbers(Object node) throws UnimplementedError
getPredNodeNumbers
in interface NumberedEdgeManager<Object>
getPredNodeNumbers
in class AbstractNumberedGraph<Object>
UnimplementedError
public IntSet getSuccNodeNumbers(Object node) throws IllegalArgumentException
getSuccNodeNumbers
in interface NumberedEdgeManager<Object>
getSuccNodeNumbers
in class AbstractNumberedGraph<Object>
IllegalArgumentException
public int getPredNodeCount(Object N) throws UnimplementedError
EdgeManager
immediate predecessor
nodes of ngetPredNodeCount
in interface EdgeManager<Object>
getPredNodeCount
in class AbstractGraph<Object>
UnimplementedError
public Iterator<Object> getPredNodes(Object N) throws IllegalArgumentException
EdgeManager
Iterator
over the immediate predecessor nodes of n
This method never returns null
.getPredNodes
in interface EdgeManager<Object>
getPredNodes
in class AbstractGraph<Object>
Iterator
over the immediate predecessor nodes of this Node.IllegalArgumentException
public int getSuccNodeCount(Object N) throws UnimplementedError
EdgeManager
immediate successor
nodes of this Node in the GraphgetSuccNodeCount
in interface EdgeManager<Object>
getSuccNodeCount
in class AbstractGraph<Object>
UnimplementedError
public Iterator<Object> getSuccNodes(Object N)
EdgeManager
This method never returns null
.
getSuccNodes
in interface EdgeManager<Object>
getSuccNodes
in class AbstractGraph<Object>
public boolean hasEdge(PointerKey src, PointerKey dst)
protected void unconditionallyAddConstraintsFromNode(CGNode node)
protected void addNodePassthruExceptionConstraints(CGNode node, IR ir)
protected void addNodeInstructionConstraints(CGNode node, IR ir, DefUse du)
protected void addBlockInstructionConstraints(CGNode node, ControlFlowGraph<SSAInstruction,ISSABasicBlock> cfg, ISSABasicBlock b, SimpleDemandPointerFlowGraph.StatementVisitor v)
protected SimpleDemandPointerFlowGraph.StatementVisitor makeVisitor(ExplicitCallGraph.ExplicitNode node, IR ir, DefUse du)