Kuiper: Correct and Efficient GPU Programming with Dependent Types and Separation Logic
Guido Martínez, Bastian Köpcke, Jonás Fiala, Gabriel Ebner, Tahina Ramananandro, Michel Steuwer, Tyler Sorensen, Nikhil Swamy
Abstract
We introduce Kuiper, a language for safe and verified efficient CPU/GPU programming embedded as an extensible library within the F * dependently typed language. We rely on F * 's support for dependent types and its associated Pulse concurrent separation logic to develop a program logic in which to prove CPU/GPU programs safe, data-race free, and functionally correct. Our model of the GPU includes several intricacies, including the memory hierarchy, kernel launches, and synchronization within a single comprehensive framework. To do so, we extend the Pulse program logic with a novel notion of located resources and a new connective to structure reasoning about massively parallel programs, and present new proof rules to lift the per-thread view of GPU kernels to an end-to-end correctness specification.
We have used Kuiper to program and prove correct a variety of GPU kernels, including full functional correctness proofs of an optimized matrix multiplication using two levels of block tiling and tensor cores. In doing so, we have developed a range of libraries to enable programs and proofs at a high level of abstraction but without imposing any runtime overhead. These allow Kuiper programs to be polymorphic (over types, operations, memory layout, and more) and compile to efficient, specialized CUDA code, while enabling a novel form of verified auto-tuning. Our experimental evaluation confirms that Kuiper programs match the performance of their handwritten CUDA counterparts and are competitive with closed source, state-of-the-art kernels in cuBLAS.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 96903728-0578-4604-8fb7-4ff117848cbeBuilds on8
- PyTorch 2: Faster Machine Learning Through Dynamic Python Bytecode Transformation and Graph CompilationJason Ansel, Edward Z. Yang, Horace He, Natalia Gimelshein et al.ASPLOS 2024 · 693 citations
- Specifying and testing GPU workgroup progress modelsTyler Sorensen, Lucas F. Salvador, Harmit Raval, Hugues Evrard et al.OOPSLA 2021 · 11 citations
- Sound and Partially-Complete Static Analysis of Data-Races in GPU ProgramsDennis Liew, Tiago Cogumbreiro, Julien LangeOOPSLA 2024 · 10 citations
- PulseCore: An Impredicative Concurrent Separation Logic for Dependently Typed ProgramsGabriel Ebner, Guido Martínez, Aseem Rastogi, Thibault Dardinier et al.PLDI 2025 · 8 citations
- Descend: A Safe GPU Systems Programming LanguageBastian Köpcke, Sergei Gorlatch, Michel SteuwerPLDI 2024 · 7 citations
Related papers
- Modeling and analyzing evaluation cost of CUDA kernelsStefan K. Muller, Jan HoffmannPOPL 2021 · 15 citations
- Modular GPU Programming with Typed PerspectivesManya Bansal, Daniel Sainati, Joseph W. Cutler, Saman P. Amarasinghe et al.PLDI 2026
- Checking Data-Race Freedom of GPU Kernels, CompositionallyTiago Cogumbreiro, Julien Lange, Dennis Liew Zhen Rong, Hannah ZicarelliCAV 2021 · 17 citations
- Task-Based Tensor Computations on Modern GPUsRohan Yadav, Michael Garland, Alex Aiken, Michael BauerPLDI 2025 · 5 citations
- Equivalence Checking of ML GPU KernelsBenjamin Driscoll, Kshitij Dubey, Anjiang Wei, Neeraj Kayal et al.OOPSLA 2026 · 1 citation
