ryujin 2.1.1 revision 04c248772b8df3a0cf47434aee70d95a0ae62bfc
Classes | Namespaces
openmp.h File Reference
#include <compile_time_options.h>
#include <deal.II/base/config.h>
#include <atomic>
#include <future>
Include dependency graph for openmp.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  ryujin::SynchronizationDispatch
 

Namespaces

namespace  ryujin
 

Macros

OpenMP parallel for macros

Intended use:

// serial work
// per thread work and thread-local storage declarations
for (unsigned int i = 0; i < size_internal; i += simd_length) {
// parallel for loop that is statically distributed on all available
// worker threads by slicing the interval [0,size_internal)
}
#define RYUJIN_PARALLEL_REGION_BEGIN
Definition: openmp.h:54
#define RYUJIN_OMP_FOR
Definition: openmp.h:70
#define RYUJIN_PARALLEL_REGION_END
Definition: openmp.h:63
#define RYUJIN_PRAGMA(x)   _Pragma(#x)
 
#define RYUJIN_PARALLEL_REGION_BEGIN
 
#define RYUJIN_PARALLEL_REGION_END   }
 
#define RYUJIN_OMP_FOR   RYUJIN_PRAGMA(omp for)
 
#define RYUJIN_OMP_FOR_NOWAIT   RYUJIN_PRAGMA(omp for nowait)
 
#define RYUJIN_OMP_BARRIER   RYUJIN_PRAGMA(omp barrier)
 
#define RYUJIN_OMP_CRITICAL   RYUJIN_PRAGMA(omp critical)
 
#define RYUJIN_OMP_SINGLE   RYUJIN_PRAGMA(omp single)
 
#define RYUJIN_LIKELY(x)   (__builtin_expect(!!(x), 1))
 
#define RYUJIN_UNLIKELY(x)   (__builtin_expect(!!(x), 0))