Files | |
file | condition_variable.hh |
file | forward_parallel_for_each.hh |
file | thread.hh |
file | thread_pool.hh |
Namespaces | |
namespace | paludis |
Classes | |
class | paludis::ActionQueue |
class | paludis::ConditionVariable |
class | paludis::Mutex |
class | paludis::Lock |
class | paludis::TryLock |
class | paludis::Thread |
class | paludis::ThreadPool |
Functions | |
template<typename Iter_, typename Func_> | |
void | paludis::forward_parallel_for_each_thread_func (Iter_ &cur, const Iter_ &end, Mutex &mutex, Func_ &func, unsigned n_at_once) |
template<typename Iter_, typename Func_> | |
void | paludis::forward_parallel_for_each (Iter_ cur, const Iter_ &end, Func_ func, unsigned n_threads, unsigned n_at_once) |
void paludis::forward_parallel_for_each | ( | Iter_ | cur, | |
const Iter_ & | end, | |||
Func_ | func, | |||
unsigned | n_threads, | |||
unsigned | n_at_once | |||
) | [inline] |
Like std::for_each, but in parallel, and no return value.
This works for forward iterators, but is only effective if each calculation is quite slow.
void paludis::forward_parallel_for_each_thread_func | ( | Iter_ & | cur, | |
const Iter_ & | end, | |||
Mutex & | mutex, | |||
Func_ & | func, | |||
unsigned | n_at_once | |||
) | [inline] |