Skip to content

Add basic variable debug metadata - #233

Merged
nihalpasham merged 1 commit into
mainfrom
debug-info-full-locals
Jun 16, 2026
Merged

nihalpasham merged 1 commit into
mainfrom
debug-info-full-locals

Conversation

@nihalpasham

Copy link
Copy Markdown
Collaborator

Summary

This adds the first CUDA_OXIDE_DEBUG=full slice for device variable debug info.

It builds on the line-table work from #225. Line tables already give cuda-gdb source breakpoints; this PR starts teaching cuda-gdb about simple source locals and arguments too.

rustc var_debug_info
        |
        v
MIR local alloca tagged with name + simple type
        |
        v
LLVM alloca + llvm.dbg.declare
        |
        v
LLVM opt may salvage into #dbg_value
        |
        v
PTX DWARF + cuda-gdb info locals / print <var>

What lands

  • adds DebugKind::Full as a real variable-debug tier
  • carries whole-local var_debug_info from MIR translation onto local slots
  • supports the first small type surface:
    • bool
    • signed / unsigned integers
    • floats
    • raw pointers and references as pointer-shaped debug types
  • emits DILocalVariable, DIBasicType, DIDerivedType, and llvm.dbg.declare
  • preserves local debug tags through MIR-to-LLVM lowering
  • skips Pliron mem2reg in full-debug mode so dbg.declare does not point at deleted slots
  • keeps LLVM opt -O2 enabled, because LLVM can salvage many dbg.declare records into #dbg_value
  • strips only PTX .target ..., debug for line-tables mode, keeping fast source breakpoints
  • keeps PTX .target ..., debug for full mode, because cuda-gdb needs it for local/argument inspection

Mode split:

CUDA_OXIDE_DEBUG=line-tables
  source breakpoints / stepping
  no locals
  fast: strips PTX target debug after llc

CUDA_OXIDE_DEBUG=full
  source breakpoints / stepping
  supported locals + args
  slower: keeps PTX target debug for cuda-gdb variable inspection

What is intentionally not solved yet

This is not full Rust debug info yet. It deliberately skips:

  • ADTs, tuples, arrays, slices, closures, and rich Rust type trees
  • field/projection fragments like x.0, *p, or destructured variables
  • precise lexical scopes
  • constants from var_debug_info
  • Pliron mem2reg rewriting dbg.declare into dbg.value

Those stay tracked by #226.

Validation

Non-example CI/docs checks run locally:

  • cargo fmt --all -- --check
  • cargo clippy --workspace -- -D warnings
  • CI unit-test matrix packages with --all-targets
  • cargo test -p cuda-core --lib
  • cargo clippy --manifest-path crates/rustc-codegen-cuda/Cargo.toml --all-targets -- -D warnings
  • cargo test --manifest-path crates/rustc-codegen-cuda/Cargo.toml
  • RUSTDOCFLAGS="-D warnings" cargo doc --no-deps --workspace
  • cargo test --doc --workspace --exclude cuda-bindings
  • cargo deny check

Manual debug/perf checks:

  • CUDA_OXIDE_DEBUG=full cargo oxide pipeline compiler_features
  • CUDA_OXIDE_DEBUG=full CUDA_OXIDE_VERBOSE=1 cargo oxide build gemm
  • CUDA_OXIDE_DEBUG=full CUDA_OXIDE_VERBOSE=1 cargo oxide build tiled_gemm
  • cuda-gdb full-debug smoke on gemm: source breakpoint hit, backtrace works, supported locals/args visible where not optimized out
  • line-table PTX target-debug strip checked with cuda-gdb source breakpoint
  • gemm line-tables after strip: about 0.319 ms, matching no-debug speed
  • tiled_gemm line-tables after strip: about 0.230 ms, matching no-debug speed

Full example build/run coverage is being run separately.

Part of #226.
Builds on #225.
Related: #105, #106, #103, #67.

@nihalpasham nihalpasham added enhancement New feature or request debug info Debug information in generated PTX/IR (line/source maps) codegen Device code-generation pipeline (Rust MIR to IR to PTX) llvm-export Textual LLVM/NVVM IR exporter (llvm-export crate) IR-lowering Lowering between dialects (dialect-mir to LLVM dialect) tests Adds or improves test coverage labels Jun 16, 2026
@nihalpasham
nihalpasham merged commit 4dbeea3 into main Jun 16, 2026
24 checks passed
elibol added a commit to elibol/cuda-rust that referenced this pull request Aug 28, 2026
…head

The NVIDIA#233 branch was rewritten while resolving its conflicts with cutile
main; 9620a6f is no longer in its history. Repin all 222 example locks
at 5cf5a55, regenerate the five that predated the shared-crate switch,
and move nvls_all_reduce to simt::vmm now that cutile main's NVIDIA#202 vmm
module owns the root name.
elibol added a commit to elibol/cuda-rust that referenced this pull request Aug 31, 2026
The NVIDIA#233 branch gained the extern "C" wrapper ABI and the cuInit
coercion regression nihalpasham asked for; manifests are unchanged, so
this is a pure pin substitution across all 222 locks.
nihalpasham pushed a commit to elibol/cuda-rust that referenced this pull request Sep 3, 2026
…head

The NVIDIA#233 branch was rewritten while resolving its conflicts with cutile
main; 9620a6f is no longer in its history. Repin all 222 example locks
at 5cf5a55, regenerate the five that predated the shared-crate switch,
and move nvls_all_reduce to simt::vmm now that cutile main's NVIDIA#202 vmm
module owns the root name.
nihalpasham pushed a commit to elibol/cuda-rust that referenced this pull request Sep 3, 2026
The NVIDIA#233 branch gained the extern "C" wrapper ABI and the cuInit
coercion regression nihalpasham asked for; manifests are unchanged, so
this is a pure pin substitution across all 222 locks.
nihalpasham added a commit that referenced this pull request Sep 4, 2026
* feat: build the host-side crates from cutile-rs

Switches the workspace's cuda-bindings, cuda-core, and cuda-async to
the shared host-side crates from cutile-rs, pinned as git dependencies
on its feat/cuda-oxide-host-support branch, which carries this
workspace's surface under simt modules.

The local copies leave the workspace members but stay on disk as
standalone packages (the rustc-codegen-cuda pattern, manifests
de-inherited), so the example workspaces keep building unchanged.

Source changes are mechanical path edits: cuda_async module paths gain
the simt level (55 sites in cuda-host and cuda-macros, including
emitted code), and bare LaunchConfig becomes cuda_core::simt's, since
the root export belongs to the Tile-side type. The cuda_launch_async!
trybuild fixtures deepen their local cuda_async stub to match, and the
recorded stderr baselines regenerate with the new paths. CI installs
CUDA 13.2.0, the shared bindings' minimum.

cuda-host and cuda-macros test suites pass against the shared crates,
194 tests plus the trybuild guards, on an RTX 5090.

* ci: retire the departed host crates from the lanes; fmt; trybuild baselines

cuda-core and cuda-async left the workspace for the shared crates, so
the unit-test matrix drops their lanes and the exclusion comment stops
naming cuda-bindings; their tests run in cutile-rs CI. The Justfile
mirrors the matrix, as its guard requires. deny.toml allows the
cutile-rs git source the workspace now pins. rustfmt over the files
the path edits touched, and the remaining trybuild stderr baselines
regenerate with the simt paths, under both the plain and all-features
invocations.

* examples: build against the shared host-side crates

With cuda-host on the shared crates, every example graph carried two
same-named cuda-cores, its own path dependency on the retired local
copy and the shared one underneath cuda-host, which cannot type-check
together. The example manifests move to the same git dependencies the
workspace uses, their sources take the simt::LaunchConfig path the
rest of the tree took, and all 218 lockfiles refresh against the new
graph. The tile+simt interop example points its cutile dependencies
at the same branch, collapsing its graph to a single cuda-core.

* examples: rustfmt over the import rewrites

* examples: sweep the nested workspaces too

Four examples carry a nested device or kernel-lib workspace one level
deeper than the sweep reached; they kept path dependencies on the
retired local crates, recreating the two-cuda-core graph the sweep
exists to remove. Their manifests and lockfiles follow the rest.

