AMD ROCm Mathlibs (#17699)
* ROCm Mathlibs * fixed the review comments * fixed flake8 issues
This commit is contained in:
parent
4a2136670d
commit
3dfd99c57a
39
var/spack/repos/builtin/packages/hipcub/package.py
Normal file
39
var/spack/repos/builtin/packages/hipcub/package.py
Normal file
@ -0,0 +1,39 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Hipcub(CMakePackage):
|
||||
""" Radeon Open Compute Parallel Primitives Library"""
|
||||
|
||||
homepage = "https://github.com/ROCmSoftwarePlatform/hipCUB"
|
||||
url = "https://github.com/ROCmSoftwarePlatform/hipCUB/archive/rocm-3.5.0.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('3.5.0', sha256='1eb2cb5f6e90ed1b7a9ac6dd86f09ec2ea27bceb5a92eeffa9c2123950c53b9d')
|
||||
|
||||
variant('build_type', default='Release', values=("Release", "Debug"), description='CMake build type')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
for ver in ['3.5.0']:
|
||||
depends_on('hip@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocm-device-libs@' + ver, type='build', when='@' + ver)
|
||||
depends_on('comgr@' + ver, type='build', when='@' + ver)
|
||||
depends_on('hsa-rocr-dev@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocprim@' + ver, type='build', when='@' + ver)
|
||||
|
||||
def setup_build_environment(self, env):
|
||||
env.set('CXX', self.spec['hip'].hipcc)
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
|
||||
args = [
|
||||
'-DCMAKE_MODULE_PATH={0}/cmake'.format(spec['hip'].prefix)
|
||||
]
|
||||
|
||||
return args
|
24
var/spack/repos/builtin/packages/miopengemm/package.py
Normal file
24
var/spack/repos/builtin/packages/miopengemm/package.py
Normal file
@ -0,0 +1,24 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Miopengemm(CMakePackage):
|
||||
"""An OpenCL general matrix multiplication (GEMM) API
|
||||
and kernel generator"""
|
||||
|
||||
homepage = "https://github.com/ROCmSoftwarePlatform/MIOpenGEMM"
|
||||
url = "https://github.com/ROCmSoftwarePlatform/MIOpenGEMM/archive/1.1.6.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('1.1.6', sha256='9ab04903794c6a59432928eaec92c687d51e2b4fd29630cf227cbc49d56dc69b')
|
||||
|
||||
variant('build_type', default='Release', values=("Release", "Debug"), description='CMake build type')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
depends_on('rocm-cmake@3.5:', type='build', when='@1.1.6')
|
||||
depends_on('rocm-opencl@3.5:', type='build', when='@1.1.6')
|
31
var/spack/repos/builtin/packages/rccl/package.py
Normal file
31
var/spack/repos/builtin/packages/rccl/package.py
Normal file
@ -0,0 +1,31 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Rccl(CMakePackage):
|
||||
"""RCCL (pronounced "Rickle") is a stand-alone library
|
||||
of standard collective communication routines for GPUs,
|
||||
implementing all-reduce, all-gather, reduce, broadcast,
|
||||
and reduce-scatter."""
|
||||
|
||||
homepage = "https://github.com/RadeonOpenCompute/rccl"
|
||||
url = "https://github.com/ROCmSoftwarePlatform/rccl/archive/rocm-3.5.0.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('3.5.0', sha256='290b57a66758dce47d0bfff3f5f8317df24764e858af67f60ddcdcadb9337253')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
for ver in ['3.5.0']:
|
||||
depends_on('rocm-cmake@' + ver, type='build', when='@' + ver)
|
||||
depends_on('hip@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocm-device-libs@' + ver, type='build', when='@' + ver)
|
||||
depends_on('comgr@' + ver, type='build', when='@' + ver)
|
||||
depends_on('hsa-rocr-dev@' + ver, type='build', when='@' + ver)
|
||||
|
||||
def setup_build_environment(self, env):
|
||||
env.set('CXX', self.spec['hip'].hipcc)
|
24
var/spack/repos/builtin/packages/rocm-clang-ocl/package.py
Normal file
24
var/spack/repos/builtin/packages/rocm-clang-ocl/package.py
Normal file
@ -0,0 +1,24 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class RocmClangOcl(CMakePackage):
|
||||
""" OpenCL compilation with clang compiler """
|
||||
|
||||
homepage = "https://github.com/RadeonOpenCompute/clang-ocl"
|
||||
url = "https://github.com/RadeonOpenCompute/clang-ocl/archive/rocm-3.5.0.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('3.5.0', sha256='38c95fbd0ac3d11d9bd224ad333b68b9620dde502b8a8a9f3d96ba642901e8bb')
|
||||
|
||||
variant('build_type', default='Release', values=("Release", "Debug"), description='CMake build type')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
for ver in ['3.5.0']:
|
||||
depends_on('rocm-cmake@' + ver, type='build', when='@' + ver)
|
||||
depends_on('llvm-amdgpu@' + ver, type='build', when='@' + ver)
|
38
var/spack/repos/builtin/packages/rocprim/package.py
Normal file
38
var/spack/repos/builtin/packages/rocprim/package.py
Normal file
@ -0,0 +1,38 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Rocprim(CMakePackage):
|
||||
""" Radeon Open Compute Parallel Primitives Library"""
|
||||
|
||||
homepage = "https://github.com/ROCmSoftwarePlatform/rocPRIM"
|
||||
url = "https://github.com/ROCmSoftwarePlatform/rocPRIM/archive/rocm-3.5.0.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('3.5.0', sha256='29302dbeb27ae88632aa1be43a721f03e7e597c329602f9ca9c9c530c1def40d')
|
||||
|
||||
variant('build_type', default='Release', values=("Release", "Debug"), description='CMake build type')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
for ver in ['3.5.0']:
|
||||
depends_on('hip@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocm-device-libs@' + ver, type='build', when='@' + ver)
|
||||
depends_on('comgr@' + ver, type='build', when='@' + ver)
|
||||
depends_on('hsa-rocr-dev@' + ver, type='build', when='@' + ver)
|
||||
|
||||
def setup_build_environment(self, env):
|
||||
env.set('CXX', self.spec['hip'].hipcc)
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
|
||||
args = [
|
||||
'-DCMAKE_MODULE_PATH={0}/cmake'.format(spec['hip'].prefix)
|
||||
]
|
||||
|
||||
return args
|
35
var/spack/repos/builtin/packages/rocsparse/package.py
Normal file
35
var/spack/repos/builtin/packages/rocsparse/package.py
Normal file
@ -0,0 +1,35 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Rocsparse(CMakePackage):
|
||||
"""rocSPARSE exposes a common interface that provides
|
||||
Basic Linear Algebra Subroutines for sparse computation
|
||||
implemented on top of AMD's Radeon Open eCosystem Platform ROCm runtime
|
||||
and toolchains. rocSPARSE is created using the HIP programming
|
||||
language and optimized for AMD's latest discrete GPUs."""
|
||||
|
||||
homepage = "https://github.com/ROCmSoftwarePlatform/rocSPARSE"
|
||||
url = "https://github.com/ROCmSoftwarePlatform/rocSPARSE/archive/rocm-3.5.0.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('3.5.0', sha256='9ca6bae7da78abbb47143c3d77ff4a8cd7d63979875fc7ebc46b400769fd9cb5')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
depends_on('boost', type='build')
|
||||
for ver in ['3.5.0']:
|
||||
depends_on('hip@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocm-device-libs@' + ver, type='build', when='@' + ver)
|
||||
depends_on('comgr@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocprim@' + ver, type='build', when='@' + ver)
|
||||
depends_on('llvm-amdgpu@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocminfo@' + ver, type='build', when='@' + ver)
|
||||
depends_on('hsa-rocr-dev@' + ver, type='build', when='@' + ver)
|
||||
|
||||
def setup_build_environment(self, env):
|
||||
env.set('CXX', self.spec['hip'].hipcc)
|
43
var/spack/repos/builtin/packages/rocthrust/package.py
Normal file
43
var/spack/repos/builtin/packages/rocthrust/package.py
Normal file
@ -0,0 +1,43 @@
|
||||
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
|
||||
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
||||
#
|
||||
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
||||
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Rocthrust(CMakePackage):
|
||||
"""Thrust is a parallel algorithm library. This library has been ported to
|
||||
HIP/ROCm platform, which uses the rocPRIM library. The HIP ported
|
||||
library works on HIP/ROCm platforms"""
|
||||
|
||||
homepage = "https://github.com/ROCmSoftwarePlatform/rocThrust"
|
||||
url = "https://github.com/ROCmSoftwarePlatform/rocThrust/archive/rocm-3.5.0.tar.gz"
|
||||
|
||||
maintainers = ['srekolam', 'arjun-raj-kuppala']
|
||||
|
||||
version('3.5.0', sha256='0d1bac1129d17bb1259fd06f5c9cb4c1620d1790b5c295b866fb3442d18923cb')
|
||||
|
||||
variant('build_type', default='Release', values=("Release", "Debug"),
|
||||
description='CMake build type')
|
||||
|
||||
depends_on('cmake@3:', type='build')
|
||||
for ver in ['3.5.0']:
|
||||
depends_on('hip@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocm-device-libs@' + ver, type='build', when='@' + ver)
|
||||
depends_on('comgr@' + ver, type='build', when='@' + ver)
|
||||
depends_on('hsa-rocr-dev@' + ver, type='build', when='@' + ver)
|
||||
depends_on('rocprim@' + ver, type='build', when='@' + ver)
|
||||
|
||||
def setup_build_environment(self, env):
|
||||
env.set('CXX', self.spec['hip'].hipcc)
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
|
||||
args = [
|
||||
'-DCMAKE_MODULE_PATH={0}/cmake'.format(spec['hip'].prefix)
|
||||
]
|
||||
|
||||
return args
|
Loading…
Reference in New Issue
Block a user