HPCAgent-Bench: A Framework for Sound Benchmarking of Code-Optimizing Agents, Harnesses, and Skills
- Source
- arxiv.org
- Author
- Yakup Koray Budanaz, Lorenzo Paleari, Marcin Copik, Alexandru Calotoiu, Timo Schneider, Benjamin Chen Ming Choong, Shriram Chandran, Lars Hulsbergen, Levi Widmer, Torsten Hoefler
- Date

Context
When someone adds a , a tool or a different harness to a and the agent produces faster code, it is hard to tell whether the addition caused the gain. A new benchmark from researchers at ETH Zurich and A*STAR, HPCAgent-Bench, is built to answer that question for performance optimization (arxiv.org). It contains 689 kernels, the small compute-heavy routines that dominate run time in scientific and machine-learning code, drawn from loop-optimization challenges, real HPC applications and ML models. Each kernel is specified once in NumPy, and agents can submit C, Fortran or Python versions that run on CPUs or GPUs, on one machine or several.
Two design choices matter most for the result. First, grading happens outside the agent's reach: an external judge checks correctness on hidden, randomly generated inputs and does the timing itself, so an agent cannot hard-code answers or report its own speed, and a speedup only counts when it is statistically significant. Second, every intervention is measured in paired runs, with the same agent run on the same kernels with and without the addition, comparing success rate, speedup and token cost. The experiments used three models, Qwen3.8-27B, Kimi-K2.7 and OSS-120B, with Claude Code as the default harness.
Measured that way, most additions changed what the agent spent far more than what it achieved. Across 40 matched setups, interventions significantly changed speedup only twice, while token cost moved by up to 3.0x (arxiv.org). Swapping harnesses did not change speedup in the harness comparison, though some harnesses cut billed tokens, and the optimization-specific add-ons tested shifted how tokens were spent while their speedups stayed within noise. The authors add that cost claims depend on how input, cached-input and output tokens are weighted, which alone could change a cost effect up to threefold, so they publish their weights and every token count. The agents did produce real gains, up to 4.2x over automatic parallelizers, but the paper's point is that an added component has to show its value in a controlled comparison like this, not in a single impressive run.
- Each kernel is specified once in NumPy, with C and Fortran references derived from it. Submissions come through a common C ABI or Python interface and run on CPUs or GPUs, single or multi-node.
- The 689 kernels span three tracks: loop-level optimization challenges, kernels extracted from HPC codes, and machine-learning models.
- The authors report agents reaching up to 4.2x speedup over automatic parallelizers, and 93 to 99% of answers without device-specific code stayed correct on another machine, with speedup rank correlation of at least 0.84.
- Across 40 matched setups, adding interventions such as tools significantly changed speedup only twice but changed token cost by up to 3.0x.
- Because the weights given to input, cached-input and output tokens decide whether a saving counts as significant, the authors their weights and release every token count.
- agent skill — A reusable instruction file that teaches an agent how to do one job well — the procedure, the tools, and what counts as done.
- Agent mode — A mode in which one agent can inspect, edit, run commands, and iterate toward an outcome.
- Open weights — A model whose learned parameter values have been made available to download, under terms the publisher sets.
- State — Information describing a system at a particular moment, such as its current text, settings or saved records.
articleKernelArc: A Multi-Agent Framework for GPU Kernel OptimizationJoyjit Kundu, Ben Stoffelen, Kaili Wang, Peter Vrancx, Ludovic Denoyer
articleHow Do Coding Agents Optimize Software and Report Performance Validation? A Large-Scale Empirical Study of Open-Source Pull RequestsHuiyun Peng, Ricardo Calvo, Kelechi G. Kalu, James C. Davis
articleSlackBench: Benchmarking Agents on Collaborative Projects Grounded in Real Code RepositoriesMingxuan Li, Huanzhi Mao, Ruitao Zheng, Jarod Stanbury James, Yunze Li, Natanya Anderson, Joseph E. Gonzalez, Alex Dimakis