Sacado Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Fad_KokkosAtomicTests_HIP.cpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Sacado Package
4 //
5 // Copyright 2006 NTESS and the Sacado contributors.
6 // SPDX-License-Identifier: LGPL-2.1-or-later
7 // *****************************************************************************
8 // @HEADER
9 
13 
14 #include "Kokkos_Macros.hpp"
15 
16 // Temporarily disable DFad testing on HIP. HIP does not support "new"
17 // on device so temporary allocations don't work.
18 #ifdef KOKKOS_ENABLE_HIP
19 #define SACADO_TEST_DFAD 0
20 #else
21 #define SACADO_TEST_DFAD 1
22 #endif
23 
25 
26 // Instantiate tests for HIP device.
27 using Kokkos::HIP;
28 VIEW_FAD_TESTS_D( HIP )
29 
30 int main( int argc, char* argv[] ) {
31  Teuchos::GlobalMPISession mpiSession(&argc, &argv);
32 
33  // Initialize HIP
34  Kokkos::InitializationSettings init_args;
35  init_args.set_device_id(0);
36  Kokkos::initialize( init_args );
37  Kokkos::print_configuration(std::cout);
38 
40 
41  // Finalize HIP
42  Kokkos::finalize();
43 
44  return res;
45 }
static int runUnitTestsFromMain(int argc, char *argv[])
int main()
Definition: ad_example.cpp:171
#define VIEW_FAD_TESTS_D(D)