Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -530,9 +530,9 @@ class IDETypeStateAnalysis
llvm::dyn_cast<llvm::AllocaInst>(Res.first)) {
if (Res.second == TSD->error()) {
Warning<IDETypeStateAnalysisDomain<TypeStateDescriptionTy>>
War(&I, Res.first, TSD->error());
Warn(&I, Res.first, TSD->error());
// ERROR STATE DETECTED
this->Printer->onResult(War);
this->Printer->onResult(Warn);
}
}
}
Expand All @@ -542,9 +542,9 @@ class IDETypeStateAnalysis
llvm::dyn_cast<llvm::AllocaInst>(Res.first)) {
if (Res.second == TSD->error()) {
Warning<IDETypeStateAnalysisDomain<TypeStateDescriptionTy>>
War(&I, Res.first, TSD->error());
Warn(&I, Res.first, TSD->error());
// ERROR STATE DETECTED
this->Printer->onResult(War);
this->Printer->onResult(Warn);
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion include/phasar/PhasarLLVM/Utils/AnalysisPrinterBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ template <typename AnalysisDomainTy> struct Warning {
LatticeElement(std::move(Lattice)) {}
};

template <typename AnalysisDomainTy> struct Results {
template <typename AnalysisDomainTy> struct DataflowAnalysisResults {
std::vector<Warning<AnalysisDomainTy>> War;
};

Expand Down
2 changes: 1 addition & 1 deletion include/phasar/PhasarLLVM/Utils/DefaultAnalysisPrinter.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class DefaultAnalysisPrinter : public AnalysisPrinterBase<AnalysisDomainTy> {
}

private:
Results<AnalysisDomainTy> AnalysisResults{};
DataflowAnalysisResults<AnalysisDomainTy> AnalysisResults{};
};

} // namespace psr
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,9 +227,9 @@ void IDEExtendedTaintAnalysis::reportLeakIfNecessary(
const llvm::Value *LeakCandidate) {
if (isSink(SinkCandidate, Inst)) {
Leaks[Inst].insert(LeakCandidate);
Warning<IDEExtendedTaintAnalysisDomain> War(
Warning<IDEExtendedTaintAnalysisDomain> Warn(
Inst, makeFlowFact(LeakCandidate), Top{});
Printer->onResult(War);
Printer->onResult(Warn);
}
}

Expand Down Expand Up @@ -754,9 +754,9 @@ void IDEExtendedTaintAnalysis::emitTextReport(

for (auto &[Inst, LeakSet] : Leaks) {
for (const auto &Leak : LeakSet) {
Warning<IDEExtendedTaintAnalysisDomain> War(Inst, makeFlowFact(Leak),
Top{});
Printer->onResult(War);
Warning<IDEExtendedTaintAnalysisDomain> Warn(Inst, makeFlowFact(Leak),
Top{});
Printer->onResult(Warn);
}
}

Expand Down
12 changes: 6 additions & 6 deletions lib/PhasarLLVM/DataFlow/IfdsIde/Problems/IFDSTaintAnalysis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -410,9 +410,9 @@ auto IFDSTaintAnalysis::getSummaryFlowFunction([[maybe_unused]] n_t CallSite,
CallSite](d_t Source) -> container_type {
if (Leak.count(Source)) {
if (Leaks[CallSite].insert(Source).second) {
Warning<LLVMIFDSAnalysisDomainDefault> War(CallSite, Source,
topElement());
Printer->onResult(War);
Warning<LLVMIFDSAnalysisDomainDefault> Warn(CallSite, Source,
topElement());
Printer->onResult(Warn);
}
}

Expand All @@ -439,9 +439,9 @@ auto IFDSTaintAnalysis::getSummaryFlowFunction([[maybe_unused]] n_t CallSite,

if (Leak.count(Source)) {
if (Leaks[CallSite].insert(Source).second) {
Warning<LLVMIFDSAnalysisDomainDefault> War(CallSite, Source,
topElement());
Printer->onResult(War);
Warning<LLVMIFDSAnalysisDomainDefault> Warn(CallSite, Source,
topElement());
Printer->onResult(Warn);
}
}

Expand Down