Lines Matching +refs:clang +refs:format +refs:region
2 :format: html
14 LLVM's code coverage mapping format is used to provide code coverage
24 then we briefly desribe LLVM's code coverage mapping format and the
25 way that Clang and LLVM's code coverage tool work with this format. After
26 the basics are down, more advanced features of the coverage mapping format
40 ``clang -o test -fprofile-instr-generate -fcoverage-mapping test.c``
56 LLVM's code coverage mapping format is designed to be a self contained
57 data format, that can be embedded into the LLVM IR and object files.
58 It's described in this document as a **mapping** format because its goal is
65 1. When clang compiles a source file with ``-fcoverage-mapping``, it
77 The coverage mapping format aims to be a "universal format" that would be
89 coverage mapping format works.
91 The coverage mapping format operates on a per-function level as the
101 A mapping region stores the `source code range`_ that is covered by this region,
103 the region's kind.
142 as the code coverage tool can determine the execution count for this region
143 by looking up the execution count of the first region with a corresponding
159 mapping region. Both locations include the line and the column numbers.
167 in which source file or macro expansion is this region located.
186 instrumentation counter. The execution count for a region with such counter
192 The execution count for a region with an expression counter is determined by
215 …e='background-color:#4A789C'>; </span> <span class='c1'>// Unreachable region's counter is zero<…
261 i32 1, ; Coverage mapping format version
299 * The format version. The current version is 2 (encoded as a 1).
342 * The string contains values that are encoded in the LEB128 format, which is
382 …| ``0x01`` | The coverage mapping counter for the first region in this function. The value of 1 te…
385 …| ``0x01`` | The starting line of the first mapping region in this function. …
387 …| ``0x0C`` | The starting column of the first mapping region in this function. …
389 …| ``0x02`` | The ending line of the first mapping region in this function. …
391 …| ``0x02`` | The ending column of the first mapping region in this function. …
410 The format of the structure follows:
425 This section describes the basic types that are used by the encoding format
516 region in a particular sub-array has the same file id.
528 sorted in an ascending order by the region's starting location.
535 The mapping region record contains two sub-records ---
536 the `header`_, which stores the counter and/or the region's kind,
538 location of this region.
551 The header encodes the region's counter and the region's kind.
560 A mapping region whose header has a counter with a non-zero tag is
561 a code region.
573 * bit 2: expansionRegionTag. If this bit is set, then this mapping region
574 is an expansion region.
576 * remaining bits: data. If this region is an expansion region, then the data
577 contains the expanded file id of that region.
579 Otherwise, the data contains the region's kind. The possible region
582 * 0 - This mapping region is a code region with a counter of zero.
583 * 2 - This mapping region is a skipped region.
595 current mapping region and the starting line of the previous mapping region.
597 If the current mapping region is the first region in the current
598 sub-array, then it stores the starting line of that region.
600 * *columnStart*: The starting column of the mapping region.
603 of the current mapping region.
605 * *columnEnd*: The ending column of the mapping region.