svf-tools 1.0.333 → 1.0.334
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/SVF-doxygen/html/html/ConsG_8cpp_source.html +16 -7
- package/SVF-doxygen/html/html/ContextDDA_8cpp_source.html +1 -1
- package/SVF-doxygen/html/html/FlowDDA_8cpp_source.html +1 -1
- package/SVF-doxygen/html/html/FlowSensitiveTBHC_8cpp_source.html +1 -1
- package/SVF-doxygen/html/html/FlowSensitive_8cpp_source.html +1 -1
- package/SVF-doxygen/html/html/Graph2Json_8cpp_source.html +2 -2
- package/SVF-doxygen/html/html/IRGraph_8cpp_source.html +2 -2
- package/SVF-doxygen/html/html/MSSAMuChi_8h_source.html +2 -2
- package/SVF-doxygen/html/html/MemRegion_8cpp_source.html +4 -4
- package/SVF-doxygen/html/html/MemRegion_8h_source.html +2 -2
- package/SVF-doxygen/html/html/MemSSA_8cpp_source.html +2 -2
- package/SVF-doxygen/html/html/MemSSA_8h_source.html +2 -2
- package/SVF-doxygen/html/html/PAGBuilderFromFile_8cpp_source.html +2 -2
- package/SVF-doxygen/html/html/SVFG_8cpp_source.html +1 -1
- package/SVF-doxygen/html/html/SVFIRBuilder_8cpp_source.html +4 -4
- package/SVF-doxygen/html/html/SVFIRBuilder_8h_source.html +16 -16
- package/SVF-doxygen/html/html/SVFIR_8cpp_source.html +22 -22
- package/SVF-doxygen/html/html/SVFIR_8h_source.html +16 -16
- package/SVF-doxygen/html/html/SVFStatements_8cpp_source.html +1 -1
- package/SVF-doxygen/html/html/SVFStatements_8h.html +14 -12
- package/SVF-doxygen/html/html/SVFStatements_8h_source.html +131 -122
- package/SVF-doxygen/html/html/VFGNode_8h_source.html +11 -11
- package/SVF-doxygen/html/html/VFG_8cpp_source.html +18 -18
- package/SVF-doxygen/html/html/VFG_8h_source.html +17 -16
- package/SVF-doxygen/html/html/annotated.html +271 -270
- package/SVF-doxygen/html/html/classSVF_1_1AddrStmt-members.html +16 -10
- package/SVF-doxygen/html/html/classSVF_1_1AddrStmt.html +36 -14
- package/SVF-doxygen/html/html/classSVF_1_1AddrStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1AssignStmt-members.html +145 -0
- package/SVF-doxygen/html/html/classSVF_1_1AssignStmt.html +770 -0
- package/SVF-doxygen/html/html/classSVF_1_1AssignStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1BinaryOPStmt-members.html +7 -11
- package/SVF-doxygen/html/html/classSVF_1_1BinaryOPStmt.html +19 -138
- package/SVF-doxygen/html/html/classSVF_1_1BranchStmt-members.html +2 -2
- package/SVF-doxygen/html/html/classSVF_1_1BranchStmt.html +39 -39
- package/SVF-doxygen/html/html/classSVF_1_1BranchVFGNode.html +3 -3
- package/SVF-doxygen/html/html/classSVF_1_1CallPE-members.html +19 -13
- package/SVF-doxygen/html/html/classSVF_1_1CallPE.html +43 -21
- package/SVF-doxygen/html/html/classSVF_1_1CallPE.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1CmpStmt-members.html +7 -11
- package/SVF-doxygen/html/html/classSVF_1_1CmpStmt.html +20 -139
- package/SVF-doxygen/html/html/classSVF_1_1ConstraintGraph.html +16 -9
- package/SVF-doxygen/html/html/classSVF_1_1ContextDDA.html +1 -1
- package/SVF-doxygen/html/html/classSVF_1_1CopyStmt-members.html +16 -10
- package/SVF-doxygen/html/html/classSVF_1_1CopyStmt.html +36 -14
- package/SVF-doxygen/html/html/classSVF_1_1CopyStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1FlowDDA.html +1 -1
- package/SVF-doxygen/html/html/classSVF_1_1FlowSensitive.html +1 -1
- package/SVF-doxygen/html/html/classSVF_1_1FlowSensitiveTBHC.html +1 -1
- package/SVF-doxygen/html/html/classSVF_1_1GenericEdge.html +3 -9
- package/SVF-doxygen/html/html/classSVF_1_1GenericEdge.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1GepStmt-members.html +16 -10
- package/SVF-doxygen/html/html/classSVF_1_1GepStmt.html +41 -19
- package/SVF-doxygen/html/html/classSVF_1_1GepStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1ICFGPrinter.html +2 -2
- package/SVF-doxygen/html/html/classSVF_1_1LoadStmt-members.html +16 -10
- package/SVF-doxygen/html/html/classSVF_1_1LoadStmt.html +36 -14
- package/SVF-doxygen/html/html/classSVF_1_1LoadStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1MRGenerator.html +8 -8
- package/SVF-doxygen/html/html/classSVF_1_1MemSSA.html +6 -6
- package/SVF-doxygen/html/html/classSVF_1_1MultiOpndStmt-members.html +36 -29
- package/SVF-doxygen/html/html/classSVF_1_1MultiOpndStmt.html +250 -31
- package/SVF-doxygen/html/html/classSVF_1_1NormalGepStmt-members.html +17 -11
- package/SVF-doxygen/html/html/classSVF_1_1NormalGepStmt.html +39 -17
- package/SVF-doxygen/html/html/classSVF_1_1NormalGepStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1PAGBuilderFromFile.html +2 -2
- package/SVF-doxygen/html/html/classSVF_1_1PhiStmt-members.html +5 -9
- package/SVF-doxygen/html/html/classSVF_1_1PhiStmt.html +18 -137
- package/SVF-doxygen/html/html/classSVF_1_1RetPE-members.html +16 -10
- package/SVF-doxygen/html/html/classSVF_1_1RetPE.html +43 -21
- package/SVF-doxygen/html/html/classSVF_1_1RetPE.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1SVFG.html +1 -1
- package/SVF-doxygen/html/html/classSVF_1_1SVFIR.html +23 -23
- package/SVF-doxygen/html/html/classSVF_1_1SVFIRBuilder.html +5 -5
- package/SVF-doxygen/html/html/classSVF_1_1SVFStmt.html +12 -8
- package/SVF-doxygen/html/html/classSVF_1_1SVFStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1StoreStmt-members.html +16 -10
- package/SVF-doxygen/html/html/classSVF_1_1StoreStmt.html +36 -14
- package/SVF-doxygen/html/html/classSVF_1_1StoreStmt.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1TDForkPE-members.html +18 -12
- package/SVF-doxygen/html/html/classSVF_1_1TDForkPE.html +35 -13
- package/SVF-doxygen/html/html/classSVF_1_1TDForkPE.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1TDJoinPE-members.html +17 -11
- package/SVF-doxygen/html/html/classSVF_1_1TDJoinPE.html +35 -13
- package/SVF-doxygen/html/html/classSVF_1_1TDJoinPE.png +0 -0
- package/SVF-doxygen/html/html/classSVF_1_1UnaryOPStmt-members.html +2 -2
- package/SVF-doxygen/html/html/classSVF_1_1UnaryOPStmt.html +32 -32
- package/SVF-doxygen/html/html/classSVF_1_1VFG.html +27 -27
- package/SVF-doxygen/html/html/classSVF_1_1VariantGepStmt-members.html +17 -11
- package/SVF-doxygen/html/html/classSVF_1_1VariantGepStmt.html +37 -15
- package/SVF-doxygen/html/html/classSVF_1_1VariantGepStmt.png +0 -0
- package/SVF-doxygen/html/html/classes.html +91 -93
- package/SVF-doxygen/html/html/functions_a.html +10 -7
- package/SVF-doxygen/html/html/functions_c.html +16 -15
- package/SVF-doxygen/html/html/functions_func.html +7 -4
- package/SVF-doxygen/html/html/functions_func_c.html +24 -23
- package/SVF-doxygen/html/html/functions_func_g.html +26 -18
- package/SVF-doxygen/html/html/functions_func_o.html +5 -3
- package/SVF-doxygen/html/html/functions_func_t.html +1 -0
- package/SVF-doxygen/html/html/functions_g.html +30 -22
- package/SVF-doxygen/html/html/functions_l.html +5 -5
- package/SVF-doxygen/html/html/functions_m.html +1 -1
- package/SVF-doxygen/html/html/functions_o.html +14 -12
- package/SVF-doxygen/html/html/functions_p.html +18 -14
- package/SVF-doxygen/html/html/functions_r.html +2 -2
- package/SVF-doxygen/html/html/functions_s.html +10 -12
- package/SVF-doxygen/html/html/functions_t.html +4 -3
- package/SVF-doxygen/html/html/functions_v.html +3 -3
- package/SVF-doxygen/html/html/hierarchy.html +17 -16
- package/SVF-doxygen/html/html/namespaceSVF.html +2 -0
- package/SVF-doxygen/html/html/search/all_1.js +1 -0
- package/SVF-doxygen/html/html/search/all_10.js +6 -6
- package/SVF-doxygen/html/html/search/all_12.js +2 -2
- package/SVF-doxygen/html/html/search/all_13.js +7 -7
- package/SVF-doxygen/html/html/search/all_14.js +7 -7
- package/SVF-doxygen/html/html/search/all_15.js +1 -1
- package/SVF-doxygen/html/html/search/all_16.js +2 -2
- package/SVF-doxygen/html/html/search/all_3.js +2 -2
- package/SVF-doxygen/html/html/search/all_7.js +8 -4
- package/SVF-doxygen/html/html/search/all_c.js +2 -2
- package/SVF-doxygen/html/html/search/all_d.js +1 -1
- package/SVF-doxygen/html/html/search/all_e.js +2 -2
- package/SVF-doxygen/html/html/search/all_f.js +3 -3
- package/SVF-doxygen/html/html/search/classes_0.js +2 -1
- package/SVF-doxygen/html/html/search/functions_0.js +1 -0
- package/SVF-doxygen/html/html/search/functions_11.js +1 -1
- package/SVF-doxygen/html/html/search/functions_2.js +1 -1
- package/SVF-doxygen/html/html/search/functions_6.js +8 -4
- package/SVF-doxygen/html/html/search/functions_b.js +1 -1
- package/SVF-doxygen/html/html/search/functions_d.js +1 -1
- package/SVF-doxygen/html/html/search/variables_14.js +3 -3
- package/SVF-doxygen/html/html/search/variables_15.js +1 -1
- package/SVF-doxygen/html/html/search/variables_e.js +2 -2
- package/SVF-doxygen/html/html/structllvm_1_1DOTGraphTraits_3_01IRGraph_01_5_01_4.html +2 -2
- package/include/Graphs/VFG.h +4 -4
- package/include/MemoryModel/SVFStatements.h +379 -310
- package/lib/Graphs/ConsG.cpp +24 -24
- package/lib/Graphs/VFG.cpp +10 -10
- package/lib/MSSA/MemRegion.cpp +5 -5
- package/lib/MemoryModel/SVFIR.cpp +2 -2
- package/lib/MemoryModel/SVFStatements.cpp +11 -11
- package/package.json +1 -1
package/lib/Graphs/ConsG.cpp
CHANGED
|
@@ -53,16 +53,16 @@ void ConstraintGraph::buildCG()
|
|
|
53
53
|
for (PAGEdge::SVFStmtSetTy::iterator iter = addrs.begin(), eiter =
|
|
54
54
|
addrs.end(); iter != eiter; ++iter)
|
|
55
55
|
{
|
|
56
|
-
|
|
57
|
-
addAddrCGEdge(edge->
|
|
56
|
+
const AddrStmt* edge = SVFUtil::cast<AddrStmt>(*iter);
|
|
57
|
+
addAddrCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
PAGEdge::SVFStmtSetTy& copys = getPAGEdgeSet(PAGEdge::Copy);
|
|
61
61
|
for (PAGEdge::SVFStmtSetTy::iterator iter = copys.begin(), eiter =
|
|
62
62
|
copys.end(); iter != eiter; ++iter)
|
|
63
63
|
{
|
|
64
|
-
|
|
65
|
-
addCopyCGEdge(edge->
|
|
64
|
+
const CopyStmt* edge = SVFUtil::cast<CopyStmt>(*iter);
|
|
65
|
+
addCopyCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
PAGEdge::SVFStmtSetTy& phis = getPAGEdgeSet(PAGEdge::Phi);
|
|
@@ -78,32 +78,32 @@ void ConstraintGraph::buildCG()
|
|
|
78
78
|
for (PAGEdge::SVFStmtSetTy::iterator iter = calls.begin(), eiter =
|
|
79
79
|
calls.end(); iter != eiter; ++iter)
|
|
80
80
|
{
|
|
81
|
-
|
|
82
|
-
addCopyCGEdge(edge->
|
|
81
|
+
const CallPE* edge = SVFUtil::cast<CallPE>(*iter);
|
|
82
|
+
addCopyCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
83
83
|
}
|
|
84
84
|
|
|
85
85
|
PAGEdge::SVFStmtSetTy& rets = getPAGEdgeSet(PAGEdge::Ret);
|
|
86
86
|
for (PAGEdge::SVFStmtSetTy::iterator iter = rets.begin(), eiter =
|
|
87
87
|
rets.end(); iter != eiter; ++iter)
|
|
88
88
|
{
|
|
89
|
-
|
|
90
|
-
addCopyCGEdge(edge->
|
|
89
|
+
const RetPE* edge = SVFUtil::cast<RetPE>(*iter);
|
|
90
|
+
addCopyCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
91
91
|
}
|
|
92
92
|
|
|
93
93
|
PAGEdge::SVFStmtSetTy& tdfks = getPAGEdgeSet(PAGEdge::ThreadFork);
|
|
94
94
|
for (PAGEdge::SVFStmtSetTy::iterator iter = tdfks.begin(), eiter =
|
|
95
95
|
tdfks.end(); iter != eiter; ++iter)
|
|
96
96
|
{
|
|
97
|
-
|
|
98
|
-
addCopyCGEdge(edge->
|
|
97
|
+
const TDForkPE* edge = SVFUtil::cast<TDForkPE>(*iter);
|
|
98
|
+
addCopyCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
99
99
|
}
|
|
100
100
|
|
|
101
101
|
PAGEdge::SVFStmtSetTy& tdjns = getPAGEdgeSet(PAGEdge::ThreadJoin);
|
|
102
102
|
for (PAGEdge::SVFStmtSetTy::iterator iter = tdjns.begin(), eiter =
|
|
103
103
|
tdjns.end(); iter != eiter; ++iter)
|
|
104
104
|
{
|
|
105
|
-
|
|
106
|
-
addCopyCGEdge(edge->
|
|
105
|
+
const TDJoinPE* edge = SVFUtil::cast<TDJoinPE>(*iter);
|
|
106
|
+
addCopyCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
107
107
|
}
|
|
108
108
|
|
|
109
109
|
PAGEdge::SVFStmtSetTy& ngeps = getPAGEdgeSet(PAGEdge::NormalGep);
|
|
@@ -111,7 +111,7 @@ void ConstraintGraph::buildCG()
|
|
|
111
111
|
ngeps.end(); iter != eiter; ++iter)
|
|
112
112
|
{
|
|
113
113
|
NormalGepStmt* edge = SVFUtil::cast<NormalGepStmt>(*iter);
|
|
114
|
-
addNormalGepCGEdge(edge->
|
|
114
|
+
addNormalGepCGEdge(edge->getRHSVarID(),edge->getLHSVarID(),edge->getLocationSet());
|
|
115
115
|
}
|
|
116
116
|
|
|
117
117
|
PAGEdge::SVFStmtSetTy& vgeps = getPAGEdgeSet(PAGEdge::VariantGep);
|
|
@@ -119,23 +119,23 @@ void ConstraintGraph::buildCG()
|
|
|
119
119
|
vgeps.end(); iter != eiter; ++iter)
|
|
120
120
|
{
|
|
121
121
|
VariantGepStmt* edge = SVFUtil::cast<VariantGepStmt>(*iter);
|
|
122
|
-
addVariantGepCGEdge(edge->
|
|
122
|
+
addVariantGepCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
123
123
|
}
|
|
124
124
|
|
|
125
|
-
PAGEdge::SVFStmtSetTy&
|
|
126
|
-
for (PAGEdge::SVFStmtSetTy::iterator iter =
|
|
127
|
-
|
|
125
|
+
PAGEdge::SVFStmtSetTy& loads = getPAGEdgeSet(PAGEdge::Load);
|
|
126
|
+
for (PAGEdge::SVFStmtSetTy::iterator iter = loads.begin(), eiter =
|
|
127
|
+
loads.end(); iter != eiter; ++iter)
|
|
128
128
|
{
|
|
129
|
-
|
|
130
|
-
addLoadCGEdge(edge->
|
|
129
|
+
LoadStmt* edge = SVFUtil::cast<LoadStmt>(*iter);
|
|
130
|
+
addLoadCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
131
131
|
}
|
|
132
132
|
|
|
133
|
-
PAGEdge::SVFStmtSetTy&
|
|
134
|
-
for (PAGEdge::SVFStmtSetTy::iterator iter =
|
|
135
|
-
|
|
133
|
+
PAGEdge::SVFStmtSetTy& stores = getPAGEdgeSet(PAGEdge::Store);
|
|
134
|
+
for (PAGEdge::SVFStmtSetTy::iterator iter = stores.begin(), eiter =
|
|
135
|
+
stores.end(); iter != eiter; ++iter)
|
|
136
136
|
{
|
|
137
|
-
|
|
138
|
-
addStoreCGEdge(edge->
|
|
137
|
+
StoreStmt* edge = SVFUtil::cast<StoreStmt>(*iter);
|
|
138
|
+
addStoreCGEdge(edge->getRHSVarID(),edge->getLHSVarID());
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
141
|
|
package/lib/Graphs/VFG.cpp
CHANGED
|
@@ -389,7 +389,7 @@ void VFG::addVFGNodes()
|
|
|
389
389
|
forks.end(); iter != eiter; ++iter)
|
|
390
390
|
{
|
|
391
391
|
TDForkPE* forkedge = SVFUtil::cast<TDForkPE>(*iter);
|
|
392
|
-
addActualParmVFGNode(forkedge->
|
|
392
|
+
addActualParmVFGNode(forkedge->getRHSVar(),forkedge->getCallSite());
|
|
393
393
|
}
|
|
394
394
|
|
|
395
395
|
// initialize actual parameter nodes
|
|
@@ -435,7 +435,7 @@ void VFG::addVFGNodes()
|
|
|
435
435
|
param->getIncomingEdgesEnd(PAGEdge::Call); cit != ecit; ++cit)
|
|
436
436
|
{
|
|
437
437
|
CallPE* callPE = SVFUtil::cast<CallPE>(*cit);
|
|
438
|
-
if (isInterestedPAGNode(callPE->
|
|
438
|
+
if (isInterestedPAGNode(callPE->getRHSVar()))
|
|
439
439
|
callPEs.insert(callPE);
|
|
440
440
|
}
|
|
441
441
|
}
|
|
@@ -455,7 +455,7 @@ void VFG::addVFGNodes()
|
|
|
455
455
|
ecit = varParam->getIncomingEdgesEnd(PAGEdge::Call); cit!=ecit; ++cit)
|
|
456
456
|
{
|
|
457
457
|
CallPE* callPE = SVFUtil::cast<CallPE>(*cit);
|
|
458
|
-
if(isInterestedPAGNode(callPE->
|
|
458
|
+
if(isInterestedPAGNode(callPE->getRHSVar()))
|
|
459
459
|
callPEs.insert(callPE);
|
|
460
460
|
}
|
|
461
461
|
}
|
|
@@ -478,7 +478,7 @@ void VFG::addVFGNodes()
|
|
|
478
478
|
cit != ecit; ++cit)
|
|
479
479
|
{
|
|
480
480
|
const RetPE* retPE = SVFUtil::cast<RetPE>(*cit);
|
|
481
|
-
if (isInterestedPAGNode(retPE->
|
|
481
|
+
if (isInterestedPAGNode(retPE->getLHSVar()))
|
|
482
482
|
retPEs.insert(retPE);
|
|
483
483
|
}
|
|
484
484
|
}
|
|
@@ -667,7 +667,7 @@ void VFG::connectDirectVFGEdges()
|
|
|
667
667
|
it!=eit; ++it)
|
|
668
668
|
{
|
|
669
669
|
const CallBlockNode* cs = (*it)->getCallSite();
|
|
670
|
-
ActualParmVFGNode* acutalParm = getActualParmVFGNode((*it)->
|
|
670
|
+
ActualParmVFGNode* acutalParm = getActualParmVFGNode((*it)->getRHSVar(),cs);
|
|
671
671
|
addInterEdgeFromAPToFP(acutalParm,formalParm,getCallSiteID(cs, formalParm->getFun()));
|
|
672
672
|
}
|
|
673
673
|
}
|
|
@@ -679,7 +679,7 @@ void VFG::connectDirectVFGEdges()
|
|
|
679
679
|
/// connect formal ret to actual ret
|
|
680
680
|
for(RetPESet::const_iterator it = calleeRet->retPEBegin(), eit = calleeRet->retPEEnd(); it!=eit; ++it)
|
|
681
681
|
{
|
|
682
|
-
ActualRetVFGNode* callsiteRev = getActualRetVFGNode((*it)->
|
|
682
|
+
ActualRetVFGNode* callsiteRev = getActualRetVFGNode((*it)->getLHSVar());
|
|
683
683
|
const CallBlockNode* retBlockNode = (*it)->getCallSite();
|
|
684
684
|
CallBlockNode* callBlockNode = pag->getICFG()->getCallBlockNode(retBlockNode->getCallSite());
|
|
685
685
|
addInterEdgeFromFRToAR(calleeRet,callsiteRev, getCallSiteID(callBlockNode, calleeRet->getFun()));
|
|
@@ -697,8 +697,8 @@ void VFG::connectDirectVFGEdges()
|
|
|
697
697
|
forks.end(); iter != eiter; ++iter)
|
|
698
698
|
{
|
|
699
699
|
TDForkPE* forkedge = SVFUtil::cast<TDForkPE>(*iter);
|
|
700
|
-
ActualParmVFGNode* acutalParm = getActualParmVFGNode(forkedge->
|
|
701
|
-
FormalParmVFGNode* formalParm = getFormalParmVFGNode(forkedge->
|
|
700
|
+
ActualParmVFGNode* acutalParm = getActualParmVFGNode(forkedge->getRHSVar(),forkedge->getCallSite());
|
|
701
|
+
FormalParmVFGNode* formalParm = getFormalParmVFGNode(forkedge->getLHSVar());
|
|
702
702
|
addInterEdgeFromAPToFP(acutalParm,formalParm,getCallSiteID(forkedge->getCallSite(), formalParm->getFun()));
|
|
703
703
|
}
|
|
704
704
|
/// add join edge
|
|
@@ -707,8 +707,8 @@ void VFG::connectDirectVFGEdges()
|
|
|
707
707
|
joins.end(); iter != eiter; ++iter)
|
|
708
708
|
{
|
|
709
709
|
TDJoinPE* joinedge = SVFUtil::cast<TDJoinPE>(*iter);
|
|
710
|
-
NodeID callsiteRev = getDef(joinedge->
|
|
711
|
-
FormalRetVFGNode* calleeRet = getFormalRetVFGNode(joinedge->
|
|
710
|
+
NodeID callsiteRev = getDef(joinedge->getLHSVar());
|
|
711
|
+
FormalRetVFGNode* calleeRet = getFormalRetVFGNode(joinedge->getRHSVar());
|
|
712
712
|
addRetEdge(calleeRet->getId(),callsiteRev, getCallSiteID(joinedge->getCallSite(), calleeRet->getFun()));
|
|
713
713
|
}
|
|
714
714
|
}
|
package/lib/MSSA/MemRegion.cpp
CHANGED
|
@@ -198,7 +198,7 @@ void MRGenerator::collectModRefForLoadStore()
|
|
|
198
198
|
pagEdgeToFunMap[inst] = &fun;
|
|
199
199
|
if (const StoreStmt *st = SVFUtil::dyn_cast<StoreStmt>(inst))
|
|
200
200
|
{
|
|
201
|
-
NodeBS cpts(pta->getPts(st->
|
|
201
|
+
NodeBS cpts(pta->getPts(st->getLHSVarID()).toNodeBS());
|
|
202
202
|
// TODO: change this assertion check later when we have conditional points-to set
|
|
203
203
|
if (cpts.empty())
|
|
204
204
|
continue;
|
|
@@ -208,7 +208,7 @@ void MRGenerator::collectModRefForLoadStore()
|
|
|
208
208
|
|
|
209
209
|
else if (const LoadStmt *ld = SVFUtil::dyn_cast<LoadStmt>(inst))
|
|
210
210
|
{
|
|
211
|
-
NodeBS cpts(pta->getPts(ld->
|
|
211
|
+
NodeBS cpts(pta->getPts(ld->getRHSVarID()).toNodeBS());
|
|
212
212
|
// TODO: change this assertion check later when we have conditional points-to set
|
|
213
213
|
if (cpts.empty())
|
|
214
214
|
continue;
|
|
@@ -611,7 +611,7 @@ bool MRGenerator::handleCallsiteModRef(NodeBS& mod, NodeBS& ref, const CallBlock
|
|
|
611
611
|
{
|
|
612
612
|
const PAGEdge* edge = *bit;
|
|
613
613
|
if (const AddrStmt* addr = SVFUtil::dyn_cast<AddrStmt>(edge))
|
|
614
|
-
mod.set(addr->
|
|
614
|
+
mod.set(addr->getRHSVarID());
|
|
615
615
|
}
|
|
616
616
|
}
|
|
617
617
|
/// otherwise, we find the mod/ref sets from the callee function, who has definition and been processed
|
|
@@ -678,7 +678,7 @@ NodeBS MRGenerator::getModInfoForCall(const CallBlockNode* cs)
|
|
|
678
678
|
{
|
|
679
679
|
const PAGEdge* edge = *bit;
|
|
680
680
|
if (const StoreStmt* st = SVFUtil::dyn_cast<StoreStmt>(edge))
|
|
681
|
-
mods |= pta->getPts(st->
|
|
681
|
+
mods |= pta->getPts(st->getLHSVarID()).toNodeBS();
|
|
682
682
|
}
|
|
683
683
|
return mods;
|
|
684
684
|
}
|
|
@@ -702,7 +702,7 @@ NodeBS MRGenerator::getRefInfoForCall(const CallBlockNode* cs)
|
|
|
702
702
|
{
|
|
703
703
|
const PAGEdge* edge = *bit;
|
|
704
704
|
if (const LoadStmt* ld = SVFUtil::dyn_cast<LoadStmt>(edge))
|
|
705
|
-
refs |= pta->getPts(ld->
|
|
705
|
+
refs |= pta->getPts(ld->getRHSVarID()).toNodeBS();
|
|
706
706
|
}
|
|
707
707
|
return refs;
|
|
708
708
|
}
|
|
@@ -611,8 +611,8 @@ void SVFIR::print()
|
|
|
611
611
|
ngeps.end(); iter != eiter; ++iter)
|
|
612
612
|
{
|
|
613
613
|
NormalGepStmt* gep = SVFUtil::cast<NormalGepStmt>(*iter);
|
|
614
|
-
outs() << gep->
|
|
615
|
-
<< ") --> " << gep->
|
|
614
|
+
outs() << gep->getRHSVarID() << " -- NormalGep (" << gep->getFieldOffset()
|
|
615
|
+
<< ") --> " << gep->getLHSVarID() << "\n";
|
|
616
616
|
}
|
|
617
617
|
|
|
618
618
|
SVFStmt::SVFStmtSetTy& vgeps = pag->getSVFStmtSet(SVFStmt::VariantGep);
|
|
@@ -68,7 +68,7 @@ const std::string SVFStmt::toString() const {
|
|
|
68
68
|
const std::string AddrStmt::toString() const{
|
|
69
69
|
std::string str;
|
|
70
70
|
raw_string_ostream rawstr(str);
|
|
71
|
-
rawstr << "AddrStmt: [" <<
|
|
71
|
+
rawstr << "AddrStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
72
72
|
if (Options::PAGDotGraphShorter) {
|
|
73
73
|
rawstr << "\n";
|
|
74
74
|
}
|
|
@@ -79,7 +79,7 @@ const std::string AddrStmt::toString() const{
|
|
|
79
79
|
const std::string CopyStmt::toString() const{
|
|
80
80
|
std::string str;
|
|
81
81
|
raw_string_ostream rawstr(str);
|
|
82
|
-
rawstr << "CopyStmt: [" <<
|
|
82
|
+
rawstr << "CopyStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
83
83
|
if (Options::PAGDotGraphShorter) {
|
|
84
84
|
rawstr << "\n";
|
|
85
85
|
}
|
|
@@ -149,7 +149,7 @@ const std::string BranchStmt::toString() const {
|
|
|
149
149
|
const std::string LoadStmt::toString() const{
|
|
150
150
|
std::string str;
|
|
151
151
|
raw_string_ostream rawstr(str);
|
|
152
|
-
rawstr << "LoadStmt: [" <<
|
|
152
|
+
rawstr << "LoadStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
153
153
|
if (Options::PAGDotGraphShorter) {
|
|
154
154
|
rawstr << "\n";
|
|
155
155
|
}
|
|
@@ -160,7 +160,7 @@ const std::string LoadStmt::toString() const{
|
|
|
160
160
|
const std::string StoreStmt::toString() const{
|
|
161
161
|
std::string str;
|
|
162
162
|
raw_string_ostream rawstr(str);
|
|
163
|
-
rawstr << "StoreStmt: [" <<
|
|
163
|
+
rawstr << "StoreStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
164
164
|
if (Options::PAGDotGraphShorter) {
|
|
165
165
|
rawstr << "\n";
|
|
166
166
|
}
|
|
@@ -171,7 +171,7 @@ const std::string StoreStmt::toString() const{
|
|
|
171
171
|
const std::string GepStmt::toString() const{
|
|
172
172
|
std::string str;
|
|
173
173
|
raw_string_ostream rawstr(str);
|
|
174
|
-
rawstr << "GepStmt: [" <<
|
|
174
|
+
rawstr << "GepStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
175
175
|
if (Options::PAGDotGraphShorter) {
|
|
176
176
|
rawstr << "\n";
|
|
177
177
|
}
|
|
@@ -182,7 +182,7 @@ const std::string GepStmt::toString() const{
|
|
|
182
182
|
const std::string NormalGepStmt::toString() const{
|
|
183
183
|
std::string str;
|
|
184
184
|
raw_string_ostream rawstr(str);
|
|
185
|
-
rawstr << "NormalGepStmt: [" <<
|
|
185
|
+
rawstr << "NormalGepStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
186
186
|
if (Options::PAGDotGraphShorter) {
|
|
187
187
|
rawstr << "\n";
|
|
188
188
|
}
|
|
@@ -193,7 +193,7 @@ const std::string NormalGepStmt::toString() const{
|
|
|
193
193
|
const std::string VariantGepStmt::toString() const{
|
|
194
194
|
std::string str;
|
|
195
195
|
raw_string_ostream rawstr(str);
|
|
196
|
-
rawstr << "VariantGepStmt: [" <<
|
|
196
|
+
rawstr << "VariantGepStmt: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
197
197
|
if (Options::PAGDotGraphShorter) {
|
|
198
198
|
rawstr << "\n";
|
|
199
199
|
}
|
|
@@ -204,7 +204,7 @@ const std::string VariantGepStmt::toString() const{
|
|
|
204
204
|
const std::string CallPE::toString() const{
|
|
205
205
|
std::string str;
|
|
206
206
|
raw_string_ostream rawstr(str);
|
|
207
|
-
rawstr << "CallPE: [" <<
|
|
207
|
+
rawstr << "CallPE: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
208
208
|
if (Options::PAGDotGraphShorter) {
|
|
209
209
|
rawstr << "\n";
|
|
210
210
|
}
|
|
@@ -215,7 +215,7 @@ const std::string CallPE::toString() const{
|
|
|
215
215
|
const std::string RetPE::toString() const{
|
|
216
216
|
std::string str;
|
|
217
217
|
raw_string_ostream rawstr(str);
|
|
218
|
-
rawstr << "RetPE: [" <<
|
|
218
|
+
rawstr << "RetPE: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
219
219
|
if (Options::PAGDotGraphShorter) {
|
|
220
220
|
rawstr << "\n";
|
|
221
221
|
}
|
|
@@ -226,7 +226,7 @@ const std::string RetPE::toString() const{
|
|
|
226
226
|
const std::string TDForkPE::toString() const{
|
|
227
227
|
std::string str;
|
|
228
228
|
raw_string_ostream rawstr(str);
|
|
229
|
-
rawstr << "TDForkPE: [" <<
|
|
229
|
+
rawstr << "TDForkPE: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
230
230
|
if (Options::PAGDotGraphShorter) {
|
|
231
231
|
rawstr << "\n";
|
|
232
232
|
}
|
|
@@ -237,7 +237,7 @@ const std::string TDForkPE::toString() const{
|
|
|
237
237
|
const std::string TDJoinPE::toString() const{
|
|
238
238
|
std::string str;
|
|
239
239
|
raw_string_ostream rawstr(str);
|
|
240
|
-
rawstr << "TDJoinPE: [" <<
|
|
240
|
+
rawstr << "TDJoinPE: [" << getLHSVarID() << "<--" << getRHSVarID() << "]\t";
|
|
241
241
|
if (Options::PAGDotGraphShorter) {
|
|
242
242
|
rawstr << "\n";
|
|
243
243
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "svf-tools",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.334",
|
|
4
4
|
"description": "* <b>[TypeClone](https://github.com/SVF-tools/SVF/wiki/TypeClone) published in our [ECOOP paper](https://yuleisui.github.io/publications/ecoop20.pdf) is now available in SVF </b> * <b>SVF now uses a single script for its build. Just type [`source ./build.sh`](https://github.com/SVF-tools/SVF/blob/master/build.sh) in your terminal, that's it!</b> * <b>SVF now supports LLVM-10.0.0! </b> * <b>We thank [bsauce](https://github.com/bsauce) for writing a user manual of SVF ([link1](https://www.jianshu.com/p/068a08ec749c) and [link2](https://www.jianshu.com/p/777c30d4240e)) in Chinese </b> * <b>SVF now supports LLVM-9.0.0 (Thank [Byoungyoung Lee](https://github.com/SVF-tools/SVF/issues/142) for his help!). </b> * <b>SVF now supports a set of [field-sensitive pointer analyses](https://yuleisui.github.io/publications/sas2019a.pdf). </b> * <b>[Use SVF as an external lib](https://github.com/SVF-tools/SVF/wiki/Using-SVF-as-a-lib-in-your-own-tool) for your own project (Contributed by [Hongxu Chen](https://github.com/HongxuChen)). </b> * <b>SVF now supports LLVM-7.0.0. </b> * <b>SVF now supports Docker. [Try SVF in Docker](https://github.com/SVF-tools/SVF/wiki/Try-SVF-in-Docker)! </b> * <b>SVF now supports [LLVM-6.0.0](https://github.com/svf-tools/SVF/pull/38) (Contributed by [Jack Anthony](https://github.com/jackanth)). </b> * <b>SVF now supports [LLVM-4.0.0](https://github.com/svf-tools/SVF/pull/23) (Contributed by Jared Carlson. Thank [Jared](https://github.com/jcarlson23) and [Will](https://github.com/dtzWill) for their in-depth [discussions](https://github.com/svf-tools/SVF/pull/18) about updating SVF!) </b> * <b>SVF now supports analysis for C++ programs.</b> <br />",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|