diff options
-rw-r--r-- | var/spack/repos/builtin/packages/exago/package.py | 40 | ||||
-rw-r--r-- | var/spack/repos/builtin/packages/hiop/package.py | 31 |
2 files changed, 43 insertions, 28 deletions
diff --git a/var/spack/repos/builtin/packages/exago/package.py b/var/spack/repos/builtin/packages/exago/package.py index 0e040e7f43..918379faee 100644 --- a/var/spack/repos/builtin/packages/exago/package.py +++ b/var/spack/repos/builtin/packages/exago/package.py @@ -15,6 +15,7 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): git = "https://gitlab.pnnl.gov/exasgd/frameworks/exago.git" maintainers("ryandanehy", "CameronRutherford", "pelesh") + version("1.5.1", commit="7abe482c8da0e247f9de4896f5982c4cacbecd78", submodules=True) version("1.5.0", commit="227f49573a28bdd234be5500b3733be78a958f15", submodules=True) version("1.4.1", commit="ea607c685444b5f345bfdc9a59c345f0f30adde2", submodules=True) version("1.4.0", commit="4f4c3fdb40b52ace2d6ba000e7f24b340ec8e886", submodules=True) @@ -33,8 +34,8 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): # Progrmming model options variant("mpi", default=True, description="Enable/Disable MPI") variant("raja", default=False, description="Enable/Disable RAJA") - variant("python", default=True, description="Enable/Disable Python bindings") - conflicts("+python", when="@:1.3.0", msg="Python bindings require ExaGO 1.4") + variant("python", default=True, when="@1.4:", description="Enable/Disable Python bindings") + variant("logging", default=True, description="Enable/Disable spdlog based logging") conflicts( "+python", when="+ipopt+rocm", msg="Python bindings require -fPIC with Ipopt for rocm." ) @@ -47,13 +48,14 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): "~hiop~ipopt @:1.4", msg="ExaGO needs at least one solver enabled. PFLOW only mode is supported in 1.5+", ) - # We will better support minimal builds with Python in future. # You can use Python with PFLOW if desired ~ipopt~hiop conflicts( - "~hiop~ipopt+python", msg="ExaGO Python wrapper requires at least one solver enabled." + "~hiop~ipopt+python @:1.5.0", + msg="ExaGO Python wrapper requires at least one solver enabled.", ) # Dependencies + depends_on("python@3.6:", when="@1.3.0:+python") depends_on("py-pytest", type=("build", "run"), when="@1.5.0:+python") depends_on("py-mpi4py", when="@1.3.0:+mpi+python") depends_on("pkgconfig", type="build") @@ -64,13 +66,6 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): depends_on("raja", when="+raja") depends_on("umpire", when="+raja") - depends_on("umpire@6.0.0", when="@1.1.0: +raja") - depends_on("raja@0.14.0", when="@1.1.0: +raja") - depends_on("camp@0.2.3", when="@1.1.0: +raja") - - # Some allocator code in Umpire only works with static libs - depends_on("umpire+cuda~shared", when="+raja+cuda") - depends_on("cmake@3.18:", type="build") # Profiling @@ -108,15 +103,26 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): # ^ need to depend when both hpctoolkit and tau # HiOp dependency logic - depends_on("hiop+raja", when="+hiop+raja") depends_on("hiop@0.3.99:", when="@0.99:+hiop") depends_on("hiop@0.5.1:", when="@1.1.0:+hiop") depends_on("hiop@0.5.3:", when="@1.3.0:+hiop") - depends_on("hiop@0.7.0:0.7.1", when="@1.5.0:+hiop") + depends_on("hiop@0.7.0:", when="@1.5.0:+hiop") depends_on("hiop~mpi", when="+hiop~mpi") depends_on("hiop+mpi", when="+hiop+mpi") + # RAJA dependency logic + # ExaGO will support +raja~hiop in the future + depends_on("hiop+raja", when="+hiop+raja") + # This is duplicated from HiOp + # RAJA > 0.14 and Umpire > 6.0 require c++ std 14 + # We are working on supporting newer Umpire/RAJA versions + depends_on("raja@0.14.0:0.14", when="@1.1.0:+raja") + depends_on("umpire@6.0.0:6", when="@1.1.0:+raja") + depends_on("camp@0.2.3:0.2", when="@1.1.0:+raja") + # This is no longer a requirement in RAJA > 0.14 + depends_on("umpire+cuda~shared", when="+raja+cuda ^raja@:0.14") + depends_on("petsc@3.13:3.14", when="@:1.2.99") depends_on("petsc@3.16.0:3.16", when="@1.3.0:1.4") depends_on("petsc@3.18.0:3.18", when="@1.5.0:") @@ -127,16 +133,15 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): cuda_dep = "+cuda cuda_arch={0}".format(arch) depends_on("hiop {0}".format(cuda_dep), when=cuda_dep) depends_on("raja {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) - - # For some versions of RAJA package, camp cuda variant does not get set - # correctly, so we must explicitly depend on it even though we don't use - # camp + depends_on("umpire {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) depends_on("camp {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) for arch in ROCmPackage.amdgpu_targets: rocm_dep = "+rocm amdgpu_target={0}".format(arch) depends_on("hiop {0}".format(rocm_dep), when=rocm_dep) depends_on("raja {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) + depends_on("umpire {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) + depends_on("camp {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) flag_handler = build_system_flags @@ -173,6 +178,7 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): self.define_from_variant("EXAGO_ENABLE_HIOP", "hiop"), self.define_from_variant("EXAGO_ENABLE_IPOPT", "ipopt"), self.define_from_variant("EXAGO_ENABLE_PYTHON", "python"), + self.define_from_variant("EXAGO_ENABLE_LOGGING", "logging"), ] ) diff --git a/var/spack/repos/builtin/packages/hiop/package.py b/var/spack/repos/builtin/packages/hiop/package.py index 9e2d45629e..543ff25009 100644 --- a/var/spack/repos/builtin/packages/hiop/package.py +++ b/var/spack/repos/builtin/packages/hiop/package.py @@ -80,14 +80,18 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): depends_on("magma {0}".format(cuda_dep), when=cuda_dep) depends_on("raja {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) depends_on("ginkgo {0}".format(cuda_dep), when="+ginkgo {0}".format(cuda_dep)) - depends_on("umpire ~shared {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) + depends_on("umpire {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) + # Camp GPU arch doesn't get propogated correctly + depends_on("camp {0}".format(cuda_dep), when="+raja {0}".format(cuda_dep)) for arch in ROCmPackage.amdgpu_targets: rocm_dep = "+rocm amdgpu_target={0}".format(arch) depends_on("magma {0}".format(rocm_dep), when=rocm_dep) depends_on("raja {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) - depends_on("umpire {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) depends_on("ginkgo {0}".format(rocm_dep), when="+ginkgo {0}".format(rocm_dep)) + depends_on("umpire {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) + # Camp GPU arch doesn't get propogated correctly + depends_on("camp {0}".format(rocm_dep), when="+raja {0}".format(rocm_dep)) magma_ver_constraints = (("2.5.4", "0.4"), ("2.6.1", "0.4.6"), ("2.6.2", "0.5.4")) @@ -101,9 +105,20 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): depends_on("umpire", when="+raja") depends_on("raja+openmp", when="+raja~cuda~rocm") - # Umpire > 0.14 and RAJA > 6.0 require c++ std 14 - depends_on("raja@0.14.0:0.14", when="@0.5.0:0.6.2+raja") - depends_on("umpire@6.0.0:", when="@0.5.0:0.6.2+raja") + # RAJA > 0.14 and Umpire > 6.0 require c++ std 14 + # We are working on supporting newer Umpire/RAJA versions + depends_on("raja@0.14.0:0.14", when="@0.5.0:+raja") + depends_on("umpire@6.0.0:6", when="@0.5.0:+raja") + depends_on("camp@0.2.3:0.2", when="@0.5.0:+raja") + + # This is no longer a requirement in RAJA > 0.14 + depends_on("umpire+cuda~shared", when="+raja+cuda ^raja@:0.14") + + conflicts( + "+shared", + when="+cuda+raja ^raja@:0.14", + msg="umpire+cuda exports device code and requires static libs", + ) depends_on("hip", when="+rocm") depends_on("hipblas", when="+rocm") @@ -117,12 +132,6 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): depends_on("ginkgo@1.5.0.glu_experimental", when="+ginkgo") - conflicts( - "+shared", - when="+cuda+raja", - msg="umpire+cuda exports device code and requires static libs", - ) - flag_handler = build_system_flags def cmake_args(self): |