Skip to content

[cuda.compute]: Add smoke tests for benchmarks#9885

Open
NaderAlAwar wants to merge 4 commits into
NVIDIA:mainfrom
NaderAlAwar:fix-cuda-compute-benchmarks
Open

[cuda.compute]: Add smoke tests for benchmarks#9885
NaderAlAwar wants to merge 4 commits into
NVIDIA:mainfrom
NaderAlAwar:fix-cuda-compute-benchmarks

Conversation

@NaderAlAwar

Copy link
Copy Markdown
Contributor

No description provided.

@NaderAlAwar
NaderAlAwar requested review from a team as code owners July 15, 2026 21:47
@NaderAlAwar
NaderAlAwar requested a review from shwina July 15, 2026 21:47
@NaderAlAwar
NaderAlAwar requested a review from jrhemstad July 15, 2026 21:47
@github-project-automation github-project-automation Bot moved this to Todo in CCCL Jul 15, 2026
@cccl-authenticator-app cccl-authenticator-app Bot moved this from Todo to In Review in CCCL Jul 15, 2026
@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 8eb0826f-06a9-46c1-8fe0-1a90a927970e

📥 Commits

Reviewing files that changed from the base of the PR and between c4286b7 and 22068e6.

📒 Files selected for processing (1)
  • python/cuda_cccl/benchmarks/compute/run_benchmarks.py
🚧 Files skipped from review as they are similar to previous changes (1)
  • python/cuda_cccl/benchmarks/compute/run_benchmarks.py

📝 Walkthrough

Summary by CodeRabbit

  • Tests
    • Extended CI benchmark smoke tests to cover host-overhead and compute throughput across supported CI environments, including Windows and Linux.
    • Added additional coop benchmark smoke coverage with a profiling run.
    • Benchmarks now execute in fast pass/fail validation mode (performance measurement disabled).
    • Updated the benchmark runner to support an optional profile mode and to fail if any benchmark run fails.
    • CI now installs the additional benchmark-related dependencies needed for these runs.

Walkthrough

Benchmark execution gains profile mode and failure propagation. Host benchmark wrappers generalize native-compute bypassing. Linux, Windows, and cooperative CUDA CI jobs install required benchmark dependencies and run benchmark smoke tests.

Changes

Benchmark smoke testing

Layer / File(s) Summary
Benchmark runner profile mode
python/cuda_cccl/benchmarks/compute/run_benchmarks.py
The runner adds profile-mode support, lazy YAML loading, configuration reporting, and non-zero exit status aggregation for failed benchmarks.
Generalized native compute bypass
python/cuda_cccl/benchmarks/compute/host/host_benchmark_cases.py
NoopBuildResult intercepts multiple compute entry points, while wrapper patching replaces bound build results and recurses through partitioners.
CUDA CI benchmark smoke tests
ci/test_cuda_cccl_examples_python.sh, ci/windows/test_cuda_cccl_examples_python.ps1, ci/test_cuda_coop_python.sh
Linux, Windows, and cooperative CUDA jobs install benchmark dependencies and run host, throughput, or warp-reduction smoke tests.

Suggested reviewers: shwina, jrhemstad


Comment @coderabbitai help to get the list of available commands.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@NaderAlAwar

Copy link
Copy Markdown
Contributor Author

CI is failing because we need 3.14 wheels for cuda-bench. These should be released soon

@github-actions

This comment has been minimized.

Comment on lines +24 to +26
# Install cuda_cccl, plus CuPy which the cuda.compute examples require, plus the
# benchmark-smoke deps: pytest-benchmark (host-overhead), and cuda-bench + PyYAML
# (throughput; PyYAML is needed by run_benchmarks.py --quick).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This dependency stuff is usually be specified in a pyproject.toml as an optional configuration (like we appear to have for the tests). Can we not do that here as well?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Running the examples as tests requires extra dependencies (like CuPy + others mentioned here). We want to keep the existing optional configuration for testing minimal (without including these), and we don't want to add an extra test-examples configuration

Comment thread python/cuda_cccl/benchmarks/compute/host/host_benchmark_cases.py Outdated
Comment thread python/cuda_cccl/benchmarks/compute/host/host_benchmark_cases.py Outdated
Comment thread python/cuda_cccl/benchmarks/compute/run_benchmarks.py Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
python/cuda_cccl/benchmarks/compute/run_benchmarks.py (1)

407-413: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

suggestion: Add focused tests for the new CLI and exit-status contract: verify --profile reaches both child command builders, non-zero C++/Python statuses exit with code 1, execution errors with returncode=None are failures, and skipped sides remain neutral. As per coding guidelines, validate changes with relevant targeted builds and tests, and report the results.

Also applies to: 513-525

Source: Coding guidelines

ci/test_cuda_coop_python.sh (1)

32-37: 🚀 Performance & Scalability | 🔵 Trivial | ⚡ Quick win

suggestion: Lines 32-37 use --profile without a quick mode or axis filter. Profile mode reduces iterations, but a future expansion of the benchmark configuration space could make this smoke job unnecessarily expensive. Add a reduced configuration if supported, or verify that the current axis space is intentionally bounded.

As per path instructions, "For CI and build scripts, focus on matrix correctness, targeted build/test behavior, cache/artifact handling, environment setup, GPU availability assumptions, clear failures, and avoiding unnecessary expensive jobs."

Source: Path instructions


ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: a95743d6-d216-4d33-b9cb-0b7b24865a55

📥 Commits

Reviewing files that changed from the base of the PR and between 8aef506 and c4286b7.

📒 Files selected for processing (4)
  • ci/test_cuda_cccl_examples_python.sh
  • ci/test_cuda_coop_python.sh
  • python/cuda_cccl/benchmarks/compute/host/host_benchmark_cases.py
  • python/cuda_cccl/benchmarks/compute/run_benchmarks.py
🚧 Files skipped from review as they are similar to previous changes (1)
  • python/cuda_cccl/benchmarks/compute/host/host_benchmark_cases.py

Comment thread ci/test_cuda_cccl_examples_python.sh

@Jacobfaib Jacobfaib left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Python side LGTM

Comment thread python/cuda_cccl/benchmarks/compute/run_benchmarks.py Outdated
@github-actions

Copy link
Copy Markdown
Contributor

😬 CI Workflow Results

🟥 Finished in 2h 52m: Pass: 98%/515 | Total: 4d 12h | Max: 2h 38m | Hits: 99%/666593

See results here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Review

Development

Successfully merging this pull request may close these issues.

2 participants