diff options
author | Kazu Hirata <kazu@google.com> | 2024-06-17 18:51:45 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-17 18:51:45 -0700 |
commit | 2c2f49059ff2999e06eb5ecb76af5b1ebd3e5477 (patch) | |
tree | 3353b15822f4adbe556ab983c944bf8bdb173141 /llvm/lib/Analysis/ModuleSummaryAnalysis.cpp | |
parent | d6b0b7acf3562c8089f3342634a749f03909fd32 (diff) | |
download | llvm-2c2f49059ff2999e06eb5ecb76af5b1ebd3e5477.zip llvm-2c2f49059ff2999e06eb5ecb76af5b1ebd3e5477.tar.gz llvm-2c2f49059ff2999e06eb5ecb76af5b1ebd3e5477.tar.bz2 |
[Analysis] Clean up getPromotionCandidatesForInstruction (NFC) (#95624)
Callers of getPromotionCandidatesForInstruction pass NumVals as an out
parameter for the number of value-count pairs of the value profiling
data, but nobody uses the out parameter.
This patch removes the parameter and updates the callers. Note that
the number of value-count pairs is still available via
getPromotionCandidatesForInstruction(...).size().
Diffstat (limited to 'llvm/lib/Analysis/ModuleSummaryAnalysis.cpp')
-rw-r--r-- | llvm/lib/Analysis/ModuleSummaryAnalysis.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Analysis/ModuleSummaryAnalysis.cpp b/llvm/lib/Analysis/ModuleSummaryAnalysis.cpp index a991377..c6934f5 100644 --- a/llvm/lib/Analysis/ModuleSummaryAnalysis.cpp +++ b/llvm/lib/Analysis/ModuleSummaryAnalysis.cpp @@ -483,11 +483,11 @@ static void computeFunctionSummary( } } - uint32_t NumVals, NumCandidates; + uint32_t NumCandidates; uint64_t TotalCount; auto CandidateProfileData = - ICallAnalysis.getPromotionCandidatesForInstruction( - &I, NumVals, TotalCount, NumCandidates); + ICallAnalysis.getPromotionCandidatesForInstruction(&I, TotalCount, + NumCandidates); for (const auto &Candidate : CandidateProfileData) CallGraphEdges[Index.getOrInsertValueInfo(Candidate.Value)] .updateHotness(getHotness(Candidate.Count, PSI)); |