LLVM 20.0.0git
Public Member Functions | List of all members
llvm::sampleprof::ProfileSymbolList Class Reference

ProfileSymbolList records the list of function symbols shown up in the binary used to generate the profile. More...

#include "llvm/ProfileData/SampleProf.h"

Public Member Functions

void add (StringRef Name, bool Copy=false)
 copy indicates whether we need to copy the underlying memory for the input Name.
 
bool contains (StringRef Name)
 
void merge (const ProfileSymbolList &List)
 
unsigned size ()
 
void setToCompress (bool TC)
 
bool toCompress ()
 
std::error_code read (const uint8_t *Data, uint64_t ListSize)
 
std::error_code write (raw_ostream &OS)
 
void dump (raw_ostream &OS=dbgs()) const
 

Detailed Description

ProfileSymbolList records the list of function symbols shown up in the binary used to generate the profile.

It is useful to to discriminate a function being so cold as not to shown up in the profile and a function newly added.

Definition at line 1513 of file SampleProf.h.

Member Function Documentation

◆ add()

void llvm::sampleprof::ProfileSymbolList::add ( StringRef  Name,
bool  Copy = false 
)
inline

copy indicates whether we need to copy the underlying memory for the input Name.

Definition at line 1517 of file SampleProf.h.

References Name.

Referenced by merge(), and read().

◆ contains()

bool llvm::sampleprof::ProfileSymbolList::contains ( StringRef  Name)
inline

Definition at line 1525 of file SampleProf.h.

References Name.

◆ dump()

void ProfileSymbolList::dump ( raw_ostream OS = dbgs()) const

Definition at line 420 of file SampleProf.cpp.

References OS, llvm::sort(), and Sym.

◆ merge()

void llvm::sampleprof::ProfileSymbolList::merge ( const ProfileSymbolList List)
inline

Definition at line 1527 of file SampleProf.h.

References add(), llvm::List, and Sym.

◆ read()

std::error_code ProfileSymbolList::read ( const uint8_t *  Data,
uint64_t  ListSize 
)

Definition at line 331 of file SampleProf.cpp.

References add(), llvm::Data, llvm::malformed, ProfileSymbolListCutOff, Size, and llvm::success.

◆ setToCompress()

void llvm::sampleprof::ProfileSymbolList::setToCompress ( bool  TC)
inline

Definition at line 1534 of file SampleProf.h.

◆ size()

unsigned llvm::sampleprof::ProfileSymbolList::size ( )
inline

◆ toCompress()

bool llvm::sampleprof::ProfileSymbolList::toCompress ( )
inline

◆ write()

std::error_code ProfileSymbolList::write ( raw_ostream OS)

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