16 #ifndef BLOOMBERG_QUANTUM_IQUEUE_H 17 #define BLOOMBERG_QUANTUM_IQUEUE_H 19 #include <quantum/quantum_spinlock.h> 20 #include <quantum/interface/quantum_iterminate.h> 21 #include <quantum/interface/quantum_itask.h> 22 #include <quantum/interface/quantum_iqueue_statistics.h> 23 #include <quantum/quantum_allocator.h> 36 using Ptr = std::shared_ptr<IQueue>;
43 virtual void run() = 0;
53 virtual size_t size()
const = 0;
55 virtual bool empty()
const = 0;
63 virtual bool isIdle()
const = 0;
68 #ifndef __QUANTUM_QUEUE_LIST_ALLOC_SIZE 69 #define __QUANTUM_QUEUE_LIST_ALLOC_SIZE __QUANTUM_DEFAULT_POOL_ALLOC_SIZE 71 #ifndef __QUANTUM_USE_DEFAULT_ALLOCATOR 72 #ifdef __QUANTUM_ALLOCATE_POOL_FROM_HEAP 83 #endif //BLOOMBERG_QUANTUM_IQUEUE_H virtual void signalEmptyCondition(bool value)=0
QueueType
Definition: quantum_iqueue.h:37
Definition: quantum_buffer_impl.h:22
virtual ITask::Ptr tryDequeue(std::atomic_bool &hint)=0
virtual bool tryEnqueue(ITask::Ptr task)=0
Definition: quantum_allocator.h:36
std::shared_ptr< ITask > Ptr
Definition: quantum_itask.h:34
Provides a stack-based object pool to the underlying ContiguousPoolManager. The default buffer size i...
Definition: quantum_stack_allocator.h:34
Interface to a task queue. For internal use only.
Definition: quantum_iqueue.h:33
virtual IQueueStatistics & stats()=0
virtual bool isIdle() const =0
virtual void pinToCore(int coreId)=0
virtual size_t size() const =0
std::shared_ptr< IQueue > Ptr
Definition: quantum_iqueue.h:36
virtual SpinLock & getLock()=0
Provides a heap-based object pool to the underlying ContiguousPoolManager. The default buffer size is...
Definition: quantum_heap_allocator.h:33
virtual ITask::Ptr dequeue(std::atomic_bool &hint)=0
IQueue::Ptr IQueuePtr
Definition: quantum_iqueue.h:66
Interface to access and manipulate a QueueStatistics object.
Definition: quantum_iqueue_statistics.h:29
virtual void enqueue(ITask::Ptr task)=0
QueueId
Definition: quantum_iqueue.h:38
virtual bool empty() const =0