LLVM 17.0.0git
Public Member Functions | List of all members
llvm::sampleprof::SampleContextTrimmer Class Reference

SampleContextTrimmer impelements helper functions to trim, merge cold context profiles. More...

#include "llvm/ProfileData/SampleProf.h"

Public Member Functions

 SampleContextTrimmer (SampleProfileMap &Profiles)
 
void trimAndMergeColdContextProfiles (uint64_t ColdCountThreshold, bool TrimColdContext, bool MergeColdContext, uint32_t ColdContextFrameLength, bool TrimBaseProfileOnly)
 
void canonicalizeContextProfiles ()
 

Detailed Description

SampleContextTrimmer impelements helper functions to trim, merge cold context profiles.

It also supports context profile canonicalization to make sure ProfileMap's key is consistent with FunctionSample's name/context.

Definition at line 1255 of file SampleProf.h.

Constructor & Destructor Documentation

◆ SampleContextTrimmer()

llvm::sampleprof::SampleContextTrimmer::SampleContextTrimmer ( SampleProfileMap Profiles)
inline

Definition at line 1257 of file SampleProf.h.

Member Function Documentation

◆ canonicalizeContextProfiles()

void SampleContextTrimmer::canonicalizeContextProfiles ( )

Definition at line 403 of file SampleProf.cpp.

References assert(), Context, llvm::sampleprof::FunctionSamples::getContext(), and I.

◆ trimAndMergeColdContextProfiles()

void SampleContextTrimmer::trimAndMergeColdContextProfiles ( uint64_t  ColdCountThreshold,
bool  TrimColdContext,
bool  MergeColdContext,
uint32_t  ColdContextFrameLength,
bool  TrimBaseProfileOnly 
)

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