Monado OpenXR Runtime
xrt::auxiliary::util::SharedThreadPool Class Reference

Wrapper around u_worker_thread_pool. More...

#include <util/u_worker.hpp>

Collaboration diagram for xrt::auxiliary::util::SharedThreadPool:

Public Member Functions

 SharedThreadPool (SharedThreadPool const &copy)
 
 SharedThreadPool (u_worker_thread_pool *uwtp)
 Take a C thread pool as argument in case the pool is shared between different C++ components over C interfaces, or created externally. More...
 
 SharedThreadPool (uint32_t starting_worker_count, uint32_t thread_count, const char *prefix)
 Creates a new thread pool to be used by a worker group. More...
 
SharedThreadPooloperator= (const SharedThreadPool &other)
 
 SharedThreadPool (SharedThreadPool &&)=delete
 
SharedThreadPooloperator= (SharedThreadPool &&)=delete
 

Data Fields

friend SharedThreadGroup
 

Detailed Description

Wrapper around u_worker_thread_pool.

Constructor & Destructor Documentation

◆ SharedThreadPool() [1/2]

xrt::auxiliary::util::SharedThreadPool::SharedThreadPool ( u_worker_thread_pool uwtp)
inlineexplicit

Take a C thread pool as argument in case the pool is shared between different C++ components over C interfaces, or created externally.

References u_worker_thread_pool_reference().

◆ SharedThreadPool() [2/2]

xrt::auxiliary::util::SharedThreadPool::SharedThreadPool ( uint32_t  starting_worker_count,
uint32_t  thread_count,
const char *  prefix 
)
inline

Creates a new thread pool to be used by a worker group.

Parameters
starting_worker_countHow many worker threads can be active at the same time without any "donated" threads.
thread_countThe number of threads to be created in total, this is the maximum threads that can be in flight at the same time.
prefixPrefix to used when naming threads, used for tracing and debugging.

References u_worker_thread_pool_create().


The documentation for this class was generated from the following file: