class DenseMapBase

Declaration

template <typename DerivedT,
          typename KeyT,
          typename ValueT,
          typename KeyInfoT,
          typename BucketT>
class DenseMapBase : public DebugEpochBase { /* full declaration omitted */ };

Declared at: llvm/include/llvm/ADT/DenseMap.h:59

Inherits from: DebugEpochBase

Templates

DerivedT
KeyT
ValueT
KeyInfoT
BucketT

Method Overview

  • protected DenseMapBase<DerivedT, KeyT, ValueT, KeyInfoT, BucketT>()
  • public llvm::DenseMapBase::value_type & FindAndConstruct(KeyT && Key)
  • public llvm::DenseMapBase::value_type & FindAndConstruct(const KeyT & Key)
  • public inline llvm::DenseMapBase::const_iterator begin() const
  • public inline llvm::DenseMapBase::iterator begin()
  • public void clear()
  • protected template <typename OtherBaseT>void copyFrom(const DenseMapBase<OtherBaseT, KeyT, ValueT, KeyInfoT, BucketT> & other)
  • public llvm::DenseMapBase::size_type count(const_arg_type_t<KeyT> Val) const
  • protected void destroyAll()
  • public bool empty() const
  • public inline llvm::DenseMapBase::iterator end()
  • public inline llvm::DenseMapBase::const_iterator end() const
  • public bool erase(const KeyT & Val)
  • public void erase(llvm::DenseMapBase::iterator I)
  • public llvm::DenseMapBase::const_iterator find(const_arg_type_t<KeyT> Val) const
  • public llvm::DenseMapBase::iterator find(const_arg_type_t<KeyT> Val)
  • public template <class LookupKeyT>llvm::DenseMapBase::const_iterator find_as(const LookupKeyT & Val) const
  • public template <class LookupKeyT>llvm::DenseMapBase::iterator find_as(const LookupKeyT & Val)
  • protected static const KeyT getEmptyKey()
  • protected static unsigned int getHashValue(const KeyT & Val)
  • protected template <typename LookupKeyT>static unsigned int getHashValue(const LookupKeyT & Val)
  • public size_t getMemorySize() const
  • protected unsigned int getMinBucketToReserveForEntries(unsigned int NumEntries)
  • public const void * getPointerIntoBucketsArray() const
  • protected static const KeyT getTombstoneKey()
  • protected void initEmpty()
  • public std::pair<iterator, bool> insert(std::pair<KeyT, ValueT> && KV)
  • public std::pair<iterator, bool> insert(const std::pair<KeyT, ValueT> & KV)
  • public template <typename InputIt>void insert(InputIt I, InputIt E)
  • public template <typename LookupKeyT>std::pair<iterator, bool> insert_as(std::pair<KeyT, ValueT> && KV, const LookupKeyT & Val)
  • public bool isPointerIntoBucketsArray(const void * Ptr) const
  • public ValueT lookup(const_arg_type_t<KeyT> Val) const
  • protected void moveFromOldBuckets(BucketT * OldBucketsBegin, BucketT * OldBucketsEnd)
  • public void reserve(llvm::DenseMapBase::size_type NumEntries)
  • public unsigned int size() const
  • public template <typename... Ts>std::pair<iterator, bool> try_emplace(KeyT && Key, Ts &&... Args)
  • public template <typename... Ts>std::pair<iterator, bool> try_emplace(const KeyT & Key, Ts &&... Args)

Inherited from DebugEpochBase:

Methods

DenseMapBase<DerivedT,
             KeyT,
             ValueT,
             KeyInfoT,
             BucketT>()

Declared at: llvm/include/llvm/ADT/DenseMap.h:328

llvm::DenseMapBase::value_type& FindAndConstruct(
    KeyT&& Key)

Declared at: llvm/include/llvm/ADT/DenseMap.h:303

Parameters

KeyT&& Key

llvm::DenseMapBase::value_type& FindAndConstruct(
    const KeyT& Key)

Declared at: llvm/include/llvm/ADT/DenseMap.h:291

Parameters

const KeyT& Key

inline llvm::DenseMapBase::const_iterator begin()
    const

Declared at: llvm/include/llvm/ADT/DenseMap.h:85

inline llvm::DenseMapBase::iterator begin()

Declared at: llvm/include/llvm/ADT/DenseMap.h:73

void clear()

Declared at: llvm/include/llvm/ADT/DenseMap.h:110

template <typename OtherBaseT>
void copyFrom(const DenseMapBase<OtherBaseT,
                                 KeyT,
                                 ValueT,
                                 KeyInfoT,
                                 BucketT>& other)

Declared at: llvm/include/llvm/ADT/DenseMap.h:391

Templates

OtherBaseT

Parameters

const DenseMapBase<OtherBaseT, KeyT, ValueT, KeyInfoT, BucketT>& other

llvm::DenseMapBase::size_type count(
    const_arg_type_t<KeyT> Val) const

Description

Return 1 if the specified key is in the map, 0 otherwise.

Declared at: llvm/include/llvm/ADT/DenseMap.h:145

Parameters

const_arg_type_t<KeyT> Val

void destroyAll()

Declared at: llvm/include/llvm/ADT/DenseMap.h:330

bool empty() const

Declared at: llvm/include/llvm/ADT/DenseMap.h:96

inline llvm::DenseMapBase::iterator end()

Declared at: llvm/include/llvm/ADT/DenseMap.h:82

inline llvm::DenseMapBase::const_iterator end()
    const

Declared at: llvm/include/llvm/ADT/DenseMap.h:92

bool erase(const KeyT& Val)

Declared at: llvm/include/llvm/ADT/DenseMap.h:272

Parameters

const KeyT& Val

void erase(llvm::DenseMapBase::iterator I)

Declared at: llvm/include/llvm/ADT/DenseMap.h:283

Parameters

llvm::DenseMapBase::iterator I

llvm::DenseMapBase::const_iterator find(
    const_arg_type_t<KeyT> Val) const

Declared at: llvm/include/llvm/ADT/DenseMap.h:156

Parameters

const_arg_type_t<KeyT> Val

llvm::DenseMapBase::iterator find(
    const_arg_type_t<KeyT> Val)

Declared at: llvm/include/llvm/ADT/DenseMap.h:150

Parameters

const_arg_type_t<KeyT> Val

template <class LookupKeyT>
llvm::DenseMapBase::const_iterator find_as(
    const LookupKeyT& Val) const

Declared at: llvm/include/llvm/ADT/DenseMap.h:176

Templates

LookupKeyT

Parameters

const LookupKeyT& Val

template <class LookupKeyT>
llvm::DenseMapBase::iterator find_as(
    const LookupKeyT& Val)

Description

Alternate version of find() which allows a different, and possibly less expensive, key type. The DenseMapInfo is responsible for supplying methods getHashValue(LookupKeyT) and isEqual(LookupKeyT, KeyT) for each key type used.

Declared at: llvm/include/llvm/ADT/DenseMap.h:169

Templates

LookupKeyT

Parameters

const LookupKeyT& Val

static const KeyT getEmptyKey()

Declared at: llvm/include/llvm/ADT/DenseMap.h:423

static unsigned int getHashValue(const KeyT& Val)

Declared at: llvm/include/llvm/ADT/DenseMap.h:414

Parameters

const KeyT& Val

template <typename LookupKeyT>
static unsigned int getHashValue(
    const LookupKeyT& Val)

Declared at: llvm/include/llvm/ADT/DenseMap.h:419

Templates

LookupKeyT

Parameters

const LookupKeyT& Val

size_t getMemorySize() const

Description

Return the approximate size (in bytes) of the actual map. This is just the raw memory used by DenseMap. If entries are pointers to objects, the size of the referenced objects are not included.

Declared at: llvm/include/llvm/ADT/DenseMap.h:642

