Btk
Btk::ThreadPool Struct Reference
Collaboration diagram for Btk::ThreadPool:

Public Member Functions

void run ()
 
void add_worker ()
 
void add_task (Task)
 
bool tryadd_task (Task)
 

Public Attributes

std::list< Workerworkers_list
 
std::queue< Tasktasks_queue
 
std::condition_variable condvar
 
SpinLock tasks_mtx
 
Atomic idle_workers = 0
 
Atomic cur_workers = 1
 
Atomic max_workers = 4
 
std::mutex workers_mtx
 

Static Public Attributes

static ThreadPoolinstance = nullptr
 

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