LLVM 20.0.0git
|
Reader for the coverage mapping data that is emitted by the frontend and stored in an object file. More...
#include "llvm/ProfileData/Coverage/CoverageMappingReader.h"
Classes | |
struct | ProfileMappingRecord |
Public Types | |
using | FuncRecordsStorage = std::unique_ptr< MemoryBuffer > |
using | CoverageMapCopyStorage = std::unique_ptr< MemoryBuffer > |
Public Member Functions | |
BinaryCoverageReader (const BinaryCoverageReader &)=delete | |
BinaryCoverageReader & | operator= (const BinaryCoverageReader &)=delete |
Error | readNextRecord (CoverageMappingRecord &Record) override |
Public Member Functions inherited from llvm::coverage::CoverageMappingReader | |
virtual | ~CoverageMappingReader ()=default |
virtual Error | readNextRecord (CoverageMappingRecord &Record)=0 |
CoverageMappingIterator | begin () |
CoverageMappingIterator | end () |
Static Public Member Functions | |
static Expected< std::vector< std::unique_ptr< BinaryCoverageReader > > > | create (MemoryBufferRef ObjectBuffer, StringRef Arch, SmallVectorImpl< std::unique_ptr< MemoryBuffer > > &ObjectFileBuffers, StringRef CompilationDir="", SmallVectorImpl< object::BuildIDRef > *BinaryIDs=nullptr) |
static Expected< std::unique_ptr< BinaryCoverageReader > > | createCoverageReaderFromBuffer (StringRef Coverage, FuncRecordsStorage &&FuncRecords, CoverageMapCopyStorage &&CoverageMap, std::unique_ptr< InstrProfSymtab > ProfileNamesPtr, uint8_t BytesInAddress, llvm::endianness Endian, StringRef CompilationDir="") |
Reader for the coverage mapping data that is emitted by the frontend and stored in an object file.
Definition at line 164 of file CoverageMappingReader.h.
using llvm::coverage::BinaryCoverageReader::CoverageMapCopyStorage = std::unique_ptr<MemoryBuffer> |
Definition at line 183 of file CoverageMappingReader.h.
using llvm::coverage::BinaryCoverageReader::FuncRecordsStorage = std::unique_ptr<MemoryBuffer> |
Definition at line 182 of file CoverageMappingReader.h.
|
delete |
|
static |
Definition at line 1270 of file CoverageMappingReader.cpp.
References llvm::Bin, llvm::consumeError(), create(), llvm::object::createBinary(), llvm::ArrayRef< T >::empty(), llvm::Expected< T >::get(), llvm::MemoryBufferRef::getBuffer(), llvm::MemoryBufferRef::getBufferStart(), llvm::coverage::invalid_or_missing_arch_specifier, isArchSpecifierInvalidOrMissing(), loadBinaryFormat(), loadTestingFormat(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), llvm::StringRef::size(), llvm::Error::success(), llvm::Expected< T >::takeError(), and llvm::coverage::TestingFormatMagic.
Referenced by create().
|
static |
Definition at line 902 of file CoverageMappingReader.cpp.
References llvm::big, Endian, llvm::little, and llvm::coverage::malformed.
Referenced by loadBinaryFormat(), and loadTestingFormat().
|
delete |
|
overridevirtual |
Implements llvm::coverage::CoverageMappingReader.
Definition at line 1362 of file CoverageMappingReader.cpp.
References llvm::coverage::eof, F, llvm::coverage::RawCoverageMappingReader::read(), llvm::ArrayRef< T >::slice(), and llvm::Error::success().