Skip to content

Commit bd1d96b

Browse files
committed
Introduce CounterMappingRegion::isBranch(). NFC.
Conflicts: clang/lib/CodeGen/CoverageMappingGen.cpp llvm/include/llvm/ProfileData/Coverage/CoverageMapping.h
1 parent c0785e9 commit bd1d96b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

llvm/lib/ProfileData/Coverage/CoverageMapping.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -637,8 +637,7 @@ static unsigned getMaxCounterID(const CounterMappingContext &Ctx,
637637
unsigned MaxCounterID = 0;
638638
for (const auto &Region : Record.MappingRegions) {
639639
MaxCounterID = std::max(MaxCounterID, Ctx.getMaxCounterID(Region.Count));
640-
if (Region.Kind == CounterMappingRegion::BranchRegion ||
641-
Region.Kind == CounterMappingRegion::MCDCBranchRegion)
640+
if (Region.isBranch())
642641
MaxCounterID =
643642
std::max(MaxCounterID, Ctx.getMaxCounterID(Region.FalseCount));
644643
}

0 commit comments

Comments
 (0)