CUDA-Harness: Harnessing Agentic CUDA Kernel Generation and Optimization from Natural Language
- Source
- arxiv.org
- Author
- Qi Fan, An Zou, Yehan Ma
- Date

Context
CUDA-Harness separates understanding a requested GPU calculation from writing and testing its implementation. It first produces a structured specification of inputs, outputs and operations, then generates the CUDA kernel, the code that performs the parallel computation.
Its test generator works in a separate from the code generator, which is intended to stop tests from being tailored to whatever the implementation happens to do. Validation then guides repairs before speed optimization. The separation has a limit the authors document: when the request itself is misread, the misreading can carry into both the kernel and its synthesized tests. misinterpretation accounts for 38.1% of the cases where the synthesized tests passed but the ’s own check failed.
- Harness — The software that sends a model its context, recognizes tool calls, runs or refuses them, returns results and keeps the record.
- Context and context window — Context is the information available for a generation; the context window is the capacity available to hold it.
- Prompt — Information or instructions supplied to a model; in a chat, the request you type is often called your prompt.
- Benchmark — A fixed set of tasks with a stated way of scoring them, used to compare models or setups.
articleHarness Engineering in LLM Tool Use via Agent-Native Reusable Tool PrimitivesHaibo Jin, Suijin Wang, Xucheng Yu, Haojing Luo, Haohan Wang
articleBeyond the Model: Demystifying Harness Effects in Software Engineering AgentsHaichuan Hu, Quanjun Zhang, Shengcheng Yu, Zhifei Chen, Tianyu Luo, Chunrong Fang, Zhenyu Chen, Liang Xiao
articleRealisticTritonBench: A Benchmark for Triton-Kernel Generation in Real-World AI FrameworksJinjun Huang, Zhongzhen Wen, Tongtong Xu, Meng Yan, Xin Xia, Zhongxin Liu