[llvm-cov] Allow branch coverage to be skipped when exporting for LCOV
commita921d6eb3b517ef6dcefd13cfbb9a017b00a06b1
authorAlan Phipps <a-phipps@ti.com>
Fri, 14 Oct 2022 21:08:34 +0000 (14 16:08 -0500)
committerAlan Phipps <a-phipps@ti.com>
Fri, 14 Oct 2022 21:24:41 +0000 (14 16:24 -0500)
treeb5b06d55ded8e822ab0bedb7a50edae5adf742dd
parent705e77abed0b0fb7c6ab268866d3f841838eaf97
[llvm-cov] Allow branch coverage to be skipped when exporting for LCOV

This small patch adds a '--skip-branches' option to the llvm-cov export
options. This option allows branch coverage information to be skipped from the
exported LCOV directives if it's not needed. For now, this only works when
exporting LCOV (which is noted in the option description), but it can be
extended for JSON later if it makes sense.

Differential Revision: https://reviews.llvm.org/D135986
llvm/test/tools/llvm-cov/branch-export-lcov.test
llvm/tools/llvm-cov/CodeCoverage.cpp
llvm/tools/llvm-cov/CoverageExporterLcov.cpp
llvm/tools/llvm-cov/CoverageViewOptions.h