Base Class Reference

HiCR: HiCR::channel::fixedSize::Base Class Reference
HiCR
HiCR::channel::fixedSize::Base Class Reference

#include <base.hpp>

Inheritance diagram for HiCR::channel::fixedSize::Base:
HiCR::channel::Base HiCR::channel::fixedSize::MPSC::locking::Consumer HiCR::channel::fixedSize::MPSC::locking::Producer HiCR::channel::fixedSize::SPSC::Consumer HiCR::channel::fixedSize::SPSC::Producer HiCR::channel::fixedSize::MPSC::nonlocking::Producer

Protected Member Functions

 Base (CommunicationManager &communicationManager, const std::shared_ptr< LocalMemorySlot > &coordinationBuffer, const size_t tokenSize, const size_t capacity)
 
- Protected Member Functions inherited from HiCR::channel::Base
 Base (CommunicationManager &communicationManager, const std::shared_ptr< LocalMemorySlot > &coordinationBuffer, const size_t tokenSize, const size_t capacity)
 
__INLINE__ CommunicationManagergetCommunicationManager () const
 
__INLINE__ auto getCoordinationBuffer () const
 

Additional Inherited Members

- Public Member Functions inherited from HiCR::channel::Base
__INLINE__ size_t getTokenSize () const noexcept
 
__INLINE__ size_t getDepth () const noexcept
 
__INLINE__ bool isFull () const noexcept
 
__INLINE__ bool isEmpty () const noexcept
 
__INLINE__ auto getCircularBuffer () const noexcept
 
- Static Public Member Functions inherited from HiCR::channel::Base
static __INLINE__ size_t getCoordinationBufferSize () noexcept
 
static __INLINE__ void initializeCoordinationBuffer (const std::shared_ptr< LocalMemorySlot > &coordinationBuffer)
 
static __INLINE__ size_t getTokenBufferSize (const size_t tokenSize, const size_t capacity) noexcept
 

Detailed Description

Base class definition for a HiCR fixed-size channel Fixed-size version is identical to the base channel.

Constructor & Destructor Documentation

◆ Base()

HiCR::channel::fixedSize::Base::Base ( CommunicationManager communicationManager,
const std::shared_ptr< LocalMemorySlot > &  coordinationBuffer,
const size_t  tokenSize,
const size_t  capacity 
)
inlineprotected

The constructor of the Channel class.

It requires the user to provide the allocated memory slots for the exchange (data) and coordination buffers.

Parameters
[in]communicationManagerThe backend's memory manager to facilitate communication between the producer and consumer sides
[in]coordinationBufferThis is a small buffer that needs to be allocated at the producer side. enables the consumer to signal how many tokens it has popped. It may also be used for other coordination signals.
[in]tokenSizeThe size of each token.
[in]capacityThe maximum number of tokens that will be held by this channel

The documentation for this class was generated from the following file:
  • /home/runner/work/HiCR/HiCR/include/hicr/frontends/channel/fixedSize/base.hpp