summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-cov/SourceCoverageDataManager.cpp
Commit message (Collapse)AuthorAgeFilesLines
* llvm-cov: Disentangle the coverage data logic from the display (NFC)Justin Bogner2014-09-201-104/+0
| | | | | | | | | | This splits the logic for actually looking up coverage information from the logic that displays it. These were tangled rather thoroughly so this change is a bit large, but it mostly consists of moving things around. The coverage lookup logic itself now lives in the library, rather than being spread between the library and the tool. llvm-svn: 218184
* llvm-cov: Rework the API for getting the coverage of a file (NFC)Justin Bogner2014-09-171-23/+77
| | | | | | | | | | | | This encapsulates how we handle the coverage regions of a file or function. In the old model, the user had to deal with nested regions, so they needed to maintain their own auxiliary data structures to get any useful information out of this. The new API provides a sequence of non-overlapping coverage segments, which makes it possible to render coverage information in a single pass and avoids a fair amount of extra work. llvm-svn: 217975
* llvm-cov: Simplify CounterMappingRegion, pushing logic to its userJustin Bogner2014-09-151-3/+6
| | | | | | | | | A single function in SourceCoverageDataManager was the only user of some of the comparisons in CounterMappingRegion, and at this point we know that only one file is relevant. This lets us use slightly simpler logic directly in the client. llvm-svn: 217745
* llvm-cov: Combine two types that were nearly identical (NFC)Justin Bogner2014-09-091-15/+6
| | | | | | | | | llvm-cov had a SourceRange type that was nearly identical to a CountedRegion except that it shaved off a couple of fields. There aren't likely to be enough of these for the minor memory savings to be worth the extra complexity here. llvm-svn: 217417
* llvm-cov: Rename MappingRegion to coverage::CountedRegion (NFC)Justin Bogner2014-09-091-5/+4
| | | | | | | This name was too similar to CoverageMappingRegion, and the type really belongs in the coverage library anyway. llvm-svn: 217416
* llvm-cov: add code coverage tool that's based on coverage mapping format and ↵Alex Lorenz2014-08-221-0/+57
clang's pgo. This commit expands llvm-cov's functionality by adding support for a new code coverage tool that uses LLVM's coverage mapping format and clang's instrumentation based profiling. The gcov compatible tool can be invoked by supplying the 'gcov' command as the first argument, or by modifying the tool's name to end with 'gcov'. Differential Revision: http://reviews.llvm.org/D4445 llvm-svn: 216300
OpenPOWER on IntegriCloud