Skip to content

Commit b61e80e

Browse files
ndellingwoodeeprude
authored andcommitted
zoltan2: update ArithTraits namespace for KOKKOS_VERSION > 40799
Compatibility update corresponding to kokkos/kokkos-kernels#2771 Signed-off-by: Nathan Ellingwood <ndellin@sandia.gov>
1 parent 9cc1e43 commit b61e80e

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

packages/zoltan2/sphynx/src/Zoltan2_Sphynx.hpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,11 @@ namespace Zoltan2 {
425425
using offset_view_t = Kokkos::View<size_t*, typename node_t::device_type>;
426426
using vector_t = Tpetra::Vector<scalar_t, lno_t, gno_t, node_t>;
427427
using dual_view_t = typename vector_t::dual_view_type;
428+
#if KOKKOS_VERSION > 40799
429+
using KAT = KokkosKernels::ArithTraits<scalar_t>;
430+
#else
428431
using KAT = Kokkos::ArithTraits<scalar_t>;
432+
#endif
429433

430434
const size_t numEnt = graph_->getLocalNumEntries();
431435
const size_t numRows = graph_->getLocalNumRows();

packages/zoltan2/test/core/TpetraCrsColorer/Bug9500.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,11 @@ class ColorerTest {
5757
JBlock->fillComplete();
5858

5959
// Fill JBlock with random numbers for a better test.
60+
#if KOKKOS_VERSION > 40799
61+
using IST = typename KokkosKernels::ArithTraits<zscalar_t>::val_type;
62+
#else
6063
using IST = typename Kokkos::ArithTraits<zscalar_t>::val_type;
64+
#endif
6165
using pool_type =
6266
Kokkos::Random_XorShift64_Pool<execution_space_t>;
6367
pool_type rand_pool(static_cast<uint64_t>(me));

packages/zoltan2/test/core/TpetraCrsColorer/TpetraCrsColorer.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,11 @@ class ColorerTest {
8282
// Fill JBlock with random numbers for a better test.
8383
JBlock->resumeFill();
8484

85+
#if KOKKOS_VERSION > 40799
86+
using IST = typename KokkosKernels::ArithTraits<zscalar_t>::val_type;
87+
#else
8588
using IST = typename Kokkos::ArithTraits<zscalar_t>::val_type;
89+
#endif
8690
using pool_type =
8791
Kokkos::Random_XorShift64_Pool<execution_space_t>;
8892
pool_type rand_pool(static_cast<uint64_t>(me));

0 commit comments

Comments
 (0)