QuantumLibrary
Bloomberg::quantum::AllocatorTraits Struct Reference

Allows application-wide settings for the various allocators used by Quantum. More...

#include <quantum_allocator_traits.h>

Public Types

using size_type = uint16_t
 

Static Public Member Functions

static bool & useDefaultAllocator ()
 Get/set if the system allocator should be used for internal objects (other than coroutine stacks). More...
 
static bool & useDefaultCoroAllocator ()
 Get/set if the system allocator should be used for coroutine stacks. More...
 
static bool & allocatePoolFromHeap ()
 Get/set if the allocator pool for internal objects should use the heap or the application stack. More...
 
static size_typedefaultPoolAllocSize ()
 Get/set if the default size for internal object pools (other than coroutine stacks). More...
 
static size_typedefaultCoroPoolAllocSize ()
 Get/set if the default size for coroutine stack pools. More...
 
static size_typepromiseAllocSize ()
 Get/set if the default size for promise object pools. More...
 
static size_typefutureAllocSize ()
 Get/set if the default size for future object pools. More...
 
static size_typecontextAllocSize ()
 Get/set if the default size for context object pools. More...
 
static size_typetaskAllocSize ()
 Get/set if the default size for task object pools. More...
 
static size_typeioTaskAllocSize ()
 Get/set if the default size for IO task object pools. More...
 
static size_typequeueListAllocSize ()
 Get/set if the default size for task queue pools. More...
 

Detailed Description

Allows application-wide settings for the various allocators used by Quantum.

Member Typedef Documentation

◆ size_type

Member Function Documentation

◆ allocatePoolFromHeap()

static bool& Bloomberg::quantum::AllocatorTraits::allocatePoolFromHeap ( )
inlinestatic

Get/set if the allocator pool for internal objects should use the heap or the application stack.

Returns
A modifiable reference to the value.
Remarks
For future use. If set to 'false', object pools will be allocated on the stack.

◆ contextAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::contextAllocSize ( )
inlinestatic

Get/set if the default size for context object pools.

Returns
A modifiable reference to the value.
Remarks
Normally this should not be modified unless very specific tuning is needed.

◆ defaultCoroPoolAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::defaultCoroPoolAllocSize ( )
inlinestatic

Get/set if the default size for coroutine stack pools.

Returns
A modifiable reference to the value.

◆ defaultPoolAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::defaultPoolAllocSize ( )
inlinestatic

Get/set if the default size for internal object pools (other than coroutine stacks).

Returns
A modifiable reference to the value.

◆ futureAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::futureAllocSize ( )
inlinestatic

Get/set if the default size for future object pools.

Returns
A modifiable reference to the value.
Remarks
Normally this should not be modified unless very specific tuning is needed.

◆ ioTaskAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::ioTaskAllocSize ( )
inlinestatic

Get/set if the default size for IO task object pools.

Returns
A modifiable reference to the value.
Remarks
Normally this should not be modified unless very specific tuning is needed.

◆ promiseAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::promiseAllocSize ( )
inlinestatic

Get/set if the default size for promise object pools.

Returns
A modifiable reference to the value.
Remarks
Normally this should not be modified unless very specific tuning is needed.

◆ queueListAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::queueListAllocSize ( )
inlinestatic

Get/set if the default size for task queue pools.

Returns
A modifiable reference to the value.
Remarks
Normally this should not be modified unless very specific tuning is needed.

◆ taskAllocSize()

static size_type& Bloomberg::quantum::AllocatorTraits::taskAllocSize ( )
inlinestatic

Get/set if the default size for task object pools.

Returns
A modifiable reference to the value.
Remarks
Normally this should not be modified unless very specific tuning is needed.

◆ useDefaultAllocator()

static bool& Bloomberg::quantum::AllocatorTraits::useDefaultAllocator ( )
inlinestatic

Get/set if the system allocator should be used for internal objects (other than coroutine stacks).

Returns
A modifiable reference to the value.
Remarks
For future use.

◆ useDefaultCoroAllocator()

static bool& Bloomberg::quantum::AllocatorTraits::useDefaultCoroAllocator ( )
inlinestatic

Get/set if the system allocator should be used for coroutine stacks.

Returns
A modifiable reference to the value.
Remarks
For future use.