lvropenmp.hpp
Go to the documentation of this file.
1 
28 #ifndef LVROPENMP
29 #define LVROPENMP
30 
31 namespace lvr2
32 {
33 
34 /***
35  * @brief Config class to get save access to information about OpenMP.
36  * Build to prevent trouble with OpenMP includes on compilers
37  * that do not support OpenMP
38  */
40 {
41 public:
42 
44  static bool haveOpenMP();
45 
47  static int getNumThreads();
48 
50  static void setNumThreads(int n);
51 
53  static void setMaxNumThreads();
54 };
55 
56 } // namespace lvr2
57 
58 #endif // LVROPENMP
static int getNumThreads()
Returns the number of supported threads (or 1 if OpenMP is not supported)
Definition: lvropenmp.cpp:70
static bool haveOpenMP()
True if OpenMP is supported.
Definition: lvropenmp.cpp:47
static void setMaxNumThreads()
Enables the maximum number of parallel threads.
Definition: lvropenmp.cpp:63
static void setNumThreads(int n)
Sets the number of used threads if OpenMP is used for parallelization.
Definition: lvropenmp.cpp:56


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Mon Feb 28 2022 22:46:08