OpenMP parallel execution policy.
More...
#include <parallel_execution_omp.h>
OpenMP parallel execution policy.
This policy uses OpenMP as implementation back-end.
grppi::parallel_execution_omp::parallel_execution_omp |
( |
| ) |
|
|
inlinenoexcept |
Default construct an OpenMP parallel execution policy.
Creates an OpenMP parallel execution object.
The concurrency degree is determined by the platform according to OpenMP rules.
grppi::parallel_execution_omp::parallel_execution_omp |
( |
int |
concurrency_degree, |
|
|
bool |
order = true |
|
) |
| |
|
inlinenoexcept |
Set num_threads to _threads in order to run in parallel.
- Parameters
-
_threads | number of threads used in the parallel mode Constructs an OpenMP parallel execution policy. |
Creates an OpenMP parallel execution object selecting the concurrency degree and ordering.
- Parameters
-
concurrency_degree | Number of threads used for parallel algorithms. |
order | Whether ordered executions is enabled or disabled. |
int grppi::parallel_execution_omp::concurrency_degree |
( |
| ) |
const |
|
inlinenoexcept |
Get number of grppi trheads.
void grppi::parallel_execution_omp::disable_ordering |
( |
| ) |
|
|
inlinenoexcept |
void grppi::parallel_execution_omp::enable_ordering |
( |
| ) |
|
|
inlinenoexcept |
int grppi::parallel_execution_omp::get_thread_id |
( |
| ) |
const |
|
inlinenoexcept |
Get index of current thread in the thread table.
bool grppi::parallel_execution_omp::is_ordered |
( |
| ) |
const |
|
inlinenoexcept |
template<typename T >
mpmc_queue<T> grppi::parallel_execution_omp::make_queue |
( |
| ) |
const |
|
inline |
Makes a communication queue for elements of type T.
Constructs a queue using the attributes that can be set via set_queue_attributes(). The value is returned via move semantics.
void grppi::parallel_execution_omp::set_concurrency_degree |
( |
int |
degree | ) |
|
|
inlinenoexcept |
Set number of grppi threads.
void grppi::parallel_execution_omp::set_queue_attributes |
( |
int |
size, |
|
|
queue_mode |
mode |
|
) |
| |
|
inlinenoexcept |
Sets the attributes for the queues built through make_queue<T>(()
The documentation for this class was generated from the following file: