]> granicus.if.org Git - llvm/commit
[llvm-cov] Remove workaround in line execution count calculation (PR34962)
authorVedant Kumar <vsk@apple.com>
Mon, 16 Oct 2017 23:47:10 +0000 (23:47 +0000)
committerVedant Kumar <vsk@apple.com>
Mon, 16 Oct 2017 23:47:10 +0000 (23:47 +0000)
commit612d06a73fd4cabb499d801c611947038b3e506a
tree94dd30127e8343713db23c0be465b122cd42a3c3
parentdf60d8e59e3d851a042867b676602f70d7887e3a
[llvm-cov] Remove workaround in line execution count calculation (PR34962)

Gap areas make it possible to correctly determine when to use counts
from deferred regions. Before gap areas were introduced, llvm-cov needed
to use a heuristic to do this: it ignored counts from segments that
start, but do not end, on a line. This heuristic breaks down on a simple
example (see PR34962).

This patch removes the heuristic and picks counts from any region entry
segment which isn't a gap area.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@315960 91177308-0d34-0410-b5e6-96231b3b80d8
test/tools/llvm-cov/Inputs/deferred-regions.covmapping
test/tools/llvm-cov/Inputs/deferred-regions.profdata
test/tools/llvm-cov/deferred-region.cpp
tools/llvm-cov/CoverageSummaryInfo.cpp