RAJA
RAJA provides a collection of platform portability abstractions for C++ HPC applications.
ThreadUtils_CPU.hpp
Go to the documentation of this file.
1 
12 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
13 // Copyright (c) Lawrence Livermore National Security, LLC and other
14 // RAJA Project Developers. See top-level LICENSE and COPYRIGHT
15 // files for dates and other details. No copyright assignment is required
16 // to contribute to RAJA.
17 //
18 // SPDX-License-Identifier: (BSD-3-Clause)
19 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
20 
21 #ifndef RAJA_ThreadUtils_CPU_HPP
22 #define RAJA_ThreadUtils_CPU_HPP
23 
24 #include "RAJA/config.hpp"
25 
26 #include "RAJA/pattern/thread.hpp"
27 #if defined(RAJA_ENABLE_OPENMP)
29 #endif
31 
32 namespace RAJA
33 {
34 
42 template<typename ThreadPolicy = RAJA::detail::active_auto_thread>
43 RAJA_INLINE int getMaxOMPThreadsCPU()
44 {
45  return RAJA::get_max_threads<ThreadPolicy>();
46 }
47 
48 } // namespace RAJA
49 
50 #endif // closing endif for header file include guard
Definition: AlignedRangeIndexSetBuilders.cpp:35
RAJA_INLINE int getMaxOMPThreadsCPU()
Definition: ThreadUtils_CPU.hpp:43
RAJA header file defining thread operations.
RAJA header file defining OpenMP thread operations.
RAJA header file defining sequential thread operations.