Class FlowGraphBuilder
java.lang.Object
com.ibm.wala.cast.js.callgraph.fieldbased.flowgraph.FlowGraphBuilder
- Direct Known Subclasses:
FilteredFlowGraphBuilder
Class for building intra-procedural flow graphs for a given class hierarchy.
- Author:
- mschaefer
-
Constructor Summary
ConstructorDescriptionFlowGraphBuilder
(IClassHierarchy cha, IAnalysisCacheView cache, boolean supportPointerAnalysis) -
Method Summary
Modifier and TypeMethodDescriptionThis is the main entry point of the flow graph builder.void
visitFunction
(FlowGraph flowgraph, IMethod method) void
visitProgram
(FlowGraph flowgraph)
-
Constructor Details
-
FlowGraphBuilder
public FlowGraphBuilder(IClassHierarchy cha, IAnalysisCacheView cache, boolean supportPointerAnalysis)
-
-
Method Details
-
buildFlowGraph
This is the main entry point of the flow graph builder.It creates a new, empty flow graph, adds nodes for a small number of special primitive functions such as
Object
andFunction
and sets up flow edges to make them flow into the corresponding global variables. Then it iterates over all functions in the class hierarchy and all their IR instructions, and adds the flow edges induced by these instructions.- Returns:
- the completed flow graph
-
visitProgram
-
visitFunction
-