Get or set the number of threads for OpenMP
omp_set_num_threads(num)omp_get_num_threads()
New number of threads for OpenMP
None
The number of threads for OpenMP
Some functions in mpMap2 are parallelised. Depending on the number of cores available, and the type of workload, it may be advantageous to turn parallelisation on or off, by setting the number of OpenMP threads appropriately. Setting the number of threads to 1 turns parallelisation off
In particular, for small examples on a computer with a large number of threads, parallelisation may result in a huge decrease in performance.
This function returns an error if the package was not compiled with OpenMP.