-
Notifications
You must be signed in to change notification settings - Fork 481
Open
Description
I wish to run context-sensitive pointer analysis using SVF. However, I am unable to find the way to do so even after looking at the wiki.
Currently I am trying to run Demand-Driven Points-To analysis, as follows:
"$LLVM_PATH/opt" -S -passes='internalize,globaldce' -internalize-public-api-list=main $filepath.bc -o $filepath.opt.bc
"$SVF_PATH/dvf" -query=all -cpts -cxt -print-all-pts -dump-callgraph $filepath.opt.bc > $filepath.pta`The documentation states that the -cxt flag enables Demand-driven context- flow- sensitive analysis, but on analyzing the following program:
#include <iostream>
struct Obj {
int value;
};
Obj* id(Obj* p) {
// Identity function
return p;
}
int main() {
Obj a;
Obj b;
Obj* pa = id(&a); // Call context 1
Obj* pb = id(&b); // Call context 2
return 0;
}The SVF output reports that pa points to {a,b}, which is context-insensitive output.
Metadata
Metadata
Assignees
Labels
No labels