Hacker News front pageElizabeth Goodman11 min readintermediate
Nvidia announces native GPU programming in Rust
Summary
NVIDIA released CUDA‑Rust, letting you write GPU kernels directly in Rust and compile to PTX. Two programming models are supported: the traditional SIMT model via the `cuda-oxide` backend (nightly Rust, custom codegen) and the newer Tile model via `cutile‑rs` (stable Rust, JIT‑compiled Tile IR). Both provide Rust‑typed safety guarantees (e.g., `DisjointSlice`, tensor partitioning) and simple Carg…
- CUDA‑Rust enables native Rust kernels, removing the need for C++/Python wrappers.
- SIMT track (`cuda-oxide`) uses a custom rustc backend, requires nightly, LLVM, and explicit launch contracts for safety.
- Tile track (`cutile‑rs`) works on stable Rust, leverages CUDA Tile IR, and uses tensor partitioning to express exclusive mutable access.
- Safety is enforced via Rust types (`DisjointSlice`, `Tensor` partitions) and compile‑time launch contracts that validate grid dimensions against device limits.
Rust’s compile‑time guarantees can eliminate whole classes of GPU bugs (out‑of‑bounds, data races) while retaining performance. Native Rust kernels simplify the toolchain for teams already using Rust for drivers and AI infrastructure, and the Tile model abstracts away architecture‑specific launch p…
6/10



