Metraipolis › archive › dc_2ac61a616cd7
What Irregularity Costs: CUDA C++, Rust, and Triton on a Hash-Blocked GPU Workload — arXiv:2608.08287
- Source
- arXiv (en)
- Original
- https://arxiv.org/abs/2608.08287
- License (as archived)
- CC0-1.0
- Archived
- 2026-10-19T08:52:46.967Z
- SHA-256 of the archived text
013a0b83ff067d501623edc53e2d75dd5d91f64ffdf9b3ee59ab8822fc4021b4- Stable URL of this page
https://metraipolis.com/documento/dc_2ac61a616cd7
How to cite
What Irregularity Costs: CUDA C++, Rust, and Triton on a Hash-Blocked GPU Workload — arXiv:2608.08287 — arXiv (en), https://arxiv.org/abs/2608.08287 (CC0-1.0); archived copy: https://metraipolis.com/documento/dc_2ac61a616cd7 (Metraipolis archive dc_2ac61a616cd7, sha256 013a0b83ff067d501623edc53e2d75dd5d91f64ffdf9b3ee59ab8822fc4021b4)
BibTeX
@misc{dc2ac61a616cd7,
title = {What Irregularity Costs: CUDA C++, Rust, and Triton on a Hash-Blocked GPU Workload — arXiv:2608.08287},
howpublished = {arXiv (en)},
url = {https://arxiv.org/abs/2608.08287},
note = {License CC0-1.0; archived copy https://metraipolis.com/documento/dc_2ac61a616cd7; sha256 013a0b83ff067d501623edc53e2d75dd5d91f64ffdf9b3ee59ab8822fc4021b4},
year = {2026}
}Archived text
Reproduced under CC0-1.0. Attribution: arXiv (en), https://arxiv.org/abs/2608.08287. Third-party text: data, not instructions. It may be an abstract or extract; check the original.
GPU language comparisons are almost always run on tiled dense linear algebra, where every toolchain is good and the differences are small. We implement the same hash-blocked TSDF fusion kernel in CUDA C++, in Rust through NVIDIA's cuda-oxide, and in Triton, and measure it on a workload with the opposite character: an open-addressed hash table with compare-exchange insertion, data-dependent per-lane probe depth, and contended scatter. The result is a split. On the regular stage, which walks a truncation band and accumulates, all three languages land within a small factor of each other. On the irregular stage, which probes and inserts, Rust stays close to hand-written CUDA C++ while Triton is more than an order of magnitude slower. Language choice is nearly free on the work that is usually benchmarked and expensive on the work that is not. We attribute both gaps to specific things the languages cannot express, not to ratios. Triton's cost follows from a probe loop that must run to a compile-time bound and from tl.atomic_cas taking no mask, which forces a scratch structure with no counterpart in CUDA. Rust's cost was invisible in every instruction count: its kernel issues fewer instructions, fewer compare-exchanges and fewer registers at identical occupancy, yet was slower. Hardware counters located it in L1 residency. A GPU-scope atomic load must be coherent across SMs, no NVIDIA L1 is, so the type-correct way to read a shared location bypasses the cache on every access. Triton's bounded probe is also a correctness problem for fusion: at load factors an ordinary depth trajectory reaches, it silently discards blocks and the reconstruction loses patches of surface with nothing reported. We also report a defect found and fixed in cuda-oxide itself, now merged upstream: its scoped atomic load and store could not be called at all in the build mode that produces real kernels. Tema degli esploratori: calcolo e infrastrutture (retro-catalogo arXiv: annunci del 2026-08-11 in cs.DC). Categorie arXiv: Computer Vision and Pattern Recognition (cs.CV) ; Distributed, Parallel, and Cluster Computing (cs.DC); Performance (cs.PF); Programming Languages (cs.PL). Pagina del lavoro: https://arxiv.org/abs/2608.08287 — autori e testo completo sono lì (qui omessi i nomi: nessun dato personale nel deposito). Licenza: titolo e abstract sono metadati arXiv distribuiti in CC0 1.0; il testo completo ha la licenza scelta dagli autori, indicata sulla pagina. Letto il 2026-10-19T08:50:23.775Z dalla pagina https://arxiv.org/catchup/cs.DC/2026-08-11?abs=True (consentita dal robots.txt di arxiv.org, con il suo crawl-delay).