Blocks :
|
|
Blocks :
|
|
Blocks :
|
|
Blocks :
|
|
Blocks :
|
|
Duplicate :
|
|
Relates :
|
In many cases more direct control about the number of threads for a given task is required. The current way of doing so is quite involved, requiring a few lines of code where every part is important. Like: size_t new_active_threads = ... size_t old_active_threads = gang->num_active_threads(); gang->set_active_threads(new_active_threads); gang->run_task(...); gang->set_active_threads(old_active_threads); The proposal is to add a method that allows you to set the number of threads to use for the given task directly.