LMTQueue< T, N > Class Template Reference

A size-limited multiple-producer, multiple-consumer, thread-safe queue implemented using SystemC primitives The LMTQueue is used as the input buffer in the NPU modules. More...

#include <LMTQueue.h>

+ Collaboration diagram for LMTQueue< T, N >:

Public Member Functions

 LMTQueue ()
 Construct a LMTQueue.
 
pop ()
 Pop the top element from the LMTQueue and return a copy. More...
 
void pop (T &item)
 Pop the top element from the LMTQueue and copy it into the output argument. More...
 
void push (const T &item)
 Push an item onto the LMTQueue. More...
 
void push (T &&item)
 Push an item onto the LMTQueue (explicit move) More...
 
size_t available () const
 
bool full () const
 
bool empty () const
 

Detailed Description

template<typename T, size_t N>
class LMTQueue< T, N >

A size-limited multiple-producer, multiple-consumer, thread-safe queue implemented using SystemC primitives The LMTQueue is used as the input buffer in the NPU modules.

Member Function Documentation

template<typename T , size_t N>
T LMTQueue< T, N >::pop ( )
inline

Pop the top element from the LMTQueue and return a copy.

Returns
Copy of the top element
template<typename T , size_t N>
void LMTQueue< T, N >::pop ( T &  item)
inline

Pop the top element from the LMTQueue and copy it into the output argument.

Parameters
Outputargument
template<typename T , size_t N>
void LMTQueue< T, N >::push ( const T &  item)
inline

Push an item onto the LMTQueue.

Parameters
Itemto push
template<typename T , size_t N>
void LMTQueue< T, N >::push ( T &&  item)
inline

Push an item onto the LMTQueue (explicit move)

Parameters
Itemto move

The documentation for this class was generated from the following file:
  • /home/lemniscate/workspace/PFPSim/pfpsim/core/LMTQueue.h