public class BackwardsInterproceduralCFG extends java.lang.Object implements BiDiInterproceduralCFG<Unit,SootMethod>
JimpleBasedInterproceduralCFG but based on inverted unit graphs.
This should be used for backward analyses.| Modifier and Type | Field and Description |
|---|---|
protected BiDiInterproceduralCFG<Unit,SootMethod> |
delegate |
| Constructor and Description |
|---|
BackwardsInterproceduralCFG(BiDiInterproceduralCFG<Unit,SootMethod> fwICFG) |
| Modifier and Type | Method and Description |
|---|---|
java.util.Set<Unit> |
allNonCallEndNodes() |
java.util.Set<Unit> |
allNonCallStartNodes()
Returns the set of all nodes that are neither call nor start nodes.
|
java.util.Collection<SootMethod> |
getCalleesOfCallAt(Unit n)
Returns all callee methods for a given call.
|
java.util.Collection<Unit> |
getCallersOf(SootMethod m)
Returns all caller statements/nodes of a given method.
|
java.util.Set<Unit> |
getCallsFromWithin(SootMethod m)
Returns all call sites within a given method.
|
java.util.Collection<Unit> |
getEndPointsOf(SootMethod m) |
SootMethod |
getMethodOf(Unit n)
Returns the method containing a node.
|
DirectedGraph<Unit> |
getOrCreateUnitGraph(SootMethod m) |
java.util.List<Value> |
getParameterRefs(SootMethod m) |
java.util.List<Unit> |
getPredsOf(Unit u) |
java.util.List<Unit> |
getPredsOfCallAt(Unit u) |
java.util.List<Unit> |
getReturnSitesOfCallAt(Unit n)
Returns all statements to which a call could return.
|
java.util.Collection<Unit> |
getStartPointsOf(SootMethod m)
Returns all start points of a given method.
|
java.util.List<Unit> |
getSuccsOf(Unit n)
Returns the successor nodes.
|
boolean |
isBranchTarget(Unit stmt,
Unit succ)
Returns whether succ is a branch target of stmt.
|
boolean |
isCallStmt(Unit stmt)
Returns
true if the given statement is a call site. |
boolean |
isExitStmt(Unit stmt)
Returns
true if the given statement leads to a method return
(exceptional or not). |
boolean |
isFallThroughSuccessor(Unit stmt,
Unit succ)
Returns whether succ is the fall-through successor of stmt,
i.e., the unique successor that is be reached when stmt
does not branch.
|
boolean |
isReachable(Unit u)
Checks whether the given statement is rachable from the entry point
|
boolean |
isReturnSite(Unit n)
Gets whether the given statement is a return site of at least one call
|
boolean |
isStartPoint(Unit stmt)
Returns true is this is a method's start statement.
|
protected final BiDiInterproceduralCFG<Unit,SootMethod> delegate
public BackwardsInterproceduralCFG(BiDiInterproceduralCFG<Unit,SootMethod> fwICFG)
public java.util.List<Unit> getSuccsOf(Unit n)
InterproceduralCFGgetSuccsOf in interface InterproceduralCFG<Unit,SootMethod>public java.util.Collection<Unit> getStartPointsOf(SootMethod m)
InterproceduralCFGgetStartPointsOf in interface InterproceduralCFG<Unit,SootMethod>public java.util.List<Unit> getReturnSitesOfCallAt(Unit n)
InterproceduralCFGgetReturnSitesOfCallAt in interface InterproceduralCFG<Unit,SootMethod>public boolean isExitStmt(Unit stmt)
InterproceduralCFGtrue if the given statement leads to a method return
(exceptional or not). For backward analyses may also be start statements.isExitStmt in interface InterproceduralCFG<Unit,SootMethod>public boolean isStartPoint(Unit stmt)
InterproceduralCFGisStartPoint in interface InterproceduralCFG<Unit,SootMethod>public java.util.Set<Unit> allNonCallStartNodes()
InterproceduralCFGallNonCallStartNodes in interface InterproceduralCFG<Unit,SootMethod>public java.util.List<Unit> getPredsOf(Unit u)
getPredsOf in interface InterproceduralCFG<Unit,SootMethod>getPredsOf in interface BiDiInterproceduralCFG<Unit,SootMethod>public java.util.Collection<Unit> getEndPointsOf(SootMethod m)
getEndPointsOf in interface BiDiInterproceduralCFG<Unit,SootMethod>public java.util.List<Unit> getPredsOfCallAt(Unit u)
getPredsOfCallAt in interface BiDiInterproceduralCFG<Unit,SootMethod>public java.util.Set<Unit> allNonCallEndNodes()
allNonCallEndNodes in interface BiDiInterproceduralCFG<Unit,SootMethod>public SootMethod getMethodOf(Unit n)
InterproceduralCFGgetMethodOf in interface InterproceduralCFG<Unit,SootMethod>n - The node for which to get the parent methodpublic java.util.Collection<SootMethod> getCalleesOfCallAt(Unit n)
InterproceduralCFGgetCalleesOfCallAt in interface InterproceduralCFG<Unit,SootMethod>public java.util.Collection<Unit> getCallersOf(SootMethod m)
InterproceduralCFGgetCallersOf in interface InterproceduralCFG<Unit,SootMethod>public java.util.Set<Unit> getCallsFromWithin(SootMethod m)
InterproceduralCFGgetCallsFromWithin in interface InterproceduralCFG<Unit,SootMethod>public boolean isCallStmt(Unit stmt)
InterproceduralCFGtrue if the given statement is a call site.isCallStmt in interface InterproceduralCFG<Unit,SootMethod>public DirectedGraph<Unit> getOrCreateUnitGraph(SootMethod m)
getOrCreateUnitGraph in interface BiDiInterproceduralCFG<Unit,SootMethod>public java.util.List<Value> getParameterRefs(SootMethod m)
getParameterRefs in interface BiDiInterproceduralCFG<Unit,SootMethod>public boolean isFallThroughSuccessor(Unit stmt, Unit succ)
InterproceduralCFGisFallThroughSuccessor in interface InterproceduralCFG<Unit,SootMethod>public boolean isBranchTarget(Unit stmt, Unit succ)
InterproceduralCFGisBranchTarget in interface InterproceduralCFG<Unit,SootMethod>public boolean isReturnSite(Unit n)
BiDiInterproceduralCFGisReturnSite in interface BiDiInterproceduralCFG<Unit,SootMethod>n - The statement to checkpublic boolean isReachable(Unit u)
BiDiInterproceduralCFGisReachable in interface BiDiInterproceduralCFG<Unit,SootMethod>u - The statement to check