LLVM 20.0.0git
|
A group of tasks to be run on a thread pool. More...
#include "llvm/Support/ThreadPool.h"
Public Member Functions | |
ThreadPoolTaskGroup (ThreadPoolInterface &Pool) | |
The ThreadPool argument is the thread pool to forward calls to. | |
~ThreadPoolTaskGroup () | |
Blocking destructor: will wait for all the tasks in the group to complete by calling ThreadPool::wait(). | |
template<typename Function , typename... Args> | |
auto | async (Function &&F, Args &&...ArgList) |
Calls ThreadPool::async() for this group. | |
void | wait () |
Calls ThreadPool::wait() for this group. | |
A group of tasks to be run on a thread pool.
Thread pool tasks in different groups can run on the same threadpool but can be waited for separately. It is even possible for tasks of one group to submit and wait for tasks of another group, as long as this does not form a loop.
Definition at line 264 of file ThreadPool.h.
|
inline |
The ThreadPool argument is the thread pool to forward calls to.
Definition at line 267 of file ThreadPool.h.
|
inline |
Blocking destructor: will wait for all the tasks in the group to complete by calling ThreadPool::wait().
Definition at line 271 of file ThreadPool.h.
References wait().
|
inline |
Calls ThreadPool::async() for this group.
Definition at line 275 of file ThreadPool.h.
References llvm::ThreadPoolInterface::async(), and F.
|
inline |
Calls ThreadPool::wait() for this group.
Definition at line 281 of file ThreadPool.h.
References llvm::ThreadPoolInterface::wait().
Referenced by ~ThreadPoolTaskGroup().