LLVM API Documentation
A Counter is an abstract value that describes how to compute the execution count for a region of code using the collected profile count data. More...
#include <CoverageMapping.h>
Public Types | |
enum | CounterKind { Zero, CounterValueReference, Expression } |
Public Member Functions | |
Counter () | |
CounterKind | getKind () const |
bool | isZero () const |
bool | isExpression () const |
unsigned | getCounterID () const |
unsigned | getExpressionID () const |
bool | operator== (const Counter &Other) const |
Static Public Member Functions | |
static Counter | getZero () |
Return the counter that represents the number zero. | |
static Counter | getCounter (unsigned CounterId) |
Return the counter that corresponds to a specific profile counter. | |
static Counter | getExpression (unsigned ExpressionId) |
Return the counter that corresponds to a specific addition counter expression. | |
Static Public Attributes | |
static const unsigned | EncodingTagBits = 2 |
static const unsigned | EncodingTagMask = 0x3 |
static const unsigned | EncodingCounterTagAndExpansionRegionTagBits |
A Counter is an abstract value that describes how to compute the execution count for a region of code using the collected profile count data.
Definition at line 32 of file CoverageMapping.h.
Definition at line 33 of file CoverageMapping.h.
llvm::coverage::Counter::Counter | ( | ) | [inline] |
Definition at line 46 of file CoverageMapping.h.
Referenced by getCounter(), getExpression(), and getZero().
static Counter llvm::coverage::Counter::getCounter | ( | unsigned | CounterId | ) | [inline, static] |
Return the counter that corresponds to a specific profile counter.
Definition at line 66 of file CoverageMapping.h.
References Counter(), and CounterValueReference.
unsigned llvm::coverage::Counter::getCounterID | ( | ) | const [inline] |
Definition at line 54 of file CoverageMapping.h.
Referenced by llvm::coverage::CounterMappingContext::dump(), encodeCounter(), and llvm::coverage::CounterMappingContext::evaluate().
static Counter llvm::coverage::Counter::getExpression | ( | unsigned | ExpressionId | ) | [inline, static] |
Return the counter that corresponds to a specific addition counter expression.
Definition at line 72 of file CoverageMapping.h.
References Counter(), and Expression.
unsigned llvm::coverage::Counter::getExpressionID | ( | ) | const [inline] |
Definition at line 56 of file CoverageMapping.h.
Referenced by llvm::coverage::CounterMappingContext::dump(), encodeCounter(), and llvm::coverage::CounterMappingContext::evaluate().
CounterKind llvm::coverage::Counter::getKind | ( | ) | const [inline] |
Definition at line 48 of file CoverageMapping.h.
Referenced by llvm::coverage::CounterMappingContext::dump(), encodeCounter(), and llvm::coverage::CounterMappingContext::evaluate().
static Counter llvm::coverage::Counter::getZero | ( | ) | [inline, static] |
Return the counter that represents the number zero.
Definition at line 63 of file CoverageMapping.h.
References Counter().
bool llvm::coverage::Counter::isExpression | ( | ) | const [inline] |
Definition at line 52 of file CoverageMapping.h.
References Expression.
Referenced by encodeCounter().
bool llvm::coverage::Counter::isZero | ( | ) | const [inline] |
Definition at line 50 of file CoverageMapping.h.
References Zero.
Referenced by llvm::coverage::CoverageMappingWriter::write().
Definition at line 58 of file CoverageMapping.h.
EncodingTagBits + 1
Definition at line 36 of file CoverageMapping.h.
Referenced by llvm::coverage::CoverageMappingWriter::write().
const unsigned llvm::coverage::Counter::EncodingTagBits = 2 [static] |
Definition at line 34 of file CoverageMapping.h.
Referenced by encodeCounter(), and llvm::coverage::CoverageMappingWriter::write().
const unsigned llvm::coverage::Counter::EncodingTagMask = 0x3 [static] |
Definition at line 35 of file CoverageMapping.h.