From: Daniel Arndt Date: Wed, 24 Jan 2024 20:28:59 +0000 (-0500) Subject: Kokkos+Cuda: enforce expt-relaxed-constexpr X-Git-Tag: relicensing~110^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8bf2049f750a4e19056f994dbea001ca4f1f3ef4;p=dealii.git Kokkos+Cuda: enforce expt-relaxed-constexpr --- diff --git a/cmake/modules/FindDEAL_II_KOKKOS.cmake b/cmake/modules/FindDEAL_II_KOKKOS.cmake index e39e93ea26..a750fd820c 100644 --- a/cmake/modules/FindDEAL_II_KOKKOS.cmake +++ b/cmake/modules/FindDEAL_II_KOKKOS.cmake @@ -48,8 +48,10 @@ else() # we don't know if CUDA support is enabled in Kokkos if(Kokkos_ENABLE_CUDA) set(DEAL_II_VECTORIZATION_WIDTH_IN_BITS 0) - # Require lambda support to use Kokkos as a backend - KOKKOS_CHECK(OPTIONS CUDA_LAMBDA) + # Require lambda support and expt-relaxed-constexpr for Cuda + # so that we can use std::array and other interfaces with + # __host__ constexpr functions in device code + KOKKOS_CHECK(OPTIONS CUDA_LAMBDA CUDA_CONSTEXPR) # Disable a bunch of annoying warnings generated by boost, template code, # and in other random places: