1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 11:02:59 +02:00
llvm-mirror/lib/ProfileData
Vedant Kumar ee981c0e05 [Coverage] Build sorted and unique segments
A coverage segment contains a starting line and column, an execution
count, and some other metadata. Clients of the coverage library use
segments to prepare line-oriented reports.

Users of the coverage library depend on segments being unique and sorted
in source order. Currently this is not guaranteed (this is why the clang
change which introduced deferred regions was reverted).

This commit documents the "unique and sorted" condition and asserts that
it holds. It also fixes the SegmentBuilder so that it produces correct
output in some edge cases.

Testing: I've added unit tests for some edge cases. I've also checked
that the new SegmentBuilder implementation is fully covered. Apart from
running check-profile and the llvm-cov tests, I've successfully used a
stage1 llvm-cov to prepare a coverage report for an instrumented clang
binary.

Differential Revision: https://reviews.llvm.org/D36813

llvm-svn: 312817
2017-09-08 18:44:50 +00:00
..
Coverage [Coverage] Build sorted and unique segments 2017-09-08 18:44:50 +00:00
CMakeLists.txt Move ProfileSummary to IR. 2016-05-19 21:07:12 +00:00
InstrProf.cpp [ProfData] Detect if zlib is available 2017-07-21 21:41:15 +00:00
InstrProfReader.cpp Prototype: Reduce llvm-profdata merge memory usage further 2017-07-06 19:00:12 +00:00
InstrProfWriter.cpp llvm-profdata: Reduce memory usage by using Error callback rather than member 2017-07-10 03:04:59 +00:00
LLVMBuild.txt Move coverage related code into a separate library. 2016-04-29 18:53:05 +00:00
ProfileSummaryBuilder.cpp NFC Add const 2016-09-30 21:05:55 +00:00
SampleProf.cpp SamplePGO: convert callsite samples map key from callsite_location to callsite_location+callee_name 2017-04-13 19:52:10 +00:00
SampleProfReader.cpp SamplePGO: convert callsite samples map key from callsite_location to callsite_location+callee_name 2017-04-13 19:52:10 +00:00
SampleProfWriter.cpp Fix the bug when SampleProfileWriter writes out number of callsites. 2017-08-03 00:09:18 +00:00