|
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 44 of file CFLSolver.h.
Definition at line 50 of file CFLSolver.h.
Definition at line 51 of file CFLSolver.h.
Define worklist.
Definition at line 49 of file CFLSolver.h.
Definition at line 55 of file CFLSolver.h.
|
inlinevirtual |
Definition at line 59 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 102 of file CFLSolver.h.
Definition at line 89 of file CFLSolver.h.
Worklist operations.
Definition at line 97 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 85 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 110 of file CFLSolver.h.
|
protected |
Definition at line 109 of file CFLSolver.h.
|
static |
Definition at line 53 of file CFLSolver.h.
|
protected |
Worklist for resolution.
Definition at line 112 of file CFLSolver.h.