summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorRobert Maynard <robert.maynard@kitware.com>2020-12-07 04:16:44 -0500
committerTamara Dahlgren <dahlgren1@llnl.gov>2021-02-17 17:07:23 -0800
commit9499dc4a7ed5037d4ee87385b621ed3910ac3969 (patch)
tree2aff619ba1f8e596629e216275212c22942ab941 /var
parentecfba13d890e907e5fd2f0445404182e78bb48ee (diff)
downloadspack-9499dc4a7ed5037d4ee87385b621ed3910ac3969.tar.gz
spack-9499dc4a7ed5037d4ee87385b621ed3910ac3969.tar.bz2
spack-9499dc4a7ed5037d4ee87385b621ed3910ac3969.tar.xz
spack-9499dc4a7ed5037d4ee87385b621ed3910ac3969.zip
VTK-m: update to specify correct requirements to kokkos (#20097)
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/vtk-m/package.py18
1 files changed, 13 insertions, 5 deletions
diff --git a/var/spack/repos/builtin/packages/vtk-m/package.py b/var/spack/repos/builtin/packages/vtk-m/package.py
index 7516a87598..7c31160df7 100644
--- a/var/spack/repos/builtin/packages/vtk-m/package.py
+++ b/var/spack/repos/builtin/packages/vtk-m/package.py
@@ -55,12 +55,17 @@ class VtkM(CMakePackage, CudaPackage):
variant("tbb", default=(sys.platform == 'darwin'), description="build TBB support")
variant("hip", default=False, description="build hip support")
- # it doesn't look like spack has a amd gpu abstraction
+ # it doesn't look like spack has an amd gpu abstraction
+ # Going to have to restrict our set to ones that Kokkos supports
amdgpu_targets = (
- 'gfx701', 'gfx801', 'gfx802', 'gfx803',
- 'gfx900', 'gfx906', 'gfx908', 'gfx1010',
- 'gfx1011', 'gfx1012'
+ 'gfx900', 'gfx906', 'gfx908'
)
+ kokkos_amd_gpu_map = {
+ 'gfx900': 'vega900',
+ 'gfx906': 'vega906',
+ 'gfx908': 'vega908'
+ }
+
variant('amdgpu_target', default='none', multi=True, values=amdgpu_targets)
conflicts("+hip", when="amdgpu_target=none")
@@ -71,7 +76,9 @@ class VtkM(CMakePackage, CudaPackage):
depends_on("tbb", when="+tbb")
depends_on("mpi", when="+mpi")
- depends_on("kokkos@3.1:+hip", when="+hip")
+ for kokkos_value in kokkos_amd_gpu_map:
+ depends_on("kokkos@develop +hip amd_gpu_arch=%s" % kokkos_amd_gpu_map[kokkos_value], when="amdgpu_target=%s" % kokkos_value)
+
depends_on("rocm-cmake@3.7:", when="+hip")
depends_on("hip@3.7:", when="+hip")
@@ -160,6 +167,7 @@ class VtkM(CMakePackage, CudaPackage):
# hip support
if "+hip" in spec:
+ options.append("-DVTKm_NO_DEPRECATED_VIRTUAL:BOOL=ON")
options.append("-DVTKm_ENABLE_HIP:BOOL=ON")
archs = ",".join(self.spec.variants['amdgpu_target'].value)