This is an archive of the discontinued LLVM Phabricator instance.

Coverage: add HasCodeBefore flag to a mapping region
ClosedPublic

Authored by arphaman on Jul 31 2014, 2:30 PM.

Details

Summary

This patch adds a flag HasCodeBefore to a coverage mapping region.

This flag will be used by the coverage tool to compute the execution counts for each line in a source file
so that the lines' execution counts will show the execution count of a first piece of code on that line
instead of the execution count of the last mapping region on that line.

Diff Detail

Repository
rL LLVM

Event Timeline

arphaman updated this revision to Diff 12085.Jul 31 2014, 2:30 PM
arphaman retitled this revision from to Coverage: add HasCodeBefore flag to a mapping region.
arphaman updated this object.
arphaman edited the test plan for this revision. (Show Details)
arphaman added reviewers: bogner, bob.wilson.
arphaman set the repository for this revision to rL LLVM.
arphaman added a subscriber: Unknown Object (MLST).
bob.wilson edited edge metadata.Aug 4 2014, 10:32 AM

This is good to commit, but see my suggested improvement below. I assume it will be tested once we get the llvm-cov support enabled?

Thanks, I will add a constant for the shift amount to the mapping region.
Yes, this will be tested in llvm-cov.

arphaman closed this revision.Aug 4 2014, 11:09 AM
arphaman updated this revision to Diff 12170.

Closed by commit rL214740 (authored by @arphaman).