diff options
author | Tom Stellard <tstellar@redhat.com> | 2021-06-28 09:23:38 -0700 |
---|---|---|
committer | Tom Stellard <tstellar@redhat.com> | 2021-06-28 09:23:38 -0700 |
commit | fed41342a82f5a3a9201819a82bf7a48313e296b (patch) | |
tree | 95c3c1c553ca5e38d86e95201d2c109564c3447e /llvm/tools/llvm-cov/CoverageSummaryInfo.cpp | |
parent | b7c7b42db1d16c4cab595bf53c62a70a6a505e0e (diff) | |
download | llvm-release/12.x.tar.gz |
Revert "Revert "[Coverage] Fix branch coverage merging in FunctionCoverageSummary::get() for instantiation""llvmorg-12.0.1-rc4llvmorg-12.0.1release/12.x
This reverts commit 33d312b2d731507327252fd597bac1b738870330.
The original patch was correct, so we need to restore it in the
release branch.
Diffstat (limited to 'llvm/tools/llvm-cov/CoverageSummaryInfo.cpp')
-rw-r--r-- | llvm/tools/llvm-cov/CoverageSummaryInfo.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/llvm/tools/llvm-cov/CoverageSummaryInfo.cpp b/llvm/tools/llvm-cov/CoverageSummaryInfo.cpp index 4a0a86168908..10e059adeb7d 100644 --- a/llvm/tools/llvm-cov/CoverageSummaryInfo.cpp +++ b/llvm/tools/llvm-cov/CoverageSummaryInfo.cpp @@ -100,11 +100,7 @@ FunctionCoverageSummary::get(const InstantiationGroup &Group, for (const auto &FCS : Summaries.drop_front()) { Summary.RegionCoverage.merge(FCS.RegionCoverage); Summary.LineCoverage.merge(FCS.LineCoverage); - - // Sum branch coverage across instantiation groups for the summary rather - // than "merge" the maximum count. This is a clearer view into whether all - // created branches are covered. - Summary.BranchCoverage += FCS.BranchCoverage; + Summary.BranchCoverage.merge(FCS.BranchCoverage); } return Summary; } |