Skip to content

Commit a64c055

Browse files
committed
sync with SVF
1 parent b55c142 commit a64c055

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

Assignment-1/Tests/test.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@
99
using namespace std;
1010

1111
void TestICFG(std::vector<std::string>& moduleNameVec) {
12-
SVFModule* svfModule = LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
12+
LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
1313

1414
/// Build Program Assignment Graph (SVFIR)
15-
SVFIRBuilder builder(svfModule);
15+
SVFIRBuilder builder;
1616
SVFIR* pag = builder.build();
1717
ICFG* icfg = pag->getICFG();
1818
// If you want to test your own case, please change the dump name
@@ -46,8 +46,8 @@ void TestICFG(std::vector<std::string>& moduleNameVec) {
4646
}
4747

4848
void TestPTA(std::vector<std::string>& moduleNameVec) {
49-
SVFModule* svfModule = LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
50-
SVF::SVFIRBuilder builder(svfModule);
49+
LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
50+
SVF::SVFIRBuilder builder;
5151
SVF::SVFIR* pag = builder.build();
5252
AndersenPTA* andersenPTA = new AndersenPTA(pag);
5353
andersenPTA->analyze();
@@ -57,9 +57,9 @@ void TestPTA(std::vector<std::string>& moduleNameVec) {
5757
}
5858

5959
void TestTaint(std::vector<std::string>& moduleNameVec) {
60-
SVFModule* svfModule = LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
60+
LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
6161
/// Build Program Assignment Graph (SVFIR)
62-
SVF::SVFIRBuilder builder(svfModule);
62+
SVF::SVFIRBuilder builder;
6363
SVF::SVFIR* pag = builder.build();
6464

6565
ICFGTraversal* taint = new ICFGTraversal(pag);

Assignment-2/Tests/test-sse.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ int main(int argc, char** argv) {
3535
"Software-Verification-Teaching Assignment 4",
3636
"[options] <input-bitcode...>");
3737

38-
SVFModule* svfModule = LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
38+
LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
3939
LLVMModuleSet::getLLVMModuleSet()->dumpModulesToFile(".svf");
4040

41-
SVFIRBuilder builder(svfModule);
41+
SVFIRBuilder builder;
4242
SVFIR* svfir = builder.build();
4343

4444
CallGraph* callgraph = AndersenWaveDiff::createAndersenWaveDiff(svfir)->getCallGraph();

Assignment-3/Tests/test-ae.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ int main(int argc, char** argv) {
2828
OptionBase::parseOptions(arg_num, arg_value, "Static Symbolic Execution", "[options] <input-bitcode...>");
2929
delete[] arg_value;
3030

31-
SVFModule* svfModule = LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
32-
SVFIRBuilder builder(svfModule);
31+
LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
32+
SVFIRBuilder builder;
3333
SVFIR* pag = builder.build();
3434
AndersenWaveDiff* ander = AndersenWaveDiff::createAndersenWaveDiff(pag);
3535
CallGraph* callgraph = ander->getCallGraph();

SVFIR/SVFIR.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,10 @@ int main(int argc, char** argv) {
5353

5454
moduleNameVec = OptionBase::parseOptions(arg_num, arg_value, "SVF IR", "[options] <input-bitcode...>");
5555

56-
SVFModule* svfModule = LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
56+
LLVMModuleSet::getLLVMModuleSet()->buildSVFModule(moduleNameVec);
5757

5858
/// Build Program Assignment Graph (SVFIR or PAG)
59-
SVFIRBuilder builder(svfModule);
59+
SVFIRBuilder builder;
6060
SVFIR* pag = builder.build();
6161
// Dump pag
6262
pag->dump(pag->getModuleIdentifier() + ".pag");

0 commit comments

Comments
 (0)