proxsuite 0.6.7
The Advanced Proximal Optimization Toolbox
Loading...
Searching...
No Matches
omp.hpp
Go to the documentation of this file.
1//
2// Copyright (c) 2023 INRIA
3//
4
5#ifndef PROXSUITE_PROXQP_PARALLEL_OMP_HPP
6#define PROXSUITE_PROXQP_PARALLEL_OMP_HPP
7
8#include <omp.h>
9
10namespace proxsuite {
11inline void
12set_default_omp_options(const size_t num_threads = (size_t)
13 omp_get_max_threads())
14{
15 omp_set_num_threads((int)num_threads);
16 omp_set_dynamic(0);
17}
18}
19
20#endif // ifndef PROXSUITE_PROXQP_PARALLEL_OMP_HPP
void set_default_omp_options(const size_t num_threads=(size_t) omp_get_max_threads())
Definition omp.hpp:12