|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectchord.util.graph.AbstractGraph<Pair<Ctxt,joeq.Class.jq_Method>>
chord.analyses.alias.CSCG
public class CSCG
Implementation of a context-sensitive call graph.
| Field Summary | |
|---|---|
protected DomM |
domM
|
protected ProgramRel |
relCICM
|
protected ProgramRel |
relCMCM
|
protected ProgramRel |
relReachableCM
|
protected ProgramRel |
relRootCM
|
| Fields inherited from class chord.util.graph.AbstractGraph |
|---|
cached |
| Constructor Summary | |
|---|---|
CSCG(DomM domM,
ProgramRel relRootCM,
ProgramRel relReachableCM,
ProgramRel relCICM,
ProgramRel relCMCM)
|
|
| Method Summary | |
|---|---|
boolean |
calls(Ctxt origCtxt,
joeq.Compiler.Quad.Quad origInvk,
Ctxt destCtxt,
joeq.Class.jq_Method destMeth)
/** Determines whether a given jq_Method invocation site in a given abstract context may call a given jq_Method in a given abstract context. |
void |
free()
Frees relations used by this call graph if they are in memory. |
java.util.Set<Pair<Ctxt,joeq.Compiler.Quad.Quad>> |
getCallers(Ctxt ctxt,
joeq.Class.jq_Method meth)
Provides each jq_Method invocation site along with each abstract context from which it may call a given jq_Method in a given abstract context. |
java.util.Set<Ctxt> |
getContexts(joeq.Class.jq_Method jq_Method)
Provides the set of all abstract contexts in which a given method may be reachable. |
java.util.Set<joeq.Compiler.Quad.Quad> |
getLabels(Pair<Ctxt,joeq.Class.jq_Method> origNode,
Pair<Ctxt,joeq.Class.jq_Method> destNode)
Provides the set of all labels on a given directed edge in the graph. |
java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> |
getNodes()
Provides all nodes in this graph. |
java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> |
getPreds(Pair<Ctxt,joeq.Class.jq_Method> cm)
Provides all immediate predecessors of a given node in this graph. |
java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> |
getRoots()
Provides all root nodes of this graph. |
java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> |
getSuccs(Pair<Ctxt,joeq.Class.jq_Method> cm)
Provides all immediate successors of a given node in this graph. |
java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> |
getTargets(Ctxt ctxt,
joeq.Compiler.Quad.Quad invk)
Provides the set containing each method along with each abstract context in which it may be called by a given call site in a given abstract context. |
boolean |
hasEdge(Pair<Ctxt,joeq.Class.jq_Method> node1,
Pair<Ctxt,joeq.Class.jq_Method> node2)
Determines whether this graph contains a given directed edge. |
boolean |
hasNode(Pair<Ctxt,joeq.Class.jq_Method> node)
Determines whether this graph contains a given node. |
boolean |
hasRoot(Pair<Ctxt,joeq.Class.jq_Method> node)
Determines whether this graph contains a given node as a root node. |
int |
numNodes()
Provides the total number of nodes in this graph. |
int |
numPreds(Pair<Ctxt,joeq.Class.jq_Method> node)
Provides the number of immediate predecessors of a given node in this graph. |
int |
numRoots()
Provides the total number of roots of this graph. |
int |
numSuccs(Pair<Ctxt,joeq.Class.jq_Method> node)
Provides the number of immediate successors of a given node in this graph. |
| Methods inherited from class chord.util.graph.AbstractGraph |
|---|
equals, evictCache, getAllPathsBuilder, getBackEdges, getNodeMap, getNodesInCycles, getNodesInRPO, getShortestPathsBuilder, getSimpleCycles, getTopSortedSCCs, hasCycles, hashCode, isConnected, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface chord.util.graph.IGraph |
|---|
getAllPathsBuilder, getBackEdges, getNodeMap, getNodesInCycles, getNodesInRPO, getShortestPathsBuilder, getSimpleCycles, getTopSortedSCCs, hasCycles, isConnected |
| Field Detail |
|---|
protected DomM domM
protected ProgramRel relRootCM
protected ProgramRel relReachableCM
protected ProgramRel relCICM
protected ProgramRel relCMCM
| Constructor Detail |
|---|
public CSCG(DomM domM,
ProgramRel relRootCM,
ProgramRel relReachableCM,
ProgramRel relCICM,
ProgramRel relCMCM)
| Method Detail |
|---|
public java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> getNodes()
IGraph
getNodes in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>public java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> getRoots()
IGraph
getRoots in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>public java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> getPreds(Pair<Ctxt,joeq.Class.jq_Method> cm)
IGraph
getPreds in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>cm - A node.
public java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> getSuccs(Pair<Ctxt,joeq.Class.jq_Method> cm)
IGraph
getSuccs in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>cm - A node.
public boolean hasNode(Pair<Ctxt,joeq.Class.jq_Method> node)
IGraph
hasNode in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>node - A node.
public boolean hasRoot(Pair<Ctxt,joeq.Class.jq_Method> node)
IGraph
hasRoot in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>node - A node.
public int numSuccs(Pair<Ctxt,joeq.Class.jq_Method> node)
IGraph
numSuccs in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>node - A node.
public java.util.Set<Ctxt> getContexts(joeq.Class.jq_Method jq_Method)
ICSCG
getContexts in interface ICSCGjq_Method - A method.
public java.util.Set<Pair<Ctxt,joeq.Compiler.Quad.Quad>> getCallers(Ctxt ctxt,
joeq.Class.jq_Method meth)
ICSCG
getCallers in interface ICSCGctxt - An abstract context.meth - A jq_Method.
public java.util.Set<Pair<Ctxt,joeq.Class.jq_Method>> getTargets(Ctxt ctxt,
joeq.Compiler.Quad.Quad invk)
ICSCG
getTargets in interface ICSCGctxt - An abstract context.invk - A call site.
public java.util.Set<joeq.Compiler.Quad.Quad> getLabels(Pair<Ctxt,joeq.Class.jq_Method> origNode,
Pair<Ctxt,joeq.Class.jq_Method> destNode)
ILabeledGraph
getLabels in interface ILabeledGraph<Pair<Ctxt,joeq.Class.jq_Method>,joeq.Compiler.Quad.Quad>origNode - The source node of the edge.destNode - The target node of the edge.
public boolean hasEdge(Pair<Ctxt,joeq.Class.jq_Method> node1,
Pair<Ctxt,joeq.Class.jq_Method> node2)
IGraph
hasEdge in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>node1 - A node.node2 - A node.
public int numRoots()
IGraph
numRoots in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>public int numNodes()
IGraph
numNodes in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>public int numPreds(Pair<Ctxt,joeq.Class.jq_Method> node)
IGraph
numPreds in interface IGraph<Pair<Ctxt,joeq.Class.jq_Method>>node - A node.
public boolean calls(Ctxt origCtxt,
joeq.Compiler.Quad.Quad origInvk,
Ctxt destCtxt,
joeq.Class.jq_Method destMeth)
ICSCG
calls in interface ICSCGorigCtxt - An abstract context.origInvk - A jq_Method invocation site.destCtxt - An abstract context.destMeth - A jq_Method.
public void free()
This jq_Method must be called after clients are done exercising the interface of this call graph.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||