unsigned int getMinBucketToReserveForEntries(
    unsigned int NumEntries)

Description

Returns the number of buckets to allocate to ensure that the DenseMap can accommodate \p NumEntries without need to grow().

Declared at: llvm/include/llvm/ADT/DenseMap.h:356

Parameters

unsigned int NumEntries

const void* getPointerIntoBucketsArray() const

Description

getPointerIntoBucketsArray() - Return an opaque pointer into the buckets array. In conjunction with the previous method, this can be used to determine whether an insertion caused the DenseMap to reallocate.

Declared at: llvm/include/llvm/ADT/DenseMap.h:325

static const KeyT getTombstoneKey()

Declared at: llvm/include/llvm/ADT/DenseMap.h:429

void initEmpty()

Declared at: llvm/include/llvm/ADT/DenseMap.h:343

std::pair<iterator, bool> insert(
    std::pair<KeyT, ValueT>&& KV)

Declared at: llvm/include/llvm/ADT/DenseMap.h:202

Parameters

std::pair<KeyT, ValueT>&& KV

std::pair<iterator, bool> insert(
    const std::pair<KeyT, ValueT>& KV)

Declared at: llvm/include/llvm/ADT/DenseMap.h:195

Parameters

const std::pair<KeyT, ValueT>& KV

template <typename InputIt>
void insert(InputIt I, InputIt E)

Description

insert - Range insertion of pairs.

Declared at: llvm/include/llvm/ADT/DenseMap.h:267

Templates

InputIt

Parameters

InputIt I
InputIt E

template <typename LookupKeyT>
std::pair<iterator, bool> insert_as(
    std::pair<KeyT, ValueT>&& KV,
    const LookupKeyT& Val)

Description

Alternate version of insert() which allows a different, and possibly less expensive, key type. The DenseMapInfo is responsible for supplying methods getHashValue(LookupKeyT) and isEqual(LookupKeyT, KeyT) for each key type used.

Declared at: llvm/include/llvm/ADT/DenseMap.h:249

Templates

LookupKeyT

Parameters

std::pair<KeyT, ValueT>&& KV
const LookupKeyT& Val

bool isPointerIntoBucketsArray(
    const void* Ptr) const

Description

isPointerIntoBucketsArray - Return true if the specified pointer points somewhere into the DenseMap's array of buckets (i.e. either to a key or value in the DenseMap).

Declared at: llvm/include/llvm/ADT/DenseMap.h:318

Parameters

const void* Ptr

ValueT lookup(const_arg_type_t<KeyT> Val) const

Description

lookup - Return the entry for the specified key, or a default constructed value if no such entry exists.

Declared at: llvm/include/llvm/ADT/DenseMap.h:185

Parameters

const_arg_type_t<KeyT> Val

void moveFromOldBuckets(BucketT* OldBucketsBegin,
                        BucketT* OldBucketsEnd)

Declared at: llvm/include/llvm/ADT/DenseMap.h:365

Parameters

BucketT* OldBucketsBegin
BucketT* OldBucketsEnd

void reserve(
    llvm::DenseMapBase::size_type NumEntries)

Description

Grow the densemap so that it can contain at least \p NumEntries items before resizing again.

Declared at: llvm/include/llvm/ADT/DenseMap.h:103

Parameters

llvm::DenseMapBase::size_type NumEntries

unsigned int size() const

Declared at: llvm/include/llvm/ADT/DenseMap.h:99

template <typename... Ts>
std::pair<iterator, bool> try_emplace(
    KeyT&& Key,
    Ts&&... Args)

Declared at: llvm/include/llvm/ADT/DenseMap.h:210

Templates

Ts

Parameters

KeyT&& Key
Ts&&... Args

template <typename... Ts>
std::pair<iterator, bool> try_emplace(
    const KeyT& Key,
    Ts&&... Args)

Declared at: llvm/include/llvm/ADT/DenseMap.h:229

Templates

Ts

Parameters

const KeyT& Key
Ts&&... Args