QuantumLibrary
Bloomberg::quantum::ThreadTraits Struct Reference

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

#include <quantum_thread_traits.h>

Static Public Member Functions

static std::chrono::milliseconds & yieldSleepIntervalMs ()
 Dictates how long any thread should sleep on blocking calls when interacting with coroutines (e.g. mutexes, condition variables, etc). More...
 
static std::chrono::microseconds & yieldSleepIntervalUs ()
 

Detailed Description

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

Member Function Documentation

◆ yieldSleepIntervalMs()

static std::chrono::milliseconds& Bloomberg::quantum::ThreadTraits::yieldSleepIntervalMs ( )
inlinestatic

Dictates how long any thread should sleep on blocking calls when interacting with coroutines (e.g. mutexes, condition variables, etc).

Returns
The modifiable sleep interval in microseconds.
Note
: When set to 0, threads will yield() instead of sleeping which results in increased performance at the detriment of higher CPU load. Default is 0ms.

◆ yieldSleepIntervalUs()

static std::chrono::microseconds& Bloomberg::quantum::ThreadTraits::yieldSleepIntervalUs ( )
inlinestatic