Thanks to visit codestin.com
Credit goes to llvm.org

LLVM 22.0.0git
llvm::sampleprof::SampleProfileMap Class Reference

This class provides operator overloads to the map container using MD5 as the key type, so that existing code can still work in most cases using SampleContext as key. More...

#include "llvm/ProfileData/SampleProf.h"

Inheritance diagram for llvm::sampleprof::SampleProfileMap:
[legend]

Public Member Functions

mapped_typecreate (const SampleContext &Ctx)
iterator find (const SampleContext &Ctx)
const_iterator find (const SampleContext &Ctx) const
size_t erase (const SampleContext &Ctx)
size_t erase (const key_type &Key)
iterator erase (iterator It)
Public Member Functions inherited from llvm::sampleprof::HashKeyMap< std::unordered_map, SampleContext, FunctionSamples >
std::pair< iterator, booltry_emplace (const key_type &Hash, const original_key_type &Key, Ts &&...Args)
std::pair< iterator, boolemplace (Ts &&...Args)
mapped_typeoperator[] (const original_key_type &Key)
iterator find (const original_key_type &Key)
mapped_type lookup (const original_key_type &Key) const
size_t count (const original_key_type &Key) const
size_t erase (const original_key_type &Ctx)

Additional Inherited Members

Public Types inherited from llvm::sampleprof::HashKeyMap< std::unordered_map, SampleContext, FunctionSamples >
using base_type
using key_type
using original_key_type
using mapped_type
using value_type
using iterator
using const_iterator

Detailed Description

This class provides operator overloads to the map container using MD5 as the key type, so that existing code can still work in most cases using SampleContext as key.

Note: when populating container, make sure to assign the SampleContext to the mapped value immediately because the key no longer holds it.

Definition at line 1439 of file SampleProf.h.

Member Function Documentation

◆ create()

◆ erase() [1/3]

size_t llvm::sampleprof::SampleProfileMap::erase ( const key_type & Key)
inline

◆ erase() [2/3]

size_t llvm::sampleprof::SampleProfileMap::erase ( const SampleContext & Ctx)
inline

◆ erase() [3/3]

iterator llvm::sampleprof::SampleProfileMap::erase ( iterator It)
inline

Definition at line 1468 of file SampleProf.h.

◆ find() [1/2]

iterator llvm::sampleprof::SampleProfileMap::find ( const SampleContext & Ctx)
inline

◆ find() [2/2]

const_iterator llvm::sampleprof::SampleProfileMap::find ( const SampleContext & Ctx) const
inline

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