Class SDG<T extends InstanceKey>
- All Implemented Interfaces:
IClassHierarchyDweller
,ISDG
,EdgeManager<Statement>
,Graph<Statement>
,NodeManager<Statement>
,NumberedEdgeManager<Statement>
,NumberedGraph<Statement>
,NumberedNodeManager<Statement>
,Iterable<Statement>
System dependence graph.
An SDG comprises a set of PDGs, one for each method. We compute these lazily.
Prototype implementation. Not efficient.
-
Constructor Summary
ConstructorDescriptionSDG
(CallGraph cg, PointerAnalysis<T> pa, ModRef<T> modRef, Slicer.DataDependenceOptions dOptions, Slicer.ControlDependenceOptions cOptions) SDG
(CallGraph cg, PointerAnalysis<T> pa, ModRef<T> modRef, Slicer.DataDependenceOptions dOptions, Slicer.ControlDependenceOptions cOptions, HeapExclusions heapExclude) SDG
(CallGraph cg, PointerAnalysis<T> pa, Slicer.DataDependenceOptions dOptions, Slicer.ControlDependenceOptions cOptions) -
Method Summary
Modifier and TypeMethodDescriptionSlicer.ControlDependenceOptions
used to construct this graph.Set
<? extends Dependency> getEdgeLabels
(Statement src, Statement dst) protected NumberedEdgeManager
<Statement> Get the program dependence graph constructed for a particular node.iterate over the nodes without constructing any new ones.toString()
Use this with care.Methods inherited from class com.ibm.wala.util.graph.AbstractNumberedGraph
getMaxNumber, getNode, getNumber, getPredNodeNumbers, getSuccNodeNumbers, iterateNodes
Methods inherited from class com.ibm.wala.util.graph.AbstractGraph
addEdge, addNode, containsNode, edgeString, getNumberOfNodes, getPredNodeCount, getPredNodes, getSuccNodeCount, getSuccNodes, hasEdge, iterator, nodeString, removeAllIncidentEdges, removeEdge, removeIncomingEdges, removeNode, removeNodeAndEdges, removeOutgoingEdges, stream
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.ibm.wala.util.graph.EdgeManager
addEdge, getPredNodeCount, getPredNodes, getSuccNodeCount, getSuccNodes, hasEdge, removeAllIncidentEdges, removeEdge, removeIncomingEdges, removeOutgoingEdges
Methods inherited from interface com.ibm.wala.util.graph.Graph
removeNodeAndEdges
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface com.ibm.wala.util.graph.NodeManager
addNode, containsNode, getNumberOfNodes, iterator, removeNode, stream
Methods inherited from interface com.ibm.wala.util.graph.NumberedEdgeManager
getPredNodeNumbers, getSuccNodeNumbers
Methods inherited from interface com.ibm.wala.util.graph.NumberedNodeManager
getMaxNumber, getNode, getNumber, iterateNodes
-
Constructor Details
-
SDG
public SDG(CallGraph cg, PointerAnalysis<T> pa, Slicer.DataDependenceOptions dOptions, Slicer.ControlDependenceOptions cOptions) -
SDG
public SDG(CallGraph cg, PointerAnalysis<T> pa, ModRef<T> modRef, Slicer.DataDependenceOptions dOptions, Slicer.ControlDependenceOptions cOptions) -
SDG
public SDG(CallGraph cg, PointerAnalysis<T> pa, ModRef<T> modRef, Slicer.DataDependenceOptions dOptions, Slicer.ControlDependenceOptions cOptions, HeapExclusions heapExclude) throws IllegalArgumentException - Throws:
IllegalArgumentException
-
-
Method Details
-
toString
Use this with care. This forces eager construction of the SDG, and SDGs can be big.- Overrides:
toString
in classAbstractGraph<Statement>
- See Also:
-
iterateLazyNodes
iterate over the nodes without constructing any new ones. Use with extreme care. May break graph traversals that lazily add more nodes.- Specified by:
iterateLazyNodes
in interfaceISDG
-
getEdgeManager
- Specified by:
getEdgeManager
in classAbstractNumberedGraph<Statement>
- Returns:
- the object which manages edges in the graph
-
getNodeManager
- Specified by:
getNodeManager
in classAbstractNumberedGraph<Statement>
- Returns:
- the object which manages nodes in the graph
-
getPDG
-
getCOptions
Description copied from interface:ISDG
Slicer.ControlDependenceOptions
used to construct this graph.- Specified by:
getCOptions
in interfaceISDG
-
getDOptions
-
getCallGraph
-
getClassHierarchy
- Specified by:
getClassHierarchy
in interfaceIClassHierarchyDweller
-
getPointerAnalysis
-
getEdgeLabels
-