Skip to content

feat: add Python CUDA, ROCm and Vulkan extras - #29

Open
zhangzhenghao wants to merge 1 commit into
mainfrom
feat/python-gpu-extras
Open

zhangzhenghao wants to merge 1 commit into
mainfrom
feat/python-gpu-extras

Conversation

@zhangzhenghao

Copy link
Copy Markdown
Collaborator

Summary

  • Add clap-cpp[cuda], clap-cpp[rocm] and clap-cpp[vulkan] as exact-version dependencies on disjoint native backend distributions, preserving the default CPU package and public Python API.
  • Select the installed GPU backend automatically (or explicitly with CLAP_CPP_BACKEND), reject ambiguous/mismatched packages, and report missing GPU runtime dependencies rather than silently changing native modules.
  • Enable GPU wheel CMake builds and connect CUDA/HIP to the existing cached native dense-matmul path; retain existing CPU precision/fallback behavior.
  • Add backend-specific Python release jobs, sccache C/C++/CUDA/HIP launchers, auditwheel repair, source archives, GitHub release assets, and stable-release PyPI trusted publishing.

Verification

As requested, no tests were added or run.

  • Built the CPU wheel through the default sdist-to-wheel path on Linux x86_64 / CPython 3.12.
  • Built all four source distributions and inspected native sources, licenses, versions and extra dependencies.
  • Inspected the CPU wheel's native module and shared-library dependencies (only standard platform runtime libraries).
  • C++ syntax checks passed for CUDA, HIP and Vulkan compilation branches.
  • Python 3.9 syntax, workflow actionlint and whitespace checks passed.

Actual GPU compilation/inference and the hosted release workflow have not been executed. GPU release wheels initially cover Linux x86_64; CPU wheels cover Linux x86_64/ARM64, macOS ARM64 and Windows x86_64, CPython 3.9–3.14. System GPU drivers/runtimes are required as documented.

First-release setup

Configure PyPI trusted publishers for clap-cpp, clap-cpp-cuda, clap-cpp-rocm and clap-cpp-vulkan, using gorse-io/clap.cpp, workflow python-release.yml, environment pypi. Stable releases publish to PyPI; prereleases attach GitHub assets only. No release or package has been published by this change.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants