Skip to content

Commit 8b96890

Browse files
committed
Refactored lib/ and unittests/ : building correctly
1 parent 3116369 commit 8b96890

48 files changed

Lines changed: 401 additions & 401 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

include/phasar/PhasarLLVM/DataFlowSolver/IfdsIde/Problems/IFDSLinearConstantAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ class IFDSLinearConstantAnalysis
8787

8888
std::shared_ptr<FlowFunction<d_t>> getCallToRetFlowFunction(
8989
n_t callSite, n_t retSite,
90-
std::set<IFDSLinearConstantAnalysis::m_t> callees) override;
90+
std::set<IFDSLinearConstantAnalysis::f_t> callees) override;
9191

9292
std::shared_ptr<FlowFunction<d_t>>
9393
getSummaryFlowFunction(n_t callStmt, f_t destFun) override;

include/phasar/PhasarLLVM/DataFlowSolver/IfdsIde/Solver/IDESolver.h

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
namespace psr {
5757

5858
// Forward declare the Transformation
59-
template <typename N, typename D, typename F, typename T, typename V,
59+
template <typename N, typename D, typename M, typename T, typename V,
6060
typename I>
6161
class IFDSToIDETabulationProblem;
6262

@@ -68,26 +68,26 @@ class IFDSToIDETabulationProblem;
6868
* @param <N> The type of nodes in the interprocedural control-flow graph.
6969
* @param <D> The type of data-flow facts to be computed by the tabulation
7070
* problem.
71-
* @param <F> The type of objects used to represent functions.
71+
* @param <M> The type of objects used to represent methods.
7272
* @param <T> The type of user-defined types that the type hierarchy consists of
7373
* @param <V> The type of values on which points-to information are computed
7474
* @param <L> The type of values to be computed along flow edges.
7575
* @param <I> The type of inter-procedural control-flow graph being used.
7676
*/
77-
template <typename N, typename D, typename F, typename T, typename V,
77+
template <typename N, typename D, typename M, typename T, typename V,
7878
typename L, typename I>
7979
class IDESolver {
8080
public:
81-
using ProblemTy = IDETabulationProblem<N, D, F, T, V, L, I>;
81+
using ProblemTy = IDETabulationProblem<N, D, M, T, V, L, I>;
8282

83-
IDESolver(IDETabulationProblem<N, D, F, T, V, L, I> &tabulationProblem)
83+
IDESolver(IDETabulationProblem<N, D, M, T, V, L, I> &tabulationProblem)
8484
: ideTabulationProblem(tabulationProblem),
8585
zeroValue(tabulationProblem.getZeroValue()),
8686
ICF(tabulationProblem.getICFG()),
8787
SolverConfig(tabulationProblem.getIFDSIDESolverConfig()),
8888
cachedFlowEdgeFunctions(tabulationProblem),
8989
allTop(tabulationProblem.allTopFunction()),
90-
jumpFn(std::make_shared<JumpFunctions<N, D, F, T, V, L, I>>(
90+
jumpFn(std::make_shared<JumpFunctions<N, D, M, T, V, L, I>>(
9191
allTop, ideTabulationProblem)),
9292
initialSeeds(tabulationProblem.initialSeeds()) {}
9393

@@ -243,8 +243,8 @@ class IDESolver {
243243
// });
244244
N prev = N{};
245245
N curr = N{};
246-
F prevFn = F{};
247-
F currFn = F{};
246+
M prevFn = M{};
247+
M currFn = M{};
248248
for (unsigned i = 0; i < cells.size(); ++i) {
249249
curr = cells[i].r;
250250
currFn = ICF->getFunctionOf(curr);
@@ -315,23 +315,23 @@ class IDESolver {
315315

316316
protected:
317317
// have a shared point to allow for a copy constructor of IDESolver
318-
std::unique_ptr<IFDSToIDETabulationProblem<N, D, F, T, V, I>>
318+
std::unique_ptr<IFDSToIDETabulationProblem<N, D, M, T, V, I>>
319319
transformedProblem;
320-
IDETabulationProblem<N, D, F, T, V, L, I> &ideTabulationProblem;
320+
IDETabulationProblem<N, D, M, T, V, L, I> &ideTabulationProblem;
321321
D zeroValue;
322322
const I *ICF;
323323
const IFDSIDESolverConfig SolverConfig;
324324
unsigned PathEdgeCount = 0;
325325

326-
FlowEdgeFunctionCache<N, D, F, T, V, L, I> cachedFlowEdgeFunctions;
326+
FlowEdgeFunctionCache<N, D, M, T, V, L, I> cachedFlowEdgeFunctions;
327327

328328
Table<N, N, std::map<D, std::set<D>>> computedIntraPathEdges;
329329

330330
Table<N, N, std::map<D, std::set<D>>> computedInterPathEdges;
331331

332332
std::shared_ptr<EdgeFunction<L>> allTop;
333333

334-
std::shared_ptr<JumpFunctions<N, D, F, T, V, L, I>> jumpFn;
334+
std::shared_ptr<JumpFunctions<N, D, M, T, V, L, I>> jumpFn;
335335

336336
std::map<std::tuple<N, D, N, D>,
337337
std::vector<std::shared_ptr<EdgeFunction<L>>>>
@@ -361,17 +361,17 @@ class IDESolver {
361361
// a modifiable l-value reference within the IDESolver implementation leads
362362
// to (massive) undefined behavior (and nightmares):
363363
// https://stackoverflow.com/questions/34240794/understanding-the-warning-binding-r-value-to-l-value-reference
364-
IDESolver(IFDSTabulationProblem<N, D, F, T, V, I> &tabulationProblem)
364+
IDESolver(IFDSTabulationProblem<N, D, M, T, V, I> &tabulationProblem)
365365
: transformedProblem(
366-
std::make_unique<IFDSToIDETabulationProblem<N, D, F, T, V, I>>(
366+
std::make_unique<IFDSToIDETabulationProblem<N, D, M, T, V, I>>(
367367
tabulationProblem)),
368368
ideTabulationProblem(*transformedProblem),
369369
zeroValue(ideTabulationProblem.getZeroValue()),
370370
ICF(ideTabulationProblem.getICFG()),
371371
SolverConfig(ideTabulationProblem.getIFDSIDESolverConfig()),
372372
cachedFlowEdgeFunctions(ideTabulationProblem),
373373
allTop(ideTabulationProblem.allTopFunction()),
374-
jumpFn(std::make_shared<JumpFunctions<N, D, F, T, V, L, I>>(
374+
jumpFn(std::make_shared<JumpFunctions<N, D, M, T, V, L, I>>(
375375
allTop, ideTabulationProblem)),
376376
initialSeeds(ideTabulationProblem.initialSeeds()) {}
377377

@@ -405,7 +405,7 @@ class IDESolver {
405405
D d2 = edge.factAtTarget();
406406
std::shared_ptr<EdgeFunction<L>> f = jumpFunction(edge);
407407
std::set<N> returnSiteNs = ICF->getReturnSitesOfCallAt(n);
408-
std::set<F> callees = ICF->getCalleesOfCallAt(n);
408+
std::set<M> callees = ICF->getCalleesOfCallAt(n);
409409
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG) << "Possible callees:");
410410
for (auto callee : callees) {
411411
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG)
@@ -620,38 +620,38 @@ class IDESolver {
620620
D d2 = edge.factAtTarget();
621621
std::shared_ptr<EdgeFunction<L>> f = jumpFunction(edge);
622622
auto successorInst = ICF->getSuccsOf(n);
623-
for (auto f : successorInst) {
623+
for (auto m : successorInst) {
624624
std::shared_ptr<FlowFunction<D>> flowFunction =
625-
cachedFlowEdgeFunctions.getNormalFlowFunction(n, f);
625+
cachedFlowEdgeFunctions.getNormalFlowFunction(n, m);
626626
INC_COUNTER("FF Queries", 1, PAMM_SEVERITY_LEVEL::Full);
627627
std::set<D> res = computeNormalFlowFunction(flowFunction, d1, d2);
628628
ADD_TO_HISTOGRAM("Data-flow facts", res.size(), 1,
629629
PAMM_SEVERITY_LEVEL::Full);
630-
saveEdges(n, f, d2, res, false);
630+
saveEdges(n, m, d2, res, false);
631631
for (D d3 : res) {
632632
std::shared_ptr<EdgeFunction<L>> g =
633-
cachedFlowEdgeFunctions.getNormalEdgeFunction(n, d2, f, d3);
633+
cachedFlowEdgeFunctions.getNormalEdgeFunction(n, d2, m, d3);
634634
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG)
635635
<< "Queried Normal Edge Function: " << g->str());
636636
std::shared_ptr<EdgeFunction<L>> fprime = f->composeWith(g);
637637
if (SolverConfig.emitESG) {
638-
intermediateEdgeFunctions[std::make_tuple(n, d2, f, d3)].push_back(
638+
intermediateEdgeFunctions[std::make_tuple(n, d2, m, d3)].push_back(
639639
fprime);
640640
}
641641
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG)
642642
<< "Compose: " << g->str() << " * " << f->str() << " = "
643643
<< fprime->str());
644644
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG) << ' ');
645645
INC_COUNTER("EF Queries", 1, PAMM_SEVERITY_LEVEL::Full);
646-
propagate(d1, f, d3, fprime, nullptr, false);
646+
propagate(d1, m, d3, fprime, nullptr, false);
647647
}
648648
}
649649
}
650650

651651
void propagateValueAtStart(std::pair<N, D> nAndD, N n) {
652652
PAMM_GET_INSTANCE;
653653
D d = nAndD.second;
654-
F p = ICF->getFunctionOf(n);
654+
M p = ICF->getFunctionOf(n);
655655
for (N c : ICF->getCallsFromWithin(p)) {
656656
for (auto entry : jumpFn->forwardLookup(d, c)) {
657657
D dPrime = entry.first;
@@ -668,7 +668,7 @@ class IDESolver {
668668
PAMM_GET_INSTANCE;
669669
auto &lg = lg::get();
670670
D d = nAndD.second;
671-
for (F q : ICF->getCalleesOfCallAt(n)) {
671+
for (M q : ICF->getCalleesOfCallAt(n)) {
672672
std::shared_ptr<FlowFunction<D>> callFlowFunction =
673673
cachedFlowEdgeFunctions.getCallFlowFunction(n, q);
674674
INC_COUNTER("FF Queries", 1, PAMM_SEVERITY_LEVEL::Full);
@@ -935,11 +935,11 @@ class IDESolver {
935935
<< ideTabulationProblem.NtoString(edge.getTarget()));
936936
N n = edge.getTarget(); // an exit node; line 21...
937937
std::shared_ptr<EdgeFunction<L>> f = jumpFunction(edge);
938-
F functionThatNeedsSummary = ICF->getFunctionOf(n);
938+
M methodThatNeedsSummary = ICF->getFunctionOf(n);
939939
D d1 = edge.factAtSource();
940940
D d2 = edge.factAtTarget();
941941
// for each of the method's start points, determine incoming calls
942-
std::set<N> startPointsOf = ICF->getStartPointsOf(functionThatNeedsSummary);
942+
std::set<N> startPointsOf = ICF->getStartPointsOf(methodThatNeedsSummary);
943943
std::map<N, std::set<D>> inc;
944944
for (N sP : startPointsOf) {
945945
// line 21.1 of Naeem/Lhotak/Rodriguez
@@ -961,7 +961,7 @@ class IDESolver {
961961
// compute return-flow function
962962
std::shared_ptr<FlowFunction<D>> retFunction =
963963
cachedFlowEdgeFunctions.getRetFlowFunction(
964-
c, functionThatNeedsSummary, n, retSiteC);
964+
c, methodThatNeedsSummary, n, retSiteC);
965965
INC_COUNTER("FF Queries", 1, PAMM_SEVERITY_LEVEL::Full);
966966
// for each incoming-call value
967967
for (D d4 : entry.second) {
@@ -1033,12 +1033,12 @@ class IDESolver {
10331033
// condition
10341034
if (SolverConfig.followReturnsPastSeeds && inc.empty() &&
10351035
ideTabulationProblem.isZeroValue(d1)) {
1036-
std::set<N> callers = ICF->getCallersOf(functionThatNeedsSummary);
1036+
std::set<N> callers = ICF->getCallersOf(methodThatNeedsSummary);
10371037
for (N c : callers) {
10381038
for (N retSiteC : ICF->getReturnSitesOfCallAt(c)) {
10391039
std::shared_ptr<FlowFunction<D>> retFunction =
10401040
cachedFlowEdgeFunctions.getRetFlowFunction(
1041-
c, functionThatNeedsSummary, n, retSiteC);
1041+
c, methodThatNeedsSummary, n, retSiteC);
10421042
INC_COUNTER("FF Queries", 1, PAMM_SEVERITY_LEVEL::Full);
10431043
std::set<D> targets = computeReturnFlowFunction(
10441044
retFunction, d1, d2, c, std::set<D>{zeroValue});
@@ -1072,7 +1072,7 @@ class IDESolver {
10721072
if (callers.empty()) {
10731073
std::shared_ptr<FlowFunction<D>> retFunction =
10741074
cachedFlowEdgeFunctions.getRetFlowFunction(
1075-
nullptr, functionThatNeedsSummary, n, nullptr);
1075+
nullptr, methodThatNeedsSummary, n, nullptr);
10761076
INC_COUNTER("FF Queries", 1, PAMM_SEVERITY_LEVEL::Full);
10771077
retFunction->computeTargets(d2);
10781078
}
@@ -1361,7 +1361,7 @@ class IDESolver {
13611361
}
13621362

13631363
std::cout << "\n**********************************************************";
1364-
std::cout << "\n* Computed inter-procedural path edges *";
1364+
std::cout << "\n* Computed inter-procedural path egdes *";
13651365
std::cout
13661366
<< "\n**********************************************************\n";
13671367

@@ -1716,7 +1716,7 @@ class IDESolver {
17161716
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG)
17171717
<< "=============================================");
17181718
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG)
1719-
<< "Process inter-procedural path edges");
1719+
<< "Process inter-procedural path egdes");
17201720
LOG_IF_ENABLE(BOOST_LOG_SEV(lg, DEBUG)
17211721
<< "=============================================");
17221722
cells = computedInterPathEdges.cellVec();

lib/Controller/AnalysisController.cpp

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -100,31 +100,31 @@ void AnalysisController::executeWholeProgram() {
100100
WholeProgramAnalysis<
101101
IFDSSolver<
102102
IFDSUninitializedVariables::n_t, IFDSUninitializedVariables::d_t,
103-
IFDSUninitializedVariables::m_t, IFDSUninitializedVariables::t_t,
103+
IFDSUninitializedVariables::f_t, IFDSUninitializedVariables::t_t,
104104
IFDSUninitializedVariables::v_t, IFDSUninitializedVariables::i_t>,
105105
IFDSUninitializedVariables>
106106
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
107107
} break;
108108
case DataFlowAnalysisType::IFDSConstAnalysis: {
109109
WholeProgramAnalysis<
110110
IFDSSolver<IFDSConstAnalysis::n_t, IFDSConstAnalysis::d_t,
111-
IFDSConstAnalysis::m_t, IFDSConstAnalysis::t_t,
111+
IFDSConstAnalysis::f_t, IFDSConstAnalysis::t_t,
112112
IFDSConstAnalysis::v_t, IFDSConstAnalysis::i_t>,
113113
IFDSConstAnalysis>
114114
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
115115
} break;
116116
case DataFlowAnalysisType::IFDSTaintAnalysis: {
117117
WholeProgramAnalysis<
118118
IFDSSolver<IFDSTaintAnalysis::n_t, IFDSTaintAnalysis::d_t,
119-
IFDSTaintAnalysis::m_t, IFDSTaintAnalysis::t_t,
119+
IFDSTaintAnalysis::f_t, IFDSTaintAnalysis::t_t,
120120
IFDSTaintAnalysis::v_t, IFDSTaintAnalysis::i_t>,
121121
IFDSTaintAnalysis>
122122
WPA(IRDB, AnalysisConfigPath, EntryPoints, &PT, &ICF, &TH);
123123
} break;
124124
case DataFlowAnalysisType::IDETaintAnalysis: {
125125
WholeProgramAnalysis<
126126
IDESolver<IDETaintAnalysis::n_t, IDETaintAnalysis::d_t,
127-
IDETaintAnalysis::m_t, IDETaintAnalysis::t_t,
127+
IDETaintAnalysis::f_t, IDETaintAnalysis::t_t,
128128
IDETaintAnalysis::v_t, IDETaintAnalysis::l_t,
129129
IDETaintAnalysis::i_t>,
130130
IDETaintAnalysis>
@@ -133,7 +133,7 @@ void AnalysisController::executeWholeProgram() {
133133
case DataFlowAnalysisType::IDETypeStateAnalysis: {
134134
// WholeProgramAnalysis<
135135
// IDESolver<IDETypeStateAnalysis::n_t, IDETypeStateAnalysis::d_t,
136-
// IDETypeStateAnalysis::m_t, IDETypeStateAnalysis::t_t,
136+
// IDETypeStateAnalysis::f_t, IDETypeStateAnalysis::t_t,
137137
// IDETypeStateAnalysis::v_t, IDETypeStateAnalysis::l_t,
138138
// IDETypeStateAnalysis::i_t>,
139139
// IDETypeStateAnalysis>
@@ -142,14 +142,14 @@ void AnalysisController::executeWholeProgram() {
142142
case DataFlowAnalysisType::IFDSTypeAnalysis: {
143143
WholeProgramAnalysis<
144144
IFDSSolver<IFDSTypeAnalysis::n_t, IFDSTypeAnalysis::d_t,
145-
IFDSTypeAnalysis::m_t, IFDSTypeAnalysis::t_t,
145+
IFDSTypeAnalysis::f_t, IFDSTypeAnalysis::t_t,
146146
IFDSTypeAnalysis::v_t, IFDSTypeAnalysis::i_t>,
147147
IFDSTypeAnalysis>
148148
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
149149
} break;
150150
case DataFlowAnalysisType::IFDSSolverTest: {
151151
WholeProgramAnalysis<IFDSSolver<IFDSSolverTest::n_t, IFDSSolverTest::d_t,
152-
IFDSSolverTest::m_t, IFDSSolverTest::t_t,
152+
IFDSSolverTest::f_t, IFDSSolverTest::t_t,
153153
IFDSSolverTest::v_t, IFDSSolverTest::i_t>,
154154
IFDSSolverTest>
155155
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
@@ -158,7 +158,7 @@ void AnalysisController::executeWholeProgram() {
158158
WholeProgramAnalysis<
159159
IFDSSolver<
160160
IFDSLinearConstantAnalysis::n_t, IFDSLinearConstantAnalysis::d_t,
161-
IFDSLinearConstantAnalysis::m_t, IFDSLinearConstantAnalysis::t_t,
161+
IFDSLinearConstantAnalysis::f_t, IFDSLinearConstantAnalysis::t_t,
162162
IFDSLinearConstantAnalysis::v_t, IFDSLinearConstantAnalysis::i_t>,
163163
IFDSLinearConstantAnalysis>
164164
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
@@ -167,7 +167,7 @@ void AnalysisController::executeWholeProgram() {
167167
WholeProgramAnalysis<
168168
IFDSSolver<
169169
IFDSFieldSensTaintAnalysis::n_t, IFDSFieldSensTaintAnalysis::d_t,
170-
IFDSFieldSensTaintAnalysis::m_t, IFDSFieldSensTaintAnalysis::t_t,
170+
IFDSFieldSensTaintAnalysis::f_t, IFDSFieldSensTaintAnalysis::t_t,
171171
IFDSFieldSensTaintAnalysis::v_t, IFDSFieldSensTaintAnalysis::i_t>,
172172
IFDSFieldSensTaintAnalysis>
173173
WPA(IRDB, AnalysisConfigPath, EntryPoints, &PT, &ICF, &TH);
@@ -176,15 +176,15 @@ void AnalysisController::executeWholeProgram() {
176176
WholeProgramAnalysis<
177177
IDESolver<
178178
IDELinearConstantAnalysis::n_t, IDELinearConstantAnalysis::d_t,
179-
IDELinearConstantAnalysis::m_t, IDELinearConstantAnalysis::t_t,
179+
IDELinearConstantAnalysis::f_t, IDELinearConstantAnalysis::t_t,
180180
IDELinearConstantAnalysis::v_t, IDELinearConstantAnalysis::l_t,
181181
IDELinearConstantAnalysis::i_t>,
182182
IDELinearConstantAnalysis>
183183
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
184184
} break;
185185
case DataFlowAnalysisType::IDESolverTest: {
186186
WholeProgramAnalysis<
187-
IDESolver<IDESolverTest::n_t, IDESolverTest::d_t, IDESolverTest::m_t,
187+
IDESolver<IDESolverTest::n_t, IDESolverTest::d_t, IDESolverTest::f_t,
188188
IDESolverTest::t_t, IDESolverTest::v_t, IDESolverTest::l_t,
189189
IDESolverTest::i_t>,
190190
IDESolverTest>
@@ -194,7 +194,7 @@ void AnalysisController::executeWholeProgram() {
194194
WholeProgramAnalysis<
195195
IntraMonoSolver<IntraMonoFullConstantPropagation::n_t,
196196
IntraMonoFullConstantPropagation::d_t,
197-
IntraMonoFullConstantPropagation::m_t,
197+
IntraMonoFullConstantPropagation::f_t,
198198
IntraMonoFullConstantPropagation::t_t,
199199
IntraMonoFullConstantPropagation::v_t,
200200
IntraMonoFullConstantPropagation::i_t>,
@@ -204,15 +204,15 @@ void AnalysisController::executeWholeProgram() {
204204
case DataFlowAnalysisType::IntraMonoSolverTest: {
205205
WholeProgramAnalysis<
206206
IntraMonoSolver<IntraMonoSolverTest::n_t, IntraMonoSolverTest::d_t,
207-
IntraMonoSolverTest::m_t, IntraMonoSolverTest::t_t,
207+
IntraMonoSolverTest::f_t, IntraMonoSolverTest::t_t,
208208
IntraMonoSolverTest::v_t, IntraMonoSolverTest::i_t>,
209209
IntraMonoSolverTest>
210210
WPA(IRDB, EntryPoints, &PT, &ICF, &TH);
211211
} break;
212212
case DataFlowAnalysisType::InterMonoSolverTest: {
213213
WholeProgramAnalysis<
214214
InterMonoSolver<InterMonoSolverTest::n_t, InterMonoSolverTest::d_t,
215-
InterMonoSolverTest::m_t, InterMonoSolverTest::t_t,
215+
InterMonoSolverTest::f_t, InterMonoSolverTest::t_t,
216216
InterMonoSolverTest::v_t, InterMonoSolverTest::i_t,
217217
3>,
218218
InterMonoSolverTest>
@@ -222,7 +222,7 @@ void AnalysisController::executeWholeProgram() {
222222
WholeProgramAnalysis<
223223
InterMonoSolver<
224224
InterMonoTaintAnalysis::n_t, InterMonoTaintAnalysis::d_t,
225-
InterMonoTaintAnalysis::m_t, InterMonoTaintAnalysis::t_t,
225+
InterMonoTaintAnalysis::f_t, InterMonoTaintAnalysis::t_t,
226226
InterMonoTaintAnalysis::v_t, InterMonoTaintAnalysis::i_t, 3>,
227227
InterMonoTaintAnalysis>
228228
WPA(IRDB, AnalysisConfigPath, EntryPoints, &PT, &ICF, &TH);

lib/PhasarLLVM/DataFlowSolver/IfdsIde/IFDSFieldSensTaintAnalysis/FlowFunctions/MapTaintedValuesToCallee.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ MapTaintedValuesToCallee::computeTargets(ExtendedValue fact) {
3131
long varArgIndex = 0L;
3232

3333
const auto sanitizedArgList = DataFlowUtils::getSanitizedArgList(
34-
callInst, destMthd, zeroValue.getValue());
34+
callInst, destFun, zeroValue.getValue());
3535

3636
for (const auto &argParamTriple : sanitizedArgList) {
3737

lib/PhasarLLVM/DataFlowSolver/IfdsIde/IFDSFieldSensTaintAnalysis/Utils/DataFlowUtils.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -692,7 +692,7 @@ const std::vector<
692692
std::tuple<const llvm::Value *, const std::vector<const llvm::Value *>,
693693
const llvm::Value *>>
694694
DataFlowUtils::getSanitizedArgList(const llvm::CallInst *callInst,
695-
const llvm::Function *destMthd,
695+
const llvm::Function *destFun,
696696
const llvm::Value *zeroValue) {
697697
std::vector<
698698
std::tuple<const llvm::Value *, const std::vector<const llvm::Value *>,
@@ -701,7 +701,7 @@ DataFlowUtils::getSanitizedArgList(const llvm::CallInst *callInst,
701701

702702
for (unsigned i = 0; i < callInst->getNumArgOperands(); ++i) {
703703
const auto arg = callInst->getOperand(i);
704-
const auto param = getNthFunctionArgument(destMthd, i);
704+
const auto param = getNthFunctionArgument(destFun, i);
705705

706706
auto argMemLocationSeq = DataFlowUtils::getMemoryLocationSeqFromMatr(arg);
707707

0 commit comments

Comments
 (0)