LLVM: llvm::sampleprof::FunctionPruningStrategy Class Reference (original) (raw)

When writing a profile with size limit, user may want to use a different strategy to reduce function count other than dropping functions with fewest samples first. More...

#include "[llvm/ProfileData/SampleProfWriter.h](SampleProfWriter%5F8h%5Fsource.html)"

Public Member Functions
FunctionPruningStrategy (SampleProfileMap &ProfileMap, size_t OutputSizeLimit)
ProfileMap A reference to the original profile map.
virtual ~FunctionPruningStrategy ()=default
virtual void Erase (size_t CurrentOutputSize)=0
SampleProfileWriter::writeWithSizeLimit() calls this after every write iteration if the output size still exceeds the limit.

When writing a profile with size limit, user may want to use a different strategy to reduce function count other than dropping functions with fewest samples first.

In this case a class implementing the same interfaces should be provided to SampleProfileWriter::writeWithSizeLimit().

Definition at line 43 of file SampleProfWriter.h.

llvm::sampleprof::FunctionPruningStrategy::FunctionPruningStrategy ( SampleProfileMap & ProfileMap, size_t OutputSizeLimit ) inline

~FunctionPruningStrategy()

virtual llvm::sampleprof::FunctionPruningStrategy::~FunctionPruningStrategy ( ) virtualdefault

Erase()

virtual void llvm::sampleprof::FunctionPruningStrategy::Erase ( size_t CurrentOutputSize) pure virtual

OutputSizeLimit

size_t llvm::sampleprof::FunctionPruningStrategy::OutputSizeLimit protected

ProfileMap


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