LLVM 20.0.0git
|
Non-owning SymbolStringPool entry pointer. More...
#include "llvm/ExecutionEngine/Orc/SymbolStringPool.h"
Public Member Functions | |
NonOwningSymbolStringPtr ()=default | |
NonOwningSymbolStringPtr (const SymbolStringPtr &S) | |
Public Member Functions inherited from llvm::orc::SymbolStringPtrBase | |
SymbolStringPtrBase ()=default | |
SymbolStringPtrBase (std::nullptr_t) | |
operator bool () const | |
StringRef | operator* () const |
bool | poolEntryIsAlive () const |
Friends | |
struct | DenseMapInfo< orc::NonOwningSymbolStringPtr > |
Additional Inherited Members | |
Protected Types inherited from llvm::orc::SymbolStringPtrBase | |
using | PoolEntry = SymbolStringPool::PoolMapEntry |
using | PoolEntryPtr = PoolEntry * |
Protected Member Functions inherited from llvm::orc::SymbolStringPtrBase | |
SymbolStringPtrBase (PoolEntryPtr S) | |
size_t | getRefCount () const |
Static Protected Member Functions inherited from llvm::orc::SymbolStringPtrBase | |
static bool | isRealPoolEntry (PoolEntryPtr P) |
Protected Attributes inherited from llvm::orc::SymbolStringPtrBase | |
PoolEntryPtr | S = nullptr |
Static Protected Attributes inherited from llvm::orc::SymbolStringPtrBase | |
static constexpr uintptr_t | EmptyBitPattern |
static constexpr uintptr_t | TombstoneBitPattern |
static constexpr uintptr_t | InvalidPtrMask |
Non-owning SymbolStringPool entry pointer.
Instances are comparable with SymbolStringPtr instances and guaranteed to have the same hash, but do not affect the ref-count of the pooled string (and are therefore cheaper to copy).
NonOwningSymbolStringPtrs are silently invalidated if the pool entry's ref-count drops to zero, so they should only be used in contexts where a corresponding SymbolStringPtr is known to exist (which will guarantee that the ref-count stays above zero). E.g. in a graph where nodes are represented by SymbolStringPtrs the edges can be represented by pairs of NonOwningSymbolStringPtrs and this will make the introduction of deletion of edges cheaper.
Definition at line 246 of file SymbolStringPool.h.
|
default |
|
inlineexplicit |
Definition at line 251 of file SymbolStringPool.h.
|
friend |
Definition at line 231 of file SymbolStringPool.h.