42 #ifndef TPETRA_DETAILS_DEFAULTTYPES_HPP
43 #define TPETRA_DETAILS_DEFAULTTYPES_HPP
45 #include "TpetraCore_config.h"
46 #include "KokkosClassic_DefaultNode_config.h"
47 #include "KokkosCompat_ClassicNodeAPI_Wrapper.hpp"
61 namespace DefaultTypes {
63 #if defined(HAVE_TPETRA_INST_DOUBLE)
64 typedef double scalar_type;
65 #elif defined(HAVE_TPETRA_INST_FLOAT)
66 typedef float scalar_type;
68 # error "Tpetra: No scalar types in the set {float, double} have been enabled."
76 #if defined(TPETRA_ENABLE_DEPRECATED_CODE)
77 #if defined(HAVE_TPETRA_INST_INT_INT)
78 typedef int global_ordinal_type;
79 #elif defined(HAVE_TPETRA_INST_INT_LONG_LONG)
80 typedef long long global_ordinal_type;
81 #elif defined(HAVE_TPETRA_INST_INT_LONG)
82 typedef long global_ordinal_type;
83 #elif defined(HAVE_TPETRA_INST_INT_UNSIGNED_LONG)
84 typedef unsigned long global_ordinal_type;
85 #elif defined(HAVE_TPETRA_INST_INT_UNSIGNED)
86 typedef unsigned global_ordinal_type;
88 #error "Tpetra: No global ordinal types in the set {int, long long, long, unsigned long, unsigned} have been enabled."
90 #else // TPETRA_ENABLE_DEPRECATED_CODE IS NOT DEFINED
91 #if defined(HAVE_TPETRA_INST_INT_LONG_LONG)
92 typedef long long global_ordinal_type;
93 #elif defined(HAVE_TPETRA_INST_INT_INT)
94 typedef int global_ordinal_type;
95 #elif defined(HAVE_TPETRA_INST_INT_LONG)
96 typedef long global_ordinal_type;
97 #elif defined(HAVE_TPETRA_INST_INT_UNSIGNED_LONG)
98 typedef unsigned long global_ordinal_type;
99 #elif defined(HAVE_TPETRA_INST_INT_UNSIGNED)
100 typedef unsigned global_ordinal_type;
102 #error "Tpetra: No global ordinal types in the set {int, long long, long, unsigned long, unsigned} have been enabled."
109 #if defined(HAVE_TPETRA_DEFAULTNODE_CUDAWRAPPERNODE)
110 using execution_space = ::Kokkos::Cuda;
111 #elif defined(HAVE_TPETRA_DEFAULTNODE_OPENMPWRAPPERNODE)
112 using execution_space = ::Kokkos::OpenMP;
113 #elif defined(HAVE_TPETRA_DEFAULTNODE_THREADSWRAPPERNODE)
114 using execution_space = ::Kokkos::Threads;
115 #elif defined(HAVE_TPETRA_DEFAULTNODE_SERIALWRAPPERNODE)
116 using execution_space = ::Kokkos::Serial;
118 # error "No default Tpetra Node type specified. Please set the CMake option Tpetra_DefaultNode to a valid Node type."
122 using node_type = ::Kokkos::Compat::KokkosDeviceWrapperNode<execution_space>;
129 #endif // TPETRA_DETAILS_DEFAULTTYPES_HPP
int local_ordinal_type
Default value of Scalar template parameter.
::Kokkos::Compat::KokkosDeviceWrapperNode< execution_space > node_type
Default value of Node template parameter.