Skip to content

Commit f54c8a1

Browse files
Modify CI to enable tests on CUDA 13.1 and add Dockerfiles for CUDA 13.1 (#21564)
1 parent c890902 commit f54c8a1

6 files changed

Lines changed: 126 additions & 0 deletions

File tree

.github/workflows/sycl-containers.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ jobs:
5151
file: ubuntu2404_build
5252
tag: latest
5353
build_args: ""
54+
- name: Build Ubuntu 24.04 Docker image with CUDA 13.1
55+
file: ubuntu2404_build_cuda131
56+
tag: latest
57+
build_args: ""
5458
steps:
5559
- name: Checkout
5660
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
@@ -87,6 +91,9 @@ jobs:
8791
- name: Build + Intel Drivers Ubuntu 24.04 Docker image
8892
file: ubuntu2404_intel_drivers
8993
tag: latest
94+
- name: Build + Intel Drivers Ubuntu 24.04 Docker image with CUDA 13.1
95+
file: ubuntu2404_intel_drivers_cuda131
96+
tag: latest
9097
steps:
9198
- name: Checkout
9299
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2

.github/workflows/sycl-linux-precommit.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,11 @@ jobs:
159159
runner: '["Linux", "cuda"]'
160160
image_options: -u 1001 --gpus all --cap-add SYS_ADMIN
161161
target_devices: cuda:gpu
162+
- name: NVIDIA/CUDA 13.1
163+
runner: '["Linux", "cuda13"]'
164+
image: "ghcr.io/intel/llvm/ubuntu2404_intel_drivers_cuda131:latest"
165+
image_options: -u 1001 --gpus all --cap-add SYS_ADMIN
166+
target_devices: cuda:gpu
162167
- name: Intel / Arc A-Series Graphics
163168
runner: '["Linux", "arc"]'
164169
target_devices: level_zero:gpu;opencl:gpu;level_zero_v2:gpu
@@ -247,6 +252,11 @@ jobs:
247252
runner: '["Linux", "cuda"]'
248253
image_options: -u 1001 --gpus all --cap-add SYS_ADMIN
249254
target_devices: cuda:gpu
255+
- name: NVIDIA/CUDA 13.1
256+
runner: '["Linux", "cuda13"]'
257+
image: "ghcr.io/intel/llvm/ubuntu2404_intel_drivers_cuda131:latest"
258+
image_options: -u 1001 --gpus all --cap-add SYS_ADMIN
259+
target_devices: cuda:gpu
250260

251261
uses: ./.github/workflows/sycl-linux-run-tests.yml
252262
with:
@@ -287,6 +297,10 @@ jobs:
287297
- name: CUDA system
288298
runner: '["Linux", "cuda"]'
289299
image_extra_opts: --gpus all
300+
- name: CUDA system with CUDA 13.1
301+
runner: '["Linux", "cuda13"]'
302+
image: "ghcr.io/intel/llvm/ubuntu2404_intel_drivers_cuda131:latest"
303+
image_extra_opts: --gpus all
290304
uses: ./.github/workflows/sycl-linux-run-tests.yml
291305
with:
292306
name: Perf tests on ${{ matrix.name }}

.github/workflows/ur-build-hw.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ jobs:
129129
${{ matrix.adapter.other_name != '' && format('-DUR_BUILD_ADAPTER_{0}=ON', matrix.adapter.other_name) || '' }}
130130
-DUR_STATIC_LOADER=${{matrix.adapter.static_Loader}}
131131
-DUR_STATIC_ADAPTER_${{matrix.adapter.name}}=${{matrix.adapter.static_adapter}}
132+
${{ matrix.adapter.name == 'CUDA' && '-DUR_CONFORMANCE_NVIDIA_ARCH="sm_75"' || '' }}
132133
-DUR_DPCXX=./dpcpp_compiler/bin/clang++
133134
-DUR_SYCL_LIBRARY_DIR=./dpcpp_compiler/lib
134135
-DCMAKE_INSTALL_PREFIX=./install

.github/workflows/ur-precommit.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,14 @@ jobs:
7070
runner: UR_L0
7171
other_adapter: NATIVE_CPU
7272
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
73+
74+
# 13.1
75+
- name: CUDA
76+
runner: cuda13
77+
docker_image: "ghcr.io/intel/llvm/ubuntu2404_intel_drivers_cuda131:latest"
78+
image_options: -u 1001 --privileged --cap-add SYS_ADMIN --gpus all
79+
80+
# 12.6.3
7381
- name: CUDA
7482
runner: UR_CUDA
7583
image_options: -u 1001 --privileged --cap-add SYS_ADMIN --gpus all
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
FROM nvidia/cuda:13.1.0-devel-ubuntu24.04
2+
3+
ENV DEBIAN_FRONTEND=noninteractive
4+
5+
USER root
6+
7+
# Configure LLVM nightly repo
8+
RUN apt-get update -qq && apt-get install --no-install-recommends -yqq curl ca-certificates
9+
RUN curl -sSL https://apt.llvm.org/llvm-snapshot.gpg.key -o /etc/apt/trusted.gpg.d/apt.llvm.org.asc
10+
RUN echo 'deb http://apt.llvm.org/noble/ llvm-toolchain-noble main' > /etc/apt/sources.list.d/llvm.list
11+
RUN echo 'deb http://apt.llvm.org/noble/ llvm-toolchain-noble-22 main' > /etc/apt/sources.list.d/llvm.list
12+
13+
# Install SYCL prerequisites
14+
COPY scripts/install_build_tools.sh /install.sh
15+
RUN /install.sh
16+
17+
COPY scripts/install_vulkan.sh /install_vulkan.sh
18+
RUN /install_vulkan.sh
19+
20+
# libzstd-dev installed by default on Ubuntu 24.04 is not compiled with -fPIC flag.
21+
# This causes linking errors when building SYCL runtime.
22+
# Bug: https://github.com/intel/llvm/issues/15935
23+
# Workaround: build zstd from sources with -fPIC flag.
24+
COPY scripts/build_zstd.sh /build_zstd.sh
25+
RUN /build_zstd.sh
26+
27+
SHELL ["/bin/bash", "-ec"]
28+
29+
# Make the directory if it doesn't exist yet.
30+
# This location is recommended by the distribution maintainers.
31+
RUN mkdir --parents --mode=0755 /etc/apt/keyrings
32+
# Download the key, convert the signing-key to a full
33+
# keyring required by apt and store in the keyring directory
34+
RUN curl -sSL https://repo.radeon.com/rocm/rocm.gpg.key | \
35+
gpg --dearmor | tee /etc/apt/keyrings/rocm.gpg > /dev/null && \
36+
# Add rocm repo
37+
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/6.3/ubuntu noble main" \
38+
| tee /etc/apt/sources.list.d/amdgpu.list && \
39+
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/6.3 noble main" \
40+
| tee --append /etc/apt/sources.list.d/rocm.list && \
41+
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
42+
| tee /etc/apt/preferences.d/rocm-pin-600 && \
43+
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
44+
| tee /etc/apt/preferences.d/rocm-pin-600
45+
# Install the ROCM kernel driver
46+
RUN apt update && apt install -yqq rocm-dev && \
47+
apt-get clean && \
48+
rm -rf /var/lib/apt/lists/*
49+
50+
# Fix Vulkan install inside container
51+
# https://stackoverflow.com/questions/74965945/vulkan-is-unable-to-detect-nvidia-gpu-from-within-a-docker-container-when-using
52+
RUN apt-get update && \
53+
apt-get install -y libegl1 && \
54+
apt-get install -y --no-install-recommends --download-only libnvidia-gl-565 && \
55+
dpkg-deb --extract /var/cache/apt/archives/libnvidia-gl-565_*.deb extracted && \
56+
cp -R ./extracted/usr/* /usr/ && \
57+
rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/*.deb ./extracted
58+
59+
COPY scripts/create-sycl-user.sh /user-setup.sh
60+
RUN /user-setup.sh
61+
62+
COPY scripts/docker_entrypoint.sh /docker_entrypoint.sh
63+
64+
COPY actions/cached_checkout /actions/cached_checkout
65+
COPY actions/cleanup /actions/cleanup
66+
COPY scripts/install_drivers.sh /opt/install_drivers.sh
67+
68+
USER sycl
69+
70+
ENTRYPOINT ["/docker_entrypoint.sh"]
71+
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
ARG base_tag=latest
2+
ARG base_image=ghcr.io/intel/llvm/ubuntu2404_build_cuda131
3+
4+
FROM $base_image:$base_tag
5+
6+
ENV DEBIAN_FRONTEND=noninteractive
7+
8+
USER root
9+
10+
RUN apt update && apt install -yqq wget
11+
12+
COPY scripts/install_drivers.sh /
13+
COPY dependencies.json /
14+
15+
RUN mkdir /runtimes
16+
ENV INSTALL_LOCATION=/runtimes
17+
RUN --mount=type=secret,id=github_token \
18+
GITHUB_TOKEN=$(cat /run/secrets/github_token) /install_drivers.sh dependencies.json --all
19+
20+
COPY scripts/drivers_entrypoint.sh /drivers_entrypoint.sh
21+
22+
USER sycl
23+
24+
ENTRYPOINT ["/bin/bash", "/drivers_entrypoint.sh"]
25+

0 commit comments

Comments
 (0)