Static Value-Flow Analysis
|
#include "AE/Core/AbstractState.h"
#include "Graphs/SVFG.h"
#include "SVF-LLVM/LLVMUtil.h"
#include "SVF-LLVM/SVFIRBuilder.h"
#include "Util/CommandLine.h"
#include "Util/Options.h"
#include "WPA/Andersen.h"
Go to the source code of this file.
Functions | |
SVF::AliasResult | aliasQuery (PointerAnalysis *pta, const SVFValue *v1, const SVFValue *v2) |
std::string | printPts (PointerAnalysis *pta, const SVFValue *svfval) |
void | traverseOnICFG (ICFG *icfg, const ICFGNode *iNode) |
void | dummyVisit (const VFGNode *node) |
void | traverseOnVFG (const SVFG *vfg, const SVFValue *svfval) |
int | main (int argc, char **argv) |
SVF::AliasResult aliasQuery | ( | PointerAnalysis * | pta, |
const SVFValue * | v1, | ||
const SVFValue * | v2 | ||
) |
An example to query alias results of two SVF values
Definition at line 44 of file svf-ex.cpp.
void dummyVisit | ( | const VFGNode * | node | ) |
Definition at line 101 of file svf-ex.cpp.
int main | ( | int | argc, |
char ** | argv | ||
) |
Build Program Assignment Graph (SVFIR)
Create Andersen's pointer analysis
Call Graph
ICFG
Value-Flow Graph (VFG)
Sparse value-flow graph (SVFG)
Collect uses of an LLVM Value
Print points-to information
Collect all successor nodes on ICFG
Definition at line 147 of file svf-ex.cpp.
std::string printPts | ( | PointerAnalysis * | pta, |
const SVFValue * | svfval | ||
) |
An example to print points-to set of an SVF value
Definition at line 52 of file svf-ex.cpp.
An example to query/collect all successor nodes from a ICFGNode (iNode) along control-flow graph (ICFG)
Traverse along VFG
Definition at line 77 of file svf-ex.cpp.
An example to query/collect all the uses of a definition of a value along value-flow graph (VFG)
Traverse along VFG
Collect all LLVM Values
can only query VFGNode involving top-level pointers (starting with % or @ in LLVM IR) PAGNode* pNode = vfg->getLHSTopLevPtr(node); Value* val = pNode->getValue();
Definition at line 108 of file svf-ex.cpp.