cuTile Rust: A Safe, Tile-Based GPU Kernel Programming DSL for Rust
By
melihelibol
14h ago· 6 min readenCode
100/100
Golden Brown
Bagelometer↗
Baker's choice. Dense with flavour, light on filler.
Score100TypenewsSentimentpositive
Summary
cuTile Rust (cutile-rs) is a new tile-based GPU kernel programming DSL for Rust that extends Rust's ownership and borrowing rules across the GPU launch boundary. It provides memory-safe, data-race-free GPU kernel writing with features like safe host-side API for tensor passing, asynchronous execution, CUDA graph replay support, and JIT compilation via the #[cutile::module] macro. The system partitions mutable tensors into disjoint pieces before launch, allows immutable tensor sharing, and preserves ownership while GPU work is in flight.
Key quotes
· 3 pulledcuTile Rust (cutile-rs) is a tile-based system for writing memory-safe, data-race-free GPU kernels in idiomatic Rust.
It extends Rust's ownership discipline across the GPU launch boundary: mutable tensors are partitioned into disjoint pieces before launch, immutable tensors are shared, and generated launchers preserve ownership while GPU work is in flight.
The #[cutile::module] macro embeds a captured Rust AST for each kernel in the host binary; when a kernel is needed, cuTile Rust JIT-compiles the kernel.
cuTile Rust provides a safe, tile-based kernel programming DSL for the Rust programming language. It features a safe host-side API for passing tensors to asynchronously executed kernel functions. -...
