GlobalMemorySlot Class Reference

HiCR: HiCR::GlobalMemorySlot Class Reference
HiCR
HiCR::GlobalMemorySlot Class Reference

#include <globalMemorySlot.hpp>

Inheritance diagram for HiCR::GlobalMemorySlot:
HiCR::backend::hwloc::GlobalMemorySlot HiCR::backend::lpf::GlobalMemorySlot HiCR::backend::mpi::GlobalMemorySlot

Public Types

using globalKey_t = uint64_t
 
using tag_t = uint64_t
 

Public Member Functions

 GlobalMemorySlot (const tag_t globalTag=0, const globalKey_t globalKey=0, std::shared_ptr< HiCR::LocalMemorySlot > sourceLocalMemorySlot=nullptr)
 
virtual ~GlobalMemorySlot ()=default
 
__INLINE__ tag_t getGlobalTag () const noexcept
 
__INLINE__ globalKey_t getGlobalKey () const noexcept
 
__INLINE__ std::shared_ptr< HiCR::LocalMemorySlotgetSourceLocalMemorySlot () noexcept
 

Detailed Description

This class represents an abstract definition for a Global Memory Slot resource in HiCR that:

  • Represents a contiguous segment of memory located in a non-local memory space

Member Typedef Documentation

◆ globalKey_t

Type definition for a global key (for exchanging global memory slots)

◆ tag_t

Type definition for a communication tag

Constructor & Destructor Documentation

◆ GlobalMemorySlot()

HiCR::GlobalMemorySlot::GlobalMemorySlot ( const tag_t  globalTag = 0,
const globalKey_t  globalKey = 0,
std::shared_ptr< HiCR::LocalMemorySlot sourceLocalMemorySlot = nullptr 
)
inline

Default constructor for a MemorySlot class

Parameters
[in]globalTagFor global memory slots, indicates the subset of global memory slots this belongs to
[in]globalKeyUnique identifier for that memory slot that this slot occupies.
[in]sourceLocalMemorySlotIndicates the source local memory slot (if any) that was promoted into this global memory slot. If none exists, a nullptr value is provided that encodes that the global memory slot is non-local (remote)

◆ ~GlobalMemorySlot()

virtual HiCR::GlobalMemorySlot::~GlobalMemorySlot ( )
virtualdefault

Member Function Documentation

◆ getGlobalKey()

__INLINE__ globalKey_t HiCR::GlobalMemorySlot::getGlobalKey ( ) const
inlinenoexcept

Getter function for the memory slot's global key

Returns
The memory slot's global key

◆ getGlobalTag()

__INLINE__ tag_t HiCR::GlobalMemorySlot::getGlobalTag ( ) const
inlinenoexcept

Getter function for the memory slot's global tag

Returns
The memory slot's global tag

◆ getSourceLocalMemorySlot()

__INLINE__ std::shared_ptr< HiCR::LocalMemorySlot > HiCR::GlobalMemorySlot::getSourceLocalMemorySlot ( )
inlinenoexcept

Function to return the source local memory slot from which this global slot was created, if one exists (if not, it's a remote memory slot)

Returns
A pointer to the local memory slot from which this global memory slot was created, if one exists. A null pointer, otherwise.

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