|
20 | 20 |
|
21 | 21 | // Include the minimal set of headers that declare all TPL singletons |
22 | 22 | #ifdef KOKKOSKERNELS_ENABLE_COMPONENT_BLAS |
23 | | -#include "KokkosBlas_tpl_spec.hpp" //cuBLAS, rocBLAS |
| 23 | +#include "KokkosBlas_tpl_spec.hpp" //cuBLAS, rocBLAS |
24 | 24 | #ifdef KOKKOSKERNELS_ENABLE_TPL_MAGMA |
25 | 25 | #include "KokkosBlas_Magma_tpl.hpp" |
26 | 26 | #endif |
27 | 27 | #endif |
28 | 28 |
|
29 | 29 | #ifdef KOKKOSKERNELS_ENABLE_COMPONENT_SPARSE |
30 | | -//note: this file declares both cuSPARSE and rocSPARSE singletons |
| 30 | +// note: this file declares both cuSPARSE and rocSPARSE singletons |
31 | 31 | #include "KokkosKernels_tpl_handles_decl.hpp" |
32 | 32 | #endif |
33 | 33 |
|
|
40 | 40 | #endif |
41 | 41 | #endif |
42 | 42 |
|
43 | | -namespace KokkosKernels |
44 | | -{ |
45 | | - void eager_initialize() |
46 | | - { |
47 | | - if(!Kokkos::is_initialized()) |
48 | | - { |
49 | | - throw std::runtime_error("Kokkos::intialize must be called before KokkosKernels::eager_initialize"); |
50 | | - } |
| 43 | +namespace KokkosKernels { |
| 44 | +void eager_initialize() { |
| 45 | + if (!Kokkos::is_initialized()) { |
| 46 | + throw std::runtime_error("Kokkos::intialize must be called before KokkosKernels::eager_initialize"); |
| 47 | + } |
51 | 48 | #ifdef KOKKOSKERNELS_ENABLE_COMPONENT_BLAS |
52 | 49 | #ifdef KOKKOSKERNELS_ENABLE_TPL_CUBLAS |
53 | | - (void) KokkosBlas::Impl::CudaBlasSingleton::singleton(); |
| 50 | + (void)KokkosBlas::Impl::CudaBlasSingleton::singleton(); |
54 | 51 | #endif |
55 | 52 | #ifdef KOKKOSKERNELS_ENABLE_TPL_ROCBLAS |
56 | | - (void) KokkosBlas::Impl::RocBlasSingleton::singleton(); |
| 53 | + (void)KokkosBlas::Impl::RocBlasSingleton::singleton(); |
57 | 54 | #endif |
58 | 55 | #ifdef KOKKOSKERNELS_ENABLE_TPL_MAGMA |
59 | 56 | #include "KokkosBlas_Magma_tpl.hpp" |
60 | | - (void) KokkosBlas::Impl::MagmaSingleton::singleton(); |
| 57 | + (void)KokkosBlas::Impl::MagmaSingleton::singleton(); |
61 | 58 | #endif |
62 | 59 | #endif |
63 | 60 |
|
64 | 61 | #ifdef KOKKOSKERNELS_ENABLE_COMPONENT_SPARSE |
65 | 62 | #ifdef KOKKOSKERNELS_ENABLE_TPL_CUSPARSE |
66 | | - (void) KokkosKernels::Impl::CusparseSingleton::singleton(); |
| 63 | + (void)KokkosKernels::Impl::CusparseSingleton::singleton(); |
67 | 64 | #endif |
68 | 65 | #ifdef KOKKOSKERNELS_ENABLE_TPL_ROCSPARSE |
69 | | - (void) KokkosKernels::Impl::RocsparseSingleton::singleton(); |
| 66 | + (void)KokkosKernels::Impl::RocsparseSingleton::singleton(); |
70 | 67 | #endif |
71 | 68 | #endif |
72 | 69 |
|
73 | 70 | #ifdef KOKKOSKERNELS_ENABLE_COMPONENT_LAPACK |
74 | 71 | #ifdef KOKKOSKERNELS_ENABLE_TPL_CUSOLVER |
75 | | - (void) KokkosLapack::Impl::CudaLapackSingleton::singleton(); |
| 72 | + (void)KokkosLapack::Impl::CudaLapackSingleton::singleton(); |
76 | 73 | #endif |
77 | 74 | #ifdef KOKKOSKERNELS_ENABLE_TPL_MAGMA |
78 | | - (void) KokkosLapack::Impl::MagmaSingleton::singleton(); |
| 75 | + (void)KokkosLapack::Impl::MagmaSingleton::singleton(); |
79 | 76 | #endif |
80 | 77 | #endif |
81 | | - } |
82 | 78 | } |
83 | | - |
| 79 | +} // namespace KokkosKernels |
0 commit comments