Package com.tonic.analysis.pdg.sdg
Class SDGBuilder
- java.lang.Object
-
- com.tonic.analysis.pdg.sdg.SDGBuilder
-
public class SDGBuilder extends Object
A builder for a system dependence graph, stitching per-method PDGs together over a call graph.
-
-
Constructor Summary
Constructors Constructor Description SDGBuilder(CallGraph callGraph, Map<MethodReference,IRMethod> irMethods)Creates a builder over the given call graph and method bodies.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static SDGbuild(CallGraph callGraph, Map<MethodReference,IRMethod> irMethods)Builds the system dependence graph, linking each method's PDG through call, parameter and summary edges.CallGraphgetCallGraph()Map<InvokeInstruction,SDGCallNode>getInvokeToCallNode()Map<MethodReference,IRMethod>getIrMethods()SDGgetSdg()
-
-
-
Constructor Detail
-
SDGBuilder
public SDGBuilder(CallGraph callGraph, Map<MethodReference,IRMethod> irMethods)
Creates a builder over the given call graph and method bodies.- Parameters:
callGraph- the call graph supplying caller/callee relationshipsirMethods- the SSA form of every method to include, keyed by reference
-
-
Method Detail
-
getCallGraph
public CallGraph getCallGraph()
- Returns:
- the call graph
-
getIrMethods
public Map<MethodReference,IRMethod> getIrMethods()
- Returns:
- the ir methods
-
getSdg
public SDG getSdg()
- Returns:
- the sdg
-
getInvokeToCallNode
public Map<InvokeInstruction,SDGCallNode> getInvokeToCallNode()
- Returns:
- the invoke to call node
-
build
public static SDG build(CallGraph callGraph, Map<MethodReference,IRMethod> irMethods)
Builds the system dependence graph, linking each method's PDG through call, parameter and summary edges.- Parameters:
callGraph- the call graph supplying caller/callee relationshipsirMethods- the SSA form of every method to include, keyed by reference- Returns:
- the completed system dependence graph
-
-