Can Coding Agents Implement Missed Compiler Optimizations? Evaluating LLM Agents on LLVM Peephole Optimizations
On the map: LLM agents and tool use → Software engineering coding agents
Abstract (arXiv)
Coding agents built on large language models are now capable of patching sizable real-world codebases, yet whether they can develop compiler optimizations remains an open question. To study this question, we introduce PeepholeBench, an evaluation framework whose tasks are constructed from real-world missed peephole optimizations reported against LLVM's InstCombine pass. Since missed peephole optimizations are typically fixed with small, localized patches, they offer a well-scoped but demanding testbed for coding agents: a correct fix demands rigorous reasoning about program semantics along with familiarity with optimizer-specific conventions. PeepholeBench derives its tasks from 21 resolved LLVM issues and 19 merged pull requests (PRs), supplies agents with only the issue context that existed before each fix, and assesses the resulting patches for both correctness and profitability. With PeepholeBench, we benchmark state-of-the-art coding agents on fixing missed peephole optimizations in LLVM's InstCombine pass, measuring their patches against the corresponding human-written fixes. We observe a tension between correctness and profitability, and no agent matches human developers on both dimensions at once. The dominant failure modes are overly narrow transformations and misuse of LLVM-specific mechanisms, errors that existing test suites rarely expose. Together, these results establish PeepholeBench as a realistic and challenging benchmark for coding agents, and suggest future directions for building agents that can more dependably assist compiler optimization development.
Key facts. No citing papers in the map yet (data through 14 Oct 2026). Placed in Software engineering coding agents, one of 16 directions in LLM agents and tool use. Builds on 18 of its 45 references that are in the map. First posted on arXiv 2 Jul 2026.
Builds on
18 of 45 references.
Closest ancestors · 4
Same direction, newest first
- 2026Agentic Harness for Real-World Compilers20 Mar
- 2026FeatureBench: Benchmarking Agentic Coding for Complex Feature Development11 Feb
- 2024OpenHands: An Open Platform for AI Software Developers as Generalist Agents23 Jul
- 2024SWE-agent: Agent-Computer Interfaces Enable Automated Software Engineering6 May
Other references · 14
- 2021Evaluating Large Language Models Trained on Codecited by 8,320
- 2023SWE-bench: Can Language Models Resolve Real-World GitHub Issues?cited by 3,373
- 2026Terminal-Bench: Benchmarking Agents on Hard, Realistic Tasks in Command Line Interfacescited by 585
- 2024AutoCodeRover: Autonomous Program Improvementcited by 278
- 2025SWE-Lancer: Can Frontier LLMs Earn 1 Million from Real-World Freelance Software Engineering?cited by 105
- 2023LLM-in-the-loop: Leveraging Large Language Model for Thematic Analysiscited by 70
- 2023Large Language Models for Compiler Optimizationcited by 52
- 2024Search-Based LLMs for Code Optimizationcited by 28
- 2023RAPGen: An Approach for Fixing Code Inefficiencies in Zero-Shotcited by 14
- 2017Souper: A Synthesizing Superoptimizercited by 12
- 2024Finding Missed Code Size Optimizations in Compilers using LLMscited by 5
- 2025LPO: Discovering Missed Peephole Optimizations with Large Language Modelscited by 4
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Understanding Agent-Based Patching of Compiler Missed Optimizations
- 2026Archer: Towards Agentic Review for Compiler Optimizations
- 2025Agentic Auto-Scheduling: An Experimental Study of LLM-Guided Loop Optimization
- 2025AwareCompiler: Agentic Context-Aware Compiler Optimization via a Synergistic Knowledge-Data Driven Framework
- 2026EffiSkill: Agent Skill Based Automated Code Efficiency Optimization
- 2026PERFOPT-Bench: Evaluating Coding Agents on Software Performance Optimization
- 2025CodeARC: Benchmarking Reasoning Capabilities of LLM Agents for Inductive Program Synthesis
- 2026VeRO: A Harness for Agents to Optimize Agents