* examples: catch the aligned-assignment manifests the sweep missed

Nine manifests write their dependencies with aligned equals signs,
which the exact-string sweep did not match, leaving them on the
retired path dependencies. A whitespace-tolerant pass converts them;
no path dependency on the retired crates remains anywhere under the
examples.

* examples: finish the shared-crate switch for all ten failing lanes

The async examples take the simt-level module paths, matching
cuda-host. The two primitive-f16 examples enable the shared crate's
f16 feature, which carries the nightly-gated DeviceCopy impl.
nvls_all_reduce builds against simt::vmm, with the multicast surface
enabled by the shared crate's new build script, and error-module
paths move to the root re-exports since the module is private there.
Every lockfile pins the branch rev carrying those additions.

* fix: keep tile interop on the tile async surface

Signed-off-by: nihalp <nihalp@nvidia.com>

* ci: back to CUDA 13.1.1, the shared bindings floor is 12.0 now

The shared host-side crates keep cuda-oxide's 12.x support: the
bindings floor dropped to 12.0 with the 13.x-only symbols behind
header probes, so the toolkit bump this branch carried is no longer
needed and the lanes return to their original 13.1.1.

* build: pin the shared crates at the 12.8-floor revision

Every red lane died in the pinned cuda-bindings build script, which
still enforced the old 13.2 floor against the 13.1.1 CI toolkit. All
219 lockfiles move to the branch revision carrying the 12.8 floor,
the probed host-function helper, peer, the published oxide-artifacts
dependency, and the DeviceCopy derive crate.

* build: repin the shared crates at the #233 conflict-resolution head

The #233 branch was rewritten while resolving its conflicts with cutile
main; 9620a6f is no longer in its history. Repin all 222 example locks
at 5cf5a55, regenerate the five that predated the shared-crate switch,
and move nvls_all_reduce to simt::vmm now that cutile main's #202 vmm
module owns the root name.

* build: align example locks to one version per crate

Main's #1198 gates CI on sync-example-locks.sh --check; align the
git-pinned workspaces the way its own docs prescribe (--align never
touches the git pins). 1920 pins moved, 221 locks agree.

* ci: detach the retired host crates and name them in the license guard

cuda-bindings was never given the standalone [workspace] table its two
siblings got at retirement, and main's stricter license guard now walks
every tracked manifest. Detach it the same way, commit the three
standalone locks the guard's --locked metadata needs, and name all
three retired roots first-party so their declared dependencies stay in
the inventory.

* build: repin the shared crates at aaf1364

The #233 branch gained the extern "C" wrapper ABI and the cuInit
coercion regression nihalpasham asked for; manifests are unchanged, so
this is a pure pin substitution across all 222 locks.

* examples: convert the three examples added on main to the shared crates

reborrow, sparse_mma_ordered_float, and shared_stage_select arrived on
main with local path deps and root LaunchConfig imports; convert them
the established way and seed their locks from vecadd's per the sync
script's doc, which lands them aligned on the first try (224 locks
agree). This also clears the clippy and cargo-deny lanes, which were
failing on the unconverted expansion and the stale --locked resolve.

* deps: track cutile-rs main for the shared host crates

cutile-rs#233 was squash-merged into cutile-rs main as a2c1ea4 and its
feature branch deleted, so the git dependencies on
feat/cuda-oxide-host-support no longer resolve. Point the 222 manifests
that declare cuda-bindings, cuda-core, and cuda-async at branch main and
repin the 225 lockfiles that carry the four shared packages
(cuda-bindings, cuda-core, cuda-core-derive, cuda-async, all 0.3.0) at
a2c1ea4bb4ae804f573a879785c96f870a4e1b84.

The shared crates' manifests are unchanged since the previous pin, so
the lock rewrite is a pure source substitution; every one of the 225
workspaces resolves with --locked. The only change in the four crates
between aaf1364 and main is the host-side toolkit floor moving from
CUDA 12.8 to 13.0 (MIN_CUDA_VERSION 13000 in cuda-bindings/build.rs);
CI installs 13.1.1 and already clears it.

From here cuda-oxide tracks cutile-rs main; advancing the pin is a
deliberate cargo update, reviewed like any dependency bump.

Signed-off-by: Melih Elibol <elibol@users.noreply.github.com>

* deps: pin the shared host crates to cutile-rs v0.3.1

Point the 222 manifests that declare cuda-bindings, cuda-core, and
cuda-async at the v0.3.1 tag instead of branch main, and re-resolve the
225 lockfiles that carry the four shared packages with cargo update, so
they now record cuda-bindings, cuda-core, cuda-core-derive, and cuda-async
0.3.1 at the tag's current target, 9f68be2d0aff0882ec329a453ddc756ad6e4f9e7.
Every workspace resolves with --locked and the example locks still agree
on one version per crate.

Referencing the tag rather than a commit means a re-tag before the final
release costs one cargo update pass and no manifest edits.

Between a2c1ea4 and the tag the shared crates gained toolkit-discovery
parity (CUDA_HOME fallback, targets/<arch>/include lookup,
CUDA_TOOLKIT_TARGET_DIR), executed host-crate tests, and the host runtime
audit follow-ups; DType became an unsafe trait and several driver wrappers
now return Result. None of those surfaces are used by cuda-oxide's own
code, and the simt:: modules are unchanged, so nothing here needed
adapting.

Signed-off-by: Melih Elibol <elibol@users.noreply.github.com>

* docs, scaffold: name the shared crates' simt surface everywhere users copy from

The host runtime now comes from the cutile-rs crates, whose cuda-oxide
API lives under cuda_core::simt and cuda_async::simt. Every snippet a
user copies has to say so: the README, the cuda-host README, the book
pages, two example READMEs, and the two cargo oxide new templates.

The scaffold also pointed cuda-core, cuda-async, and cuda-bindings at
this repository's git URL. With the local copies retired that either
resolves to nothing or to a stale copy on an old revision, so the
templates now take the crates.io release (SHARED_HOST_CRATES_VERSION)
and a test checks no git pin comes back. cuda-bindings leaves the
async template: nothing in it names cuda_bindings.

Book links that pointed at crates/cuda-core/{src,tests} now point at
the simt files in cutile-rs.

Signed-off-by: Nihal Pasham <nihalp@nvidia.com>

* retire the local host crates for real; CI, licensing, and docs follow the shared crates

The switch to the cutile-rs crates left the old crates/cuda-bindings,
crates/cuda-core, and crates/cuda-async on disk as standalone packages
"so the example workspaces keep building unchanged". Nothing built them:
every example already took the git pin, no CI lane tested them, and
their only effect was to make `cargo oxide new` resolve `cuda-core` from
this repository's git URL to a stale 0.2.1 copy. They are gone, together
with the dead `#[derive(DeviceCopy)]` in cuda-macros (cuda-core now
re-exports cuda-core-derive's), the three retired roots in the license
inventory guard, the CODEOWNERS rule for the moved crate, and the
comments that pointed at the old paths (root Cargo.toml, doctor.rs,
spine_kernel_ptx.rs, docs.yml).

The shared cuda-bindings loads libcuda at run time through libloading
instead of linking it, so the libcuda.so.1 stub shadowing in
unit-tests.yml, docs.yml, the Justfile, and CONTRIBUTING was dead
plumbing; it is removed and the `--exclude cuda-bindings` doctest
exclusions with it. bindgen now also reads curand.h, which the flake
provides and the docs name.

cutile_inter_kernel leaves the license-policy exemption (#953): its git
source is allowed and every cutile-rs crate is Apache-2.0, so it is
judged like every other example. dependency-licenses.csv describes the
crates as resolved (0.3.1 from cutile-rs) and gains cuda-core-derive and
dashmap rows.

Docs: the CUDA floor is 13.0 with an R580+ driver (README, installation,
building-from-source, example READMEs), the remaining root-path snippets
move to the simt paths, the `f16` feature is explained where it is
enabled, the cuda-host re-export of cuda_async says which surface is
which, and the docs.rs links for LaunchConfig point at the simt page.
Seven trybuild fixtures get the line-neutral formatting fixes the path
rewrite skipped.

Signed-off-by: Nihal Pasham <nihalp@nvidia.com>

* guards: host-API paths in docs and templates; shared host-crate pin parity

Two things the crate switch showed nothing was checking:

- Some forty book, README, and scaffold lines kept spelling the old root
  paths (cuda_core::LaunchConfig, cuda_async::device_operation::...),
  which on the shared crates either do not resolve or bind cutile's
  Tile-side types. No lane compiles those snippets.
  check-host-api-paths.sh greps them for the root spellings that are
  wrong on the shared crates; it fails on the pre-fix tree at 50 sites
  and passes now.

- The shared-crate release is named once in the root workspace and
  copied into 221 example manifests and the `cargo oxide new` templates.
  check-shared-crate-pin.sh requires every copy to agree with the root
  on version and form (git tag or crates.io), so the crates.io repin
  cannot leave a straggler and the scaffold cannot drift.

Both run in the status-guard workflow and in `just check-guards`.

Signed-off-by: Nihal Pasham <nihalp@nvidia.com>

* oxide-artifacts: consume the crates.io release everywhere; the in-tree crate is the publish source

The backend wrote artifact bundles with the in-tree crates/oxide-artifacts
(a path dependency) while the shared cuda-core from cutile-rs reads them
through crates.io oxide-artifacts 0.2.1. Same version, same code, but two
crates to rustc: the root lock carried both, and nothing tied the two
versions together. It worked only because just bytes cross the boundary.

The root workspace and the backend workspace now take oxide-artifacts
from crates.io like every other consumer, so writer and reader are one
crate. crates/oxide-artifacts stays a workspace member as the source the
release is published from; format changes go bump, publish, then move
the requirement and relock.

check-oxide-artifacts-parity.sh keeps the in-tree version, both manifest
requirements, and the version resolved in every lock equal, and fails if
any lock stops consuming the registry copy. It fails on a drifted in-tree
bump and passes on this tree. Runs in status-guard and just check-guards.

Validated on an RTX 5090: cargo-oxide, mir-importer, ptx-schedule and
backend lib tests, workspace clippy and fmt, all guards, and the full
smoketest (222/222) with the backend writing through the registry crate.

Signed-off-by: Nihal Pasham <nihalp@nvidia.com>

* deps: take the shared host crates from the crates.io 0.3.1 release

cutile-rs 0.3.1 is on crates.io (cuda-bindings, cuda-core-derive,
cuda-core, cuda-async, and the cutile stack), so the git-tag pin that
bridged the gap goes away:

- root workspace and all 224 example workspaces (nested ones included)
  name `"0.3.1"` from the registry; `features = ["f16"]` and the
  `package = "cuda-core"` rename in cutile_inter_kernel are kept, and
  cutile_inter_kernel's cutile / cutile-compiler pins move with them
- every Cargo.lock re-resolved with `cargo update -w`: 684 source lines
  flip from `git+...cutile-rs?tag=v0.3.1` to the registry plus a
  checksum each; no other package moves
- deny.toml drops the cutile-rs `allow-git` entry (pliron is the only
  git source left)
- dependency-licenses.csv: the four rows become "1st Party (crates.io)"
- async_mlp and async_vecadd drop their direct cuda-bindings dependency;
  neither names `cuda_bindings` anywhere
- comments in the two license guards and the cutile_inter_kernel README
  stop describing a git dependency

Provenance, checked before this commit: the published .crate archives
match the v0.3.1 tag tree (cdc69c1) file for file, and their sha256
matches both the crates.io index and the new lock checksums. The tag
moved from 9f68be2 (the previous pin) to cdc69c1 for the release; the
shared-crate delta is confined to the Tile-side `AsyncKernelLaunch`
argument storage in cuda-async plus workspace lint config. The
`cuda_async::simt` launch path cuda-oxide uses is unchanged.

Signed-off-by: nihalpasham <nihalp@nvidia.com>

---------

Signed-off-by: nihalp <nihalp@nvidia.com>
Signed-off-by: Melih Elibol <elibol@users.noreply.github.com>
Signed-off-by: Nihal Pasham <nihalp@nvidia.com>
Signed-off-by: nihalpasham <nihalp@nvidia.com>
Co-authored-by: nihalp <nihalp@nvidia.com>
meefs pushed a commit to meefs/cuda-oxide that referenced this pull request Sep 30, 2026
The shared host-side crates (cuda-bindings, cuda-core, cuda-async)
now require CUDA 13.0 or newer. MIN_CUDA_VERSION moves from 12080 to
13000, and every message and comment that stated the 12.8 floor
follows it. The Tile compiler's own floor (13.2, where tileiras
ships) is unchanged.

The CI floor lane moves from the 12.8.0 image to
nvidia/cuda:13.0.0-devel-ubuntu24.04, matching the 13.x lanes. The
job is renamed shared-crates-cuda13; it is not a required status
check, so nothing downstream keys on the old name.

The two notes recording that CUDA 12.8 renamed cuEventElapsedTime to
cuEventElapsedTime_v2 stay: they describe API history, not the floor.

Signed-off-by: Melih Elibol <elibol@users.noreply.github.com>
meefs pushed a commit to meefs/cuda-oxide that referenced this pull request Sep 30, 2026
…up to NVIDIA#233) (NVIDIA#251)

* feat(cuda-bindings): carry cuda-oxide's toolkit discovery and its tests

The build script accepted only a `{toolkit}/include/cuda.h` layout and
only the CUDA_TOOLKIT_PATH variable, so custom, Jetson/Grace, cross-build,
and `targets/<arch>` toolkit installs that build cuda-oxide today failed
during the shared-crate build.

Port cuda-oxide's lookup logic into the shared crate:

- CUDA_HOME is honored after CUDA_TOOLKIT_PATH, matching the discovery
  that cuda-core/build.rs already documents and implements.
- The redistributable `targets/<dir>/include/` layouts are probed via an
  arch+OS selection table (`toolkit_target.rs`): `x86_64-linux` for x86_64
  Linux, `sbsa-linux` then `aarch64-linux` for aarch64 Linux (a Rust
  aarch64 triple cannot distinguish Grace servers from Jetson/Tegra).
  Deliberately not a `targets/*` glob, so a multi-target install never
  hands the build another architecture's headers.
- CUDA_TOOLKIT_TARGET_DIR names one `targets/` tree by hand, like nvcc's
  `-target-dir`. When set, that tree is the only include candidate: the
  top-level `include/` (on standard installs a symlink to the host
  architecture's `targets/` tree) is not consulted, so a cross-build
  cannot silently bind the host's headers, and a wrong value fails with
  the discovery error listing the probed paths instead of silently
  falling back. This is stricter than cuda-oxide, where the top-level
  `include/` still shadowed the override on standard installs.
- bindgen and the header symbol probes use the resolved include directory
  rather than assuming the top-level layout.
- Discovery failures list every probed cuda.h path, and error messages
  name both environment variables.

The selection logic is shared verbatim with `tests/toolkit_target.rs` via
`include!`, carrying cuda-oxide's test suite extended to twelve cases:
table correctness, per-arch ownership, Tegra/sbsa/multi-target/standard
layout resolution, override semantics (sole candidate, beats top-level
include, blank means unset, wrong value fails), and non-Linux behavior.

The CUDA 12.8+ floor and the default candidate list are unchanged. The
crate and root READMEs now describe the discovery surface, including the
Windows default candidates.

Signed-off-by: nihalpasham <nihalp@nvidia.com>

* build(cuda-core): align the multicast header probe with cuda-bindings

The module doc claimed toolkit discovery "matches cuda-bindings", but the
default fallback did not: cuda-bindings probes the versioned candidates
(/usr/local/cuda-13.3 through /usr/local/cuda) with a CUDA 12.8 floor,
while this probe tried only /usr/local/cuda with no floor. On a
versioned-only install (no /usr/local/cuda symlink), or one whose symlink
points at a below-floor tree, the two build scripts resolved different
toolkits: cuda-bindings bound cuMulticast* from the versioned toolkit
while this probe read the wrong cuda.h (or none), leaving
cuda_has_multicast unset and silently compiling out the MulticastObject
surface.

Mirror cuda-bindings' resolution: the same default candidate lists
(including the Windows pair) with the same 12.8 floor, and the same
CUDA_TOOLKIT_TARGET_DIR semantics where a non-blank override names the
single targets/ tree to probe instead of extending the candidate list.
The probe stays silent on failure; cuda-bindings still reports the
authoritative error for a genuinely broken toolkit.

Signed-off-by: nihalpasham <nihalp@nvidia.com>

* test(scripts): execute the shared host-crate suites in the CPU and GPU paths

The copied cuda-oxide SIMT tests were compiled by `cargo test --no-run`
and the shared-crates-cuda12 `cargo check --all-targets` lane, but no
runnable entry point executed their assertions. Three pre-existing
cutile suites (borrow_raw, reactor_correctness, error_handling) also ran
nowhere.

CPU path (runs in the hosted "CPU only tests" lane):

- cuda-bindings: full suite minus the GPU-requiring `cuda_tests` module,
  covering the generated-shim unit tests, the fn-pointer C-ABI
  regression, and the toolkit-discovery tests.
- cuda-core: `--lib` unit tests, the three compile-time contract targets
  (the trybuild DeviceCopy derive suite with both compile-fail cases,
  DeviceCopy impl coverage, launch type contracts), and `--doc` for the
  compile_fail soundness contracts in the doc comments.
- cuda-async: `--lib` unit tests, `--doc`, and the driver-free
  error_handling integration test.

All of these pass with no usable driver: the dynamic-loader shims return
error codes instead of aborting, verified by running the set with an
unloadable libcuda shadowing the real one.

GPU path (run_gpu_tests.sh):

- the ten GPU-dependent cuda-core integration targets: borrow_raw and
  the nine SIMT suites, including simt_vmm_p2p (real two-GPU P2P mapping
  with data verification; self-skips without two devices or peer access)
  and simt_vmm_multicast (self-skips without NVLink switch multicast).
- reactor_correctness joins the cuda-async integration loop.
- cuda-async `--lib` and the unfiltered cuda-bindings suite, so the
  driver-facing unit tests also execute against a live driver.

Verified on a two-GPU RTX 5090 machine: both scripts pass end to end.
The cross-GPU P2P case self-skips there because GeForce boards do not
expose PCIe peer access, while the VMM roundtrip executes in full.

Signed-off-by: nihalpasham <nihalp@nvidia.com>

* build: raise the shared host-crate CUDA floor to 13.0

Encodes the CTK baseline agreed between the cuda-oxide and cutile
maintainers: the shared host-side crates (cuda-bindings, cuda-core,
cuda-async) require CUDA 13.0+, superseding the interim 12.8 floor. The
Tile compiler's 13.2+ requirement is unchanged.

- cuda-bindings: MIN_CUDA_VERSION 12080 -> 13000, /usr/local/cuda-12
  dropped from the default candidates, error messages updated.
- cuda-core: the multicast header probe mirrors the same floor and
  candidate list, keeping the two build scripts resolving one toolkit.
- The floor-honesty CI lane moves from the CUDA 12.8.0 container to
  13.0.1 (a 12.8 container would now be rejected by the build script)
  and is renamed shared-crates-cuda13.
- cutile-compiler's advisory warning and the cuda-bindings README state
  the new floor.

Verified on real toolkits: a CUDA 12.8 tree is rejected with the new
message, and /usr/local/cuda-13.0 resolves at the boundary.

Signed-off-by: nihalpasham <nihalp@nvidia.com>

---------

Signed-off-by: nihalpasham <nihalp@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

codegen Device code-generation pipeline (Rust MIR to IR to PTX) debug info Debug information in generated PTX/IR (line/source maps) enhancement New feature or request IR-lowering Lowering between dialects (dialect-mir to LLVM dialect) llvm-export Textual LLVM/NVVM IR exporter (llvm-export crate) tests Adds or improves test coverage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant