Skip to content

Commit 7349f53

Browse files
committed
Add libcudf debug build/test to nightly
1 parent c9d1321 commit 7349f53

3 files changed

Lines changed: 97 additions & 0 deletions

File tree

‎.github/workflows/pr.yaml‎

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
- cpp-linters
2222
- conda-cpp-checks
2323
- conda-cpp-tests
24+
- conda-cpp-debug-tests
2425
- conda-python-build
2526
- conda-python-build-noarch
2627
- conda-python-import-tests
@@ -332,6 +333,23 @@ jobs:
332333
arch: "amd64"
333334
container_image: "rapidsai/ci-conda:26.12-latest"
334335
script: "ci/test_cmake.sh"
336+
# TODO: temporary for testing; move to test.yaml (nightly) before merging.
337+
conda-cpp-debug-tests:
338+
needs: [checks]
339+
permissions:
340+
actions: read
341+
contents: read
342+
id-token: write
343+
packages: read
344+
pull-requests: read
345+
secrets: inherit # zizmor: ignore[secrets-inherit]
346+
uses: rapidsai/shared-workflows/.github/workflows/custom-job.yaml@main
347+
with:
348+
build_type: pull-request
349+
node_type: "gpu-rtxpro6000-latest-1"
350+
arch: "amd64"
351+
container_image: "rapidsai/ci-conda:26.12-latest"
352+
script: "ci/test_cpp_debug.sh"
335353
cudf-polars-quent:
336354
needs: [checks, changed-files]
337355
permissions:

‎ci/test_cpp_debug.sh‎

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
#!/bin/bash
2+
# SPDX-FileCopyrightText: Copyright (c) 2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3+
# SPDX-License-Identifier: Apache-2.0
4+
5+
# Builds libcudf and its gtests from source with CMAKE_BUILD_TYPE=Debug and runs the gtests.
6+
# Must be run on a GPU node since the build targets the native GPU architecture.
7+
8+
set -euo pipefail
9+
10+
# Support invoking test_cpp_debug.sh outside the script directory
11+
cd "$(dirname "$(realpath "${BASH_SOURCE[0]}")")"/../
12+
13+
rapids-logger "Create debug build conda environment"
14+
. /opt/conda/etc/profile.d/conda.sh
15+
16+
rapids-logger "Configuring conda strict channel priority"
17+
conda config --set channel_priority strict
18+
19+
ENV_YAML_DIR="$(mktemp -d)"
20+
21+
rapids-dependency-file-generator \
22+
--output conda \
23+
--file-key test_cpp_debug \
24+
--matrix "cuda=${RAPIDS_CUDA_VERSION%.*};arch=$(arch)" | tee "${ENV_YAML_DIR}/env.yaml"
25+
26+
rapids-mamba-retry env create --yes -f "${ENV_YAML_DIR}/env.yaml" -n test_cpp_debug
27+
28+
# Temporarily allow unbound variables for conda activation.
29+
set +u
30+
conda activate test_cpp_debug
31+
set -u
32+
33+
# Keep the preprocessor cache separate from the Release conda builds since the flags never match.
34+
SCCACHE_S3_PREPROCESSOR_CACHE_KEY_PREFIX="libcudf-$(arch)-cuda${RAPIDS_CUDA_VERSION%%.*}-debug-preprocessor-cache"
35+
export SCCACHE_S3_PREPROCESSOR_CACHE_KEY_PREFIX
36+
export SCCACHE_S3_USE_PREPROCESSOR_CACHE_MODE=true
37+
38+
source rapids-configure-sccache
39+
40+
export CMAKE_GENERATOR=Ninja
41+
42+
rapids-print-env
43+
44+
rapids-logger "Check GPU usage"
45+
nvidia-smi
46+
47+
sccache --stop-server 2>/dev/null || true
48+
49+
rapids-logger "Build libcudf and gtests (Debug)"
50+
# -g: Debug build, -n: do not install, benchmarks are not built unless requested.
51+
# The GPU architecture defaults to the native GPU on this node.
52+
./build.sh -g -n libcudf tests
53+
54+
sccache --show-adv-stats
55+
sccache --stop-server >/dev/null 2>&1 || true
56+
57+
EXITCODE=0
58+
trap "EXITCODE=1" ERR
59+
set +e
60+
61+
rapids-logger "Run libcudf gtests (Debug)"
62+
# Debug host code is unoptimized, so allow more time than ci/test_cpp.sh does.
63+
timeout 2h ctest --test-dir cpp/build --output-on-failure --no-tests=error -j20
64+
65+
rapids-logger "Test script exiting with value: $EXITCODE"
66+
exit ${EXITCODE}

‎dependencies.yaml‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,19 @@ files:
189189
- develop
190190
- iwyu
191191
- py_version
192+
test_cpp_debug:
193+
output: none
194+
includes:
195+
- build_all
196+
- build_base
197+
- build_cpp
198+
- cuda
199+
- cuda_version
200+
- depends_on_libkvikio
201+
- depends_on_libnvcomp
202+
- depends_on_librmm
203+
- depends_on_rapids_logger
204+
- test_cpp
192205
docs:
193206
output: none
194207
includes:

0 commit comments

Comments
 (0)