RAJA
RAJA provides a collection of platform portability abstractions for C++ HPC applications.
synchronize.hpp
Go to the documentation of this file.
1 
11 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
12 // Copyright (c) Lawrence Livermore National Security, LLC and other
13 // RAJA Project Developers. See top-level LICENSE and COPYRIGHT
14 // files for dates and other details. No copyright assignment is required
15 // to contribute to RAJA.
16 //
17 // SPDX-License-Identifier: (BSD-3-Clause)
18 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
19 
20 #ifndef RAJA_synchronize_cuda_HPP
21 #define RAJA_synchronize_cuda_HPP
22 
23 #include "RAJA/config.hpp"
24 
25 #if defined(RAJA_ENABLE_CUDA)
26 
28 
29 namespace RAJA
30 {
31 
32 namespace policy
33 {
34 
35 namespace cuda
36 {
37 
41 RAJA_INLINE
42 void synchronize_impl(const cuda_synchronize&)
43 {
44  CAMP_CUDA_API_INVOKE_AND_CHECK(cudaDeviceSynchronize);
45 }
46 
47 
48 } // end of namespace cuda
49 } // namespace policy
50 } // end of namespace RAJA
51 
52 #endif // defined(RAJA_ENABLE_CUDA)
53 
54 #endif // RAJA_synchronize_cuda_HPP
RAJA_INLINE void synchronize_impl(const omp_synchronize &)
Synchronize all OpenMP threads and tasks.
Definition: synchronize.hpp:36
Definition: AlignedRangeIndexSetBuilders.cpp:35
Header file containing utility methods used in CUDA operations.