aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/ProfileData/CoverageMappingTest.cpp
diff options
context:
space:
mode:
authorHans Wennborg <hans@chromium.org>2024-06-14 10:32:39 +0200
committerHans Wennborg <hans@chromium.org>2024-06-14 10:47:41 +0200
commitb422fa6b62160f5eeb038d816d05e039182dde56 (patch)
tree1facf1d549693b6e685af22a7eebbe8b4db9daa4 /llvm/unittests/ProfileData/CoverageMappingTest.cpp
parent880d37038c7bbff53ef02c9d6b01cbbc87875243 (diff)
downloadllvm-b422fa6b62160f5eeb038d816d05e039182dde56.zip
llvm-b422fa6b62160f5eeb038d816d05e039182dde56.tar.gz
llvm-b422fa6b62160f5eeb038d816d05e039182dde56.tar.bz2
Revert "[MC/DC][Coverage] Loosen the limit of NumConds from 6 (#82448)"
This broke the lit tests on Mac: https://green.lab.llvm.org/job/llvm.org/job/clang-stage1-RA/1096/ > By storing possible test vectors instead of combinations of conditions, > the restriction is dramatically relaxed. > > This introduces two options to `cc1`: > > * `-fmcdc-max-conditions=32767` > * `-fmcdc-max-test-vectors=2147483646` > > This change makes coverage mapping, profraw, and profdata incompatible > with Clang-18. > > - Bitmap semantics changed. It is incompatible with previous format. > - `BitmapIdx` in `Decision` points to the end of the bitmap. > - Bitmap is packed per function. > - `llvm-cov` can understand `profdata` generated by `llvm-profdata-18`. > > RFC: > https://discourse.llvm.org/t/rfc-coverage-new-algorithm-and-file-format-for-mc-dc/76798 This reverts commit 7ead2d8c7e9114b3f23666209a1654939987cb30.
Diffstat (limited to 'llvm/unittests/ProfileData/CoverageMappingTest.cpp')
-rw-r--r--llvm/unittests/ProfileData/CoverageMappingTest.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/unittests/ProfileData/CoverageMappingTest.cpp b/llvm/unittests/ProfileData/CoverageMappingTest.cpp
index ef14767..f063a33 100644
--- a/llvm/unittests/ProfileData/CoverageMappingTest.cpp
+++ b/llvm/unittests/ProfileData/CoverageMappingTest.cpp
@@ -872,7 +872,7 @@ TEST_P(CoverageMappingTest, non_code_region_bitmask) {
addCMR(Counter::getCounter(2), "file", 1, 1, 5, 5);
addCMR(Counter::getCounter(3), "file", 1, 1, 5, 5);
- addMCDCDecisionCMR(3, 2, "file", 7, 1, 7, 6);
+ addMCDCDecisionCMR(0, 2, "file", 7, 1, 7, 6);
addMCDCBranchCMR(Counter::getCounter(0), Counter::getCounter(1), 0, {-1, 1},
"file", 7, 2, 7, 3);
addMCDCBranchCMR(Counter::getCounter(2), Counter::getCounter(3), 1, {-1, -1},
@@ -895,7 +895,7 @@ TEST_P(CoverageMappingTest, decision_before_expansion) {
addCMR(Counter::getCounter(0), "foo", 3, 23, 5, 2);
// This(4:11) was put after Expansion(4:11) before the fix
- addMCDCDecisionCMR(3, 2, "foo", 4, 11, 4, 20);
+ addMCDCDecisionCMR(0, 2, "foo", 4, 11, 4, 20);
addExpansionCMR("foo", "A", 4, 11, 4, 12);
addExpansionCMR("foo", "B", 4, 19, 4, 20);