Skip to content

Commit f4ce75f

Browse files
authored
update HIP/CUDA dependences to include sparse libraries (#1686)
update HIP/CUDA dependences to include sparse libraries these are needed by AMReX These are copied of the dependency scripts from AMReX
1 parent b47950e commit f4ce75f

File tree

4 files changed

+46
-36
lines changed

4 files changed

+46
-36
lines changed

.github/workflows/cuda.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
cd ../..
2727
2828
- name: Dependencies
29-
run: .github/workflows/dependencies/dependencies_nvcc11.sh
29+
run: .github/workflows/dependencies/dependencies_nvcc.sh 11.7
3030

3131
- name: compile test_react (aprox13)
3232
run: |

.github/workflows/dependencies/dependencies_hip.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ echo 'export PATH=/opt/rocm/llvm/bin:/opt/rocm/bin:/opt/rocm/profiler/bin:/opt/r
4040

4141
# we should not need to export HIP_PATH=/opt/rocm/hip with those installs
4242

43+
sudo apt-get clean
4344
sudo apt-get update
4445

4546
# Ref.: https://rocmdocs.amd.com/en/latest/Installation_Guide/Installation-Guide.html#installing-development-packages-for-cross-compilation
@@ -56,7 +57,9 @@ sudo apt-get install -y --no-install-recommends \
5657
roctracer-dev \
5758
rocprofiler-dev \
5859
rocrand-dev \
59-
rocprim-dev
60+
rocfft-dev \
61+
rocprim-dev \
62+
rocsparse-dev
6063

6164
# hiprand-dev is a new package that does not exist in old versions
6265
sudo apt-get install -y --no-install-recommends hiprand-dev || true
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
#!/usr/bin/env bash
2+
#
3+
# Copyright 2020-2022 Axel Huebl
4+
#
5+
# License: BSD-3-Clause-LBNL
6+
7+
set -eu -o pipefail
8+
9+
# `man apt.conf`:
10+
# Number of retries to perform. If this is non-zero APT will retry
11+
# failed files the given number of times.
12+
echo 'Acquire::Retries "3";' | sudo tee /etc/apt/apt.conf.d/80-retries
13+
14+
sudo apt-get -qqq update
15+
sudo apt-get install -y \
16+
build-essential \
17+
ca-certificates \
18+
cmake \
19+
g++ \
20+
gfortran \
21+
gnupg \
22+
libopenmpi-dev \
23+
openmpi-bin \
24+
pkg-config \
25+
wget
26+
27+
VERSION_DOTTED=${1-12.0} && VERSION_DASHED=$(sed 's/\./-/' <<< $VERSION_DOTTED)
28+
curl -O https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-keyring_1.0-1_all.deb
29+
sudo dpkg -i cuda-keyring_1.0-1_all.deb
30+
sudo apt-get update
31+
sudo apt-get install -y \
32+
cuda-command-line-tools-$VERSION_DASHED \
33+
cuda-compiler-$VERSION_DASHED \
34+
cuda-cupti-dev-$VERSION_DASHED \
35+
cuda-minimal-build-$VERSION_DASHED \
36+
cuda-nvml-dev-$VERSION_DASHED \
37+
cuda-nvtx-$VERSION_DASHED \
38+
libcufft-dev-$VERSION_DASHED \
39+
libcurand-dev-$VERSION_DASHED \
40+
libcusparse-dev-$VERSION_DASHED
41+
sudo ln -s cuda-$VERSION_DOTTED /usr/local/cuda

.github/workflows/dependencies/dependencies_nvcc11.sh

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)