From 321298b115fbb5d60aa3b4d2013db4471d1fdbcc Mon Sep 17 00:00:00 2001 From: arjun-raj-kuppala <60718144+arjun-raj-kuppala@users.noreply.github.com> Date: Fri, 4 Dec 2020 02:23:55 -0800 Subject: AMD ROCm - Bump up rocalution with 3.9.0 and 3.10.0 releases (#20243) --- var/spack/repos/builtin/packages/rocalution/package.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'var') diff --git a/var/spack/repos/builtin/packages/rocalution/package.py b/var/spack/repos/builtin/packages/rocalution/package.py index 93b729c7c5..90722d07c7 100644 --- a/var/spack/repos/builtin/packages/rocalution/package.py +++ b/var/spack/repos/builtin/packages/rocalution/package.py @@ -20,12 +20,14 @@ class Rocalution(CMakePackage): maintainers = ['srekolam', 'arjun-raj-kuppala'] + version('3.10.0', sha256='c24cb9d1a8a1a3118040b8b16dec7c06268bcf157424d3378256cc9eb93f1b58') + version('3.9.0', sha256='1ce36801fe1d44f743b46b43345c0cd90d76b73911b2ec97be763f93a35396fb') version('3.8.0', sha256='39e64a29e75c4276163a93596436064c6338770ca72ce7f43711ed8285ed2de5') version('3.7.0', sha256='4d6b20aaaac3bafb7ec084d684417bf578349203b0f9f54168f669e3ec5699f8') version('3.5.0', sha256='be2f78c10c100d7fd9df5dd2403a44700219c2cbabaacf2ea50a6e2241df7bfe') depends_on('cmake@3.5:', type='build') - for ver in ['3.5.0', '3.7.0', '3.8.0']: + for ver in ['3.5.0', '3.7.0', '3.8.0', '3.9.0', '3.10.0']: depends_on('hip@' + ver, when='@' + ver) depends_on('rocblas@' + ver, type='link', when='@' + ver) depends_on('rocprim@' + ver, type='link', when='@' + ver) @@ -33,12 +35,24 @@ class Rocalution(CMakePackage): depends_on('rocm-device-libs@' + ver, type='build', when='@' + ver) depends_on('comgr@' + ver, type='build', when='@' + ver) depends_on('llvm-amdgpu@' + ver, type='build', when='@' + ver) + if ver in ['3.9.0', '3.10.0']: + depends_on('rocrand@' + ver, type='link', when='@' + ver) patch('0001-fix-hip-build-error.patch') def setup_build_environment(self, env): env.set('CXX', self.spec['hip'].hipcc) + def patch(self): + if '@3.9.0:' in self.spec: + kwargs = {'ignore_absent': False, 'backup': False, 'string': False} + + with working_dir('src/base/hip'): + match = '^#include ' + substitute = "#include " + files = ['hip_rand_normal.hpp', 'hip_rand_uniform.hpp'] + filter_file(match, substitute, *files, **kwargs) + def cmake_args(self): args = [ '-DSUPPORT_HIP=ON', -- cgit v1.2.3-70-g09d2