Skip to content
Snippets Groups Projects
Unverified Commit 45de1ab3 authored by boeschf's avatar boeschf Committed by GitHub
Browse files

spack gpu option (#2043)

added conditional variant for cuda builds to enable GPU-based random number generation
parent 9797403e
No related branches found
No related tags found
No related merge requests found
......@@ -56,6 +56,12 @@ class Arbor(CMakePackage, CudaPackage):
default=False,
description="Enable vectorization of computational kernels",
)
variant(
"gpu_rng",
default=False,
description="Use GPU generated random numbers -- not bitwise equal to CPU version",
when="+cuda",
)
# https://docs.arbor-sim.org/en/latest/install/build_install.html#compilers
conflicts("%gcc@:8")
......@@ -109,6 +115,7 @@ class Arbor(CMakePackage, CudaPackage):
if "+cuda" in self.spec:
args.append("-DARB_GPU=cuda")
args.append(self.define_from_variant("ARB_USE_GPU_RNG", "gpu_rng"))
# query spack for the architecture-specific compiler flags set by its wrapper
args.append("-DARB_ARCH=none")
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment