|
Static Value-Flow Analysis
|
#include <CDG.h>
Public Types | |
| typedef Map< NodeID, CDGNode * > | CDGNodeIDToNodeMapTy |
| typedef CDGEdge::CDGEdgeSetTy | CDGEdgeSetTy |
| typedef CDGNodeIDToNodeMapTy::iterator | iterator |
| typedef CDGNodeIDToNodeMapTy::const_iterator | const_iterator |
| typedef std::vector< const ICFGNode * > | ICFGNodeVector |
| typedef std::vector< std::pair< const ICFGNode *, const ICFGNode * > > | ICFGNodePairVector |
Public Types inherited from SVF::GenericGraph< NodeTy, EdgeTy > | |
| typedef NodeTy | NodeType |
| typedef EdgeTy | EdgeType |
| typedef OrderedMap< NodeID, NodeType * > | IDToNodeMapTy |
| NodeID to GenericNode map. | |
| typedef IDToNodeMapTy::iterator | iterator |
| Node Iterators. | |
| typedef IDToNodeMapTy::const_iterator | const_iterator |
Public Member Functions | |
| virtual | ~CDG () |
| Destructor. | |
| CDGNode * | getCDGNode (NodeID id) const |
| Get a CDG node. | |
| bool | hasCDGNode (NodeID id) const |
| Whether has the CDGNode. | |
| bool | hasCDGEdge (CDGNode *src, CDGNode *dst) |
| Whether we has a CDG edge. | |
| CDGEdge * | getCDGEdge (const CDGNode *src, const CDGNode *dst) |
| Get a control dependence edge according to src and dst. | |
| void | view () |
| View graph from the debugger. | |
| void | dump (const std::string &filename) |
| Dump graph into dot file. | |
| void | removeCDGEdge (CDGEdge *edge) |
| Remove a control dependence edge. | |
| void | removeCDGNode (CDGNode *node) |
| Remove a CDGNode. | |
| bool | removeCDGNode (NodeID id) |
| Remove node from nodeID. | |
| bool | addCDGEdge (CDGEdge *edge) |
| Add CDG edge. | |
| virtual void | addCDGNode (CDGNode *node) |
| Add a CDG node. | |
| void | addCDGNodesFromVector (ICFGNodeVector nodes) |
| Add CDG nodes from nodeid vector. | |
| void | addCDGEdgeFromSrcDst (const ICFGNode *src, const ICFGNode *dst, const SVFVar *pNode, s32_t branchID) |
| Add CDG edges from nodeid pair. | |
Public Member Functions inherited from SVF::GenericGraph< NodeTy, EdgeTy > | |
| GenericGraph () | |
| Constructor. | |
| virtual | ~GenericGraph () |
| Destructor. | |
| void | destroy () |
| Release memory. | |
| iterator | begin () |
| Iterators. | |
| iterator | end () |
| const_iterator | begin () const |
| const_iterator | end () const |
| void | addGNode (NodeID id, NodeType *node) |
| Add a Node. | |
| NodeType * | getGNode (NodeID id) const |
| Get a node. | |
| bool | hasGNode (NodeID id) const |
| Has a node. | |
| void | removeGNode (NodeType *node) |
| Delete a node. | |
| u32_t | getTotalNodeNum () const |
| Get total number of node/edge. | |
| u32_t | getTotalEdgeNum () const |
| void | incNodeNum () |
| Increase number of node/edge. | |
| void | incEdgeNum () |
Static Public Member Functions | |
| static CDG * | getCDG () |
| Singleton design here to make sure we only have one instance during any analysis. | |
| static void | releaseCDG () |
Private Member Functions | |
| CDG () | |
| Constructor. | |
Static Private Attributes | |
| static CDG * | controlDg = nullptr |
Additional Inherited Members | |
Public Attributes inherited from SVF::GenericGraph< NodeTy, EdgeTy > | |
| u32_t | edgeNum |
| total num of node | |
| u32_t | nodeNum |
| total num of edge | |
Protected Attributes inherited from SVF::GenericGraph< NodeTy, EdgeTy > | |
| IDToNodeMapTy | IDToNodeMap |
| node map | |
| typedef CDGNodeIDToNodeMapTy::const_iterator SVF::CDG::const_iterator |
| typedef std::vector<const ICFGNode *> SVF::CDG::ICFGNodeVector |
| typedef CDGNodeIDToNodeMapTy::iterator SVF::CDG::iterator |
Add CDG edge.
| void CDG::addCDGEdgeFromSrcDst | ( | const ICFGNode * | src, |
| const ICFGNode * | dst, | ||
| const SVFVar * | pNode, | ||
| s32_t | branchID | ||
| ) |
Add CDG edges from nodeid pair.
Definition at line 35 of file CDG.cpp.
|
inline |
Add CDG nodes from nodeid vector.
Definition at line 296 of file CDG.h.
|
inline |
Dump graph into dot file.
Definition at line 240 of file CDG.h.
Get a CDG node.
Definition at line 187 of file CDG.h.
Whether we has a CDG edge.
|
inlinestatic |
|
inline |
|
inline |
Remove a CDGNode.
Definition at line 255 of file CDG.h.
|
inline |
View graph from the debugger.
Definition at line 234 of file CDG.h.