Base class for a lock‐free thread‐safe hash‐mapped trie.

Synopsis

Declared in <llvm/ADT/TrieRawHashMap.h>

class ThreadSafeTrieRawHashMapBase;

Member Functions

Name

Description

dump

Dump a debug representation of the trie to stderr.

operator delete

Deallocate memory previously obtained from operator new.

print

Print a debug representation of the trie to OS.

Static Member Functions

Name

Description

operator new

Allocate a ThreadSafeTrieRawHashMapBase with the global operator new.

Static Data Members

Name

Description

DefaultNumRootBits

Default number of hash bits consumed by the root trie node.

DefaultNumSubtrieBits

Default number of hash bits consumed by each subtrie node.

TrieContentBaseSize

Size of the fixed header preceding each content allocation.

Protected Types

Name

Description

PointerBase

Result of a lookup, suitable as an insertion hint.

Protected Member Functions

Name

Description

ThreadSafeTrieRawHashMapBase [constructor]

Constructors

~ThreadSafeTrieRawHashMapBase [destructor]

Destructor, which asserts if there's anything to do. Subclasses should call destroyImpl().

operator=

Assignment operators

destroyImpl

Destroy all stored values and free trie nodes.

find

Find the stored content with hash.

getNextTrie

Return the next trie node after P in the allocation chain.

getNumBits

Return how many hash bits the trie node referred to by P consumes.

getNumSlotUsed

Return how many slots are occupied in the trie node referred to by P.

getNumTries

Return the number of trie nodes currently allocated.

getRoot

Return a pointer base referring to the root trie node.

getStartBit

Return the starting hash bit index for the trie node referred to by P.

getTriePrefixAsString

Return the hash prefix for the trie node referred to by P as a string.

insert

Insert and return the stored content.

Protected Static Data Members

Name

Description

DefaultContentAllocAlign

Default allocation alignment for content of type T.

DefaultContentAllocSize

Default allocation size for content of type T.

DefaultContentOffset

Byte offset of content of type T within its allocation.

Friends

Name

Description

llvm::TrieRawHashMapTestHelper

Helper used by unit tests to inspect ThreadSafeTrieRawHashMapBase internals.

Derived Classes

Name

Description

ThreadSafeTrieRawHashMap

Lock‐free thread‐safe hash‐mapped trie.

Created with MrDocs