Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolve

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Chen, Hongzheng, Novikov, Alexander, Vũ, Ngân, Alam, Hanna, Zhang, Zhiru, Grossman, Aiden, Trofin, Mircea, Yazdanbakhsh, Amir
Format: Preprint
Publié: 2026
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866912857785892864
author Chen, Hongzheng
Novikov, Alexander
Vũ, Ngân
Alam, Hanna
Zhang, Zhiru
Grossman, Aiden
Trofin, Mircea
Yazdanbakhsh, Amir
author_facet Chen, Hongzheng
Novikov, Alexander
Vũ, Ngân
Alam, Hanna
Zhang, Zhiru
Grossman, Aiden
Trofin, Mircea
Yazdanbakhsh, Amir
contents Modern compilers rely on hand-crafted heuristics to guide optimization passes. These human-designed rules often struggle to adapt to the complexity of modern software and hardware and lead to high maintenance burden. To address this challenge, we present Magellan, an agentic framework that evolves the compiler pass itself by synthesizing executable C++ decision logic. Magellan couples an LLM coding agent with evolutionary search and autotuning in a closed loop of generation, evaluation on user-provided macro-benchmarks, and refinement, producing compact heuristics that integrate directly into existing compilers. Across several production optimization tasks, Magellan discovers policies that match or surpass expert baselines. In LLVM function inlining, Magellan synthesizes new heuristics that outperform decades of manual engineering for both binary-size reduction and end-to-end performance. In register allocation, it learns a concise priority rule for live-range processing that matches intricate human-designed policies on a large-scale workload. We also report preliminary results on XLA problems, demonstrating portability beyond LLVM with reduced engineering effort.
format Preprint
id arxiv_https___arxiv_org_abs_2601_21096
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolve
Chen, Hongzheng
Novikov, Alexander
Vũ, Ngân
Alam, Hanna
Zhang, Zhiru
Grossman, Aiden
Trofin, Mircea
Yazdanbakhsh, Amir
Artificial Intelligence
Machine Learning
Programming Languages
Modern compilers rely on hand-crafted heuristics to guide optimization passes. These human-designed rules often struggle to adapt to the complexity of modern software and hardware and lead to high maintenance burden. To address this challenge, we present Magellan, an agentic framework that evolves the compiler pass itself by synthesizing executable C++ decision logic. Magellan couples an LLM coding agent with evolutionary search and autotuning in a closed loop of generation, evaluation on user-provided macro-benchmarks, and refinement, producing compact heuristics that integrate directly into existing compilers. Across several production optimization tasks, Magellan discovers policies that match or surpass expert baselines. In LLVM function inlining, Magellan synthesizes new heuristics that outperform decades of manual engineering for both binary-size reduction and end-to-end performance. In register allocation, it learns a concise priority rule for live-range processing that matches intricate human-designed policies on a large-scale workload. We also report preliminary results on XLA problems, demonstrating portability beyond LLVM with reduced engineering effort.
title Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolve
topic Artificial Intelligence
Machine Learning
Programming Languages
url https://arxiv.org/abs/2601.21096