LLVM  6.0.0svn
Public Types | Public Member Functions | List of all members
llvm::GCOVFunction Class Reference

GCOVFunction - Collects function information. More...

#include "llvm/ProfileData/GCOV.h"

Public Types

using BlockIterator = pointee_iterator< SmallVectorImpl< std::unique_ptr< GCOVBlock > >::const_iterator >
 

Public Member Functions

 GCOVFunction (GCOVFile &P)
 
bool readGCNO (GCOVBuffer &Buffer, GCOV::GCOVVersion Version)
 readGCNO - Read a function from the GCNO buffer. More...
 
bool readGCDA (GCOVBuffer &Buffer, GCOV::GCOVVersion Version)
 readGCDA - Read a function from the GCDA buffer. More...
 
StringRef getName () const
 
StringRef getFilename () const
 
size_t getNumBlocks () const
 
uint64_t getEntryCount () const
 getEntryCount - Get the number of times the function was called by retrieving the entry block's count. More...
 
uint64_t getExitCount () const
 getExitCount - Get the number of times the function returned by retrieving the exit block's count. More...
 
BlockIterator block_begin () const
 
BlockIterator block_end () const
 
iterator_range< BlockIteratorblocks () const
 
void print (raw_ostream &OS) const
 
void dump () const
 dump - Dump GCOVFunction content to dbgs() for debugging purposes. More...
 
void collectLineCounts (FileInfo &FI)
 collectLineCounts - Collect line counts. More...
 

Detailed Description

GCOVFunction - Collects function information.

Definition at line 272 of file GCOV.h.

Member Typedef Documentation

◆ BlockIterator

using llvm::GCOVFunction::BlockIterator = pointee_iterator<SmallVectorImpl< std::unique_ptr<GCOVBlock> >::const_iterator>

Definition at line 275 of file GCOV.h.

Constructor & Destructor Documentation

◆ GCOVFunction()

llvm::GCOVFunction::GCOVFunction ( GCOVFile P)
inline

Definition at line 277 of file GCOV.h.

References llvm::IndexedInstrProf::Version.

Member Function Documentation

◆ block_begin()

BlockIterator llvm::GCOVFunction::block_begin ( ) const
inline

Definition at line 287 of file GCOV.h.

◆ block_end()

BlockIterator llvm::GCOVFunction::block_end ( ) const
inline

Definition at line 288 of file GCOV.h.

◆ blocks()

iterator_range<BlockIterator> llvm::GCOVFunction::blocks ( ) const
inline

Definition at line 289 of file GCOV.h.

References llvm::dump(), llvm::make_range(), and print().

◆ collectLineCounts()

void GCOVFunction::collectLineCounts ( FileInfo FI)

collectLineCounts - Collect line counts.

This must be used after reading .gcno and .gcda files.

Definition at line 368 of file GCOV.cpp.

References llvm::FileInfo::addFunctionLine().

◆ dump()

LLVM_DUMP_METHOD void GCOVFunction::dump ( ) const

dump - Dump GCOVFunction content to dbgs() for debugging purposes.

Definition at line 361 of file GCOV.cpp.

References llvm::dbgs(), and llvm::GCOVFile::print().

◆ getEntryCount()

uint64_t GCOVFunction::getEntryCount ( ) const

getEntryCount - Get the number of times the function was called by retrieving the entry block's count.

Definition at line 342 of file GCOV.cpp.

◆ getExitCount()

uint64_t GCOVFunction::getExitCount ( ) const

getExitCount - Get the number of times the function returned by retrieving the exit block's count.

Definition at line 348 of file GCOV.cpp.

◆ getFilename()

StringRef llvm::GCOVFunction::getFilename ( ) const
inline

Definition at line 282 of file GCOV.h.

◆ getName()

StringRef llvm::GCOVFunction::getName ( ) const
inline

Definition at line 281 of file GCOV.h.

Referenced by llvm::FileInfo::print().

◆ getNumBlocks()

size_t llvm::GCOVFunction::getNumBlocks ( ) const
inline

Definition at line 283 of file GCOV.h.

◆ print()

void GCOVFunction::print ( raw_ostream OS) const

Definition at line 352 of file GCOV.cpp.

◆ readGCDA()

bool GCOVFunction::readGCDA ( GCOVBuffer Buff,
GCOV::GCOVVersion  Version 
)

◆ readGCNO()

bool GCOVFunction::readGCNO ( GCOVBuffer Buff,
GCOV::GCOVVersion  Version 
)

The documentation for this class was generated from the following files: