Static Value-Flow Analysis
|
#include <CFLSolver.h>
Public Types | |
typedef FIFOWorkList< const CFLEdge * > | WorkList |
Define worklist. | |
typedef CFGrammar::Production | Production |
typedef CFGrammar::Symbol | Symbol |
Public Member Functions | |
CFLSolver (CFLGraph *_graph, CFGrammar *_grammar) | |
virtual | ~CFLSolver () |
virtual void | initialize () |
Initialize worklist. | |
virtual void | processCFLEdge (const CFLEdge *Y_edge) |
Process CFLEdge. | |
virtual void | solve () |
Start solving. | |
const CFLGraph * | getGraph () const |
Return CFL Graph. | |
const CFGrammar * | getGrammar () const |
Return CFL Grammar. | |
virtual bool | pushIntoWorklist (const CFLEdge *item) |
virtual bool | isWorklistEmpty () |
Static Public Attributes | |
static double | numOfChecks = 0 |
Protected Member Functions | |
const CFLEdge * | popFromWorklist () |
Worklist operations. | |
bool | isInWorklist (const CFLEdge *item) |
Protected Attributes | |
CFLGraph * | graph |
CFGrammar * | grammar |
WorkList | worklist |
Worklist for resolution. | |
Definition at line 43 of file CFLSolver.h.
Definition at line 49 of file CFLSolver.h.
Definition at line 50 of file CFLSolver.h.
Define worklist.
Definition at line 48 of file CFLSolver.h.
Definition at line 54 of file CFLSolver.h.
|
inlinevirtual |
Definition at line 58 of file CFLSolver.h.
|
virtual |
Initialize worklist.
Foreach production X -> epsilon add X(i,i) if not exist to E and to worklist
Reimplemented in SVF::POCRSolver, and SVF::POCRHybridSolver.
Definition at line 36 of file CFLSolver.cpp.
Definition at line 101 of file CFLSolver.h.
Definition at line 88 of file CFLSolver.h.
Worklist operations.
Definition at line 96 of file CFLSolver.h.
Process CFLEdge.
For each production X -> Y add X(i,j) if not exist to E and to worklist
For each production X -> Y Z Foreach outgoing edge Z(j,k) from node j do add X(i,k) if not exist to E and to worklist
For each production X -> Z Y Foreach incoming edge Z(k,i) to node i do add X(k,j) if not exist to E and to worklist
Reimplemented in SVF::POCRSolver, and SVF::POCRHybridSolver.
Definition at line 62 of file CFLSolver.cpp.
Definition at line 84 of file CFLSolver.h.
|
virtual |
Start solving.
initial worklist
Select and remove an edge Y(i,j) from worklist
Definition at line 119 of file CFLSolver.cpp.
|
protected |
Definition at line 109 of file CFLSolver.h.
|
protected |
Definition at line 108 of file CFLSolver.h.
|
static |
Definition at line 52 of file CFLSolver.h.
|
protected |
Worklist for resolution.
Definition at line 111 of file CFLSolver.h.