diff options
Diffstat (limited to 'llvm/tools/llvm-cov/SourceCoverageView.h')
-rw-r--r-- | llvm/tools/llvm-cov/SourceCoverageView.h | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/llvm/tools/llvm-cov/SourceCoverageView.h b/llvm/tools/llvm-cov/SourceCoverageView.h index 9cb608fed60..c9f0c57b5cb 100644 --- a/llvm/tools/llvm-cov/SourceCoverageView.h +++ b/llvm/tools/llvm-cov/SourceCoverageView.h @@ -67,25 +67,15 @@ struct InstantiationView { /// \brief Coverage statistics for a single line. struct LineCoverageStats { uint64_t ExecutionCount; - unsigned RegionCount; + bool HasMultipleRegions; bool Mapped; - LineCoverageStats() : ExecutionCount(0), RegionCount(0), Mapped(false) {} + LineCoverageStats(ArrayRef<const coverage::CoverageSegment *> LineSegments, + const coverage::CoverageSegment *WrappedSegment); bool isMapped() const { return Mapped; } - bool hasMultipleRegions() const { return RegionCount > 1; } - - void addRegionStartCount(uint64_t Count) { - // The max of all region starts is the most interesting value. - addRegionCount(RegionCount ? std::max(ExecutionCount, Count) : Count); - ++RegionCount; - } - - void addRegionCount(uint64_t Count) { - Mapped = true; - ExecutionCount = Count; - } + bool hasMultipleRegions() const { return HasMultipleRegions; } }; /// \brief A file manager that handles format-aware file creation. |