ThreadSchedule 3.0.0
Modern C++ thread management library
Loading...
Searching...
No Matches
work_stealing_pool.hpp
Go to the documentation of this file.
1#pragma once
2
3#include "../detail/pool/backend.hpp"
4#include "../detail/pool/facade.hpp"
5
7{
37} // namespace threadschedule::advanced
work_stealing_pool(worker_count count=worker_count::automatic(), worker_registration registration=worker_registration::disabled)
auto submit_batch_or_throw(Iterator begin, Iterator end) -> std::vector< std::future< void > >
auto submit_or_throw(F &&function, Args &&... args) -> std::future< bind_result_t< F, Args... > >
auto submit(F &&function, Args &&... args) -> result< std::future< bind_result_t< F, Args... > > >
auto submit_batch(Iterator begin, Iterator end) -> result< std::vector< std::future< void > > >
auto parallel_for_each(Iterator begin, Iterator end, Function &&function) -> result< void >
auto shutdown(shutdown_policy policy=shutdown_policy::drain) -> result< void >
Value type for pool worker count.
static constexpr auto automatic() noexcept -> worker_count
Create automatic worker count.
worker_registration
Controls whether pool workers are registered in a thread registry.
@ disabled
Do not register workers in the global registry.