LLVM 22.0.0git
Classes | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Friends | List of all members
llvm::cas::ReferenceBase Class Reference

Base class for references to things in ObjectStore. More...

#include "llvm/CAS/CASReference.h"

Inheritance diagram for llvm::cas::ReferenceBase:
[legend]

Classes

struct  DenseMapEmptyTag
 
struct  DenseMapTombstoneTag
 

Public Member Functions

uint64_t getInternalRef (const ObjectStore &ExpectedCAS) const
 Get an internal reference.
 
unsigned getDenseMapHash () const
 Helper functions for DenseMapInfo.
 
bool isDenseMapEmpty () const
 
bool isDenseMapTombstone () const
 
bool isDenseMapSentinel () const
 

Protected Member Functions

void print (raw_ostream &OS, const ObjectHandle &This) const
 
void print (raw_ostream &OS, const ObjectRef &This) const
 
bool hasSameInternalRef (const ReferenceBase &RHS) const
 
 ReferenceBase (const ObjectStore *CAS, uint64_t InternalRef, bool IsHandle)
 
 ReferenceBase (DenseMapEmptyTag)
 
 ReferenceBase (DenseMapTombstoneTag)
 

Static Protected Member Functions

static constexpr uint64_t getDenseMapEmptyRef ()
 
static constexpr uint64_t getDenseMapTombstoneRef ()
 

Friends

class ObjectStore
 

Detailed Description

Base class for references to things in ObjectStore.

Definition at line 27 of file CASReference.h.

Constructor & Destructor Documentation

◆ ReferenceBase() [1/3]

llvm::cas::ReferenceBase::ReferenceBase ( const ObjectStore CAS,
uint64_t  InternalRef,
bool  IsHandle 
)
inlineprotected

Definition at line 70 of file CASReference.h.

References assert(), getDenseMapEmptyRef(), and getDenseMapTombstoneRef().

◆ ReferenceBase() [2/3]

llvm::cas::ReferenceBase::ReferenceBase ( DenseMapEmptyTag  )
inlineexplicitprotected

Definition at line 79 of file CASReference.h.

◆ ReferenceBase() [3/3]

llvm::cas::ReferenceBase::ReferenceBase ( DenseMapTombstoneTag  )
inlineexplicitprotected

Definition at line 81 of file CASReference.h.

Member Function Documentation

◆ getDenseMapEmptyRef()

static constexpr uint64_t llvm::cas::ReferenceBase::getDenseMapEmptyRef ( )
inlinestaticconstexprprotected

Definition at line 31 of file CASReference.h.

Referenced by isDenseMapEmpty(), and ReferenceBase().

◆ getDenseMapHash()

unsigned llvm::cas::ReferenceBase::getDenseMapHash ( ) const
inline

Helper functions for DenseMapInfo.

Definition at line 44 of file CASReference.h.

References llvm::hash_value().

◆ getDenseMapTombstoneRef()

static constexpr uint64_t llvm::cas::ReferenceBase::getDenseMapTombstoneRef ( )
inlinestaticconstexprprotected

Definition at line 32 of file CASReference.h.

Referenced by isDenseMapTombstone(), and ReferenceBase().

◆ getInternalRef()

uint64_t llvm::cas::ReferenceBase::getInternalRef ( const ObjectStore ExpectedCAS) const
inline

Get an internal reference.

Definition at line 36 of file CASReference.h.

References assert().

◆ hasSameInternalRef()

bool llvm::cas::ReferenceBase::hasSameInternalRef ( const ReferenceBase RHS) const
inlineprotected

Definition at line 59 of file CASReference.h.

References assert(), isDenseMapSentinel(), and RHS.

◆ isDenseMapEmpty()

bool llvm::cas::ReferenceBase::isDenseMapEmpty ( ) const
inline

Definition at line 47 of file CASReference.h.

References getDenseMapEmptyRef().

Referenced by isDenseMapSentinel().

◆ isDenseMapSentinel()

bool llvm::cas::ReferenceBase::isDenseMapSentinel ( ) const
inline

Definition at line 51 of file CASReference.h.

References isDenseMapEmpty(), and isDenseMapTombstone().

Referenced by hasSameInternalRef().

◆ isDenseMapTombstone()

bool llvm::cas::ReferenceBase::isDenseMapTombstone ( ) const
inline

Definition at line 48 of file CASReference.h.

References getDenseMapTombstoneRef().

Referenced by isDenseMapSentinel().

◆ print() [1/2]

void ReferenceBase::print ( raw_ostream OS,
const ObjectHandle This 
) const
protected

Definition at line 40 of file ObjectStore.cpp.

References assert(), OS, and printReferenceBase().

Referenced by llvm::cas::ObjectRef::print(), and llvm::cas::ObjectHandle::print().

◆ print() [2/2]

void ReferenceBase::print ( raw_ostream OS,
const ObjectRef This 
) const
protected

Definition at line 45 of file ObjectStore.cpp.

References assert(), OS, and printReferenceBase().

Friends And Related Function Documentation

◆ ObjectStore

friend class ObjectStore
friend

Definition at line 69 of file CASReference.h.


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