CompilerGym: Robust, Performant Compiler Optimization Environments for AI Research
Not on the map. Why?
Abstract (arXiv)
Interest in applying Artificial Intelligence (AI) techniques to compiler optimizations is increasing rapidly, but compiler research has a high entry barrier. Unlike in other domains, compiler and AI researchers do not have access to the datasets and frameworks that enable fast iteration and development of ideas, and getting started requires a significant engineering investment. What is needed is an easy, reusable experimental infrastructure for real world compiler optimization tasks that can serve as a common benchmark for comparing techniques, and as a platform to accelerate progress in the field. We introduce CompilerGym, a set of environments for real world compiler optimization tasks, and a toolkit for exposing new optimization tasks to compiler researchers. CompilerGym enables anyone to experiment on production compiler optimization problems through an easy-to-use package, regardless of their experience with compilers. We build upon the popular OpenAI Gym interface enabling researchers to interact with compilers using Python and a familiar API. We describe the CompilerGym architecture and implementation, characterize the optimization spaces and computational efficiencies of three included compiler environments, and provide extensive empirical evaluations. Compared to prior works, CompilerGym offers larger datasets and optimization spaces, is 27x more computationally efficient, is fault-tolerant, and capable of detecting reproducibility bugs in the underlying compilers. In making it easy for anyone to experiment with compilers - irrespective of their background - we aim to accelerate progress in the AI and compiler research domains.
Key facts. Cited by 41 papers in the map (data through 7 Oct 2026). Builds on 26 of its 59 references that are in the map. First posted on arXiv 17 Sep 2021.
Builds on
26 of 59 references.
References · 26
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,160
- 2017Proximal Policy Optimization Algorithmscited by 14,441
- 2016Asynchronous Methods for Deep Reinforcement Learningcited by 2,218
- 2019Can You Trust Your Model's Uncertainty? Evaluating Predictive Uncertainty Under Dataset Shiftcited by 1,274
- 2018IMPALA: Scalable Distributed Deep-RL with Importance Weighted Actor-Learner Architecturescited by 866
- 2015Gated Graph Sequence Neural Networkscited by 792
- 2016Reinforcement Learning with Unsupervised Auxiliary Taskscited by 400
- 2018Quantifying Generalization in Reinforcement Learningcited by 345
- 2018Distributed Prioritized Experience Replaycited by 260
- 2017A Survey of Machine Learning for Big Code and Naturalnesscited by 220
- 2020Ansor: Generating High-Performance Tensor Programs for Deep Learningcited by 199
- 2020Learning Search Space Partition for Black-box Optimization using Monte Carlo Tree Searchcited by 87
14 more
- 2020Improving Generalization in Reinforcement Learning with Mixture Regularizationcited by 81
- 2018Neural Code Comprehension: A Learnable Representation of Code Semanticscited by 59
- 2019A Geometric Perspective on Optimal Representations for Reinforcement Learningcited by 54
- 2018Ithemal: Accurate, Portable and Fast Basic Block Throughput Estimation using Deep Neural Networkscited by 43
- 2018A Survey on Compiler Autotuning using Machine Learningcited by 40
- 2021MLGO: a Machine Learning Guided Compiler Optimizations Frameworkcited by 40
- 2019NeuroVectorizer: End-to-End Vectorization with Deep Reinforcement Learningcited by 37
- 2020AutoPhase: Juggling HLS Phase Orderings in Random Forests with Deep Reinforcement Learningcited by 24
- 2020Static Neural Compiler Optimization via Deep Reinforcement Learningcited by 14
- 2021A Reinforcement Learning Environment for Polyhedral Optimizationscited by 5
- 2020A Collaborative Filtering Approach for the Automatic Tuning of Compiler Optimisationscited by 4
- 2021Learning to Make Compiler Optimizations More Effectivecited by 4
- 2021LS-CAT: A Large-Scale CUDA AutoTuning Datasetcited by 3
- 2014Collective Tuning Initiativecited by 2
Built on by
Citing papers per year: 2021: 1; 2022: 5; 2023: 10; 2024: 5; 2025: 8; 2026: 12.
41 papers.
Sort:
By area:
- 2023Large Language Models for Compiler Optimizationcited by 52
- 2024Meta Large Language Model Compiler: Foundation Models of Compiler Optimizationcited by 39
- 2023TpuGraphs: A Performance Prediction Dataset on Large Tensor Computational Graphscited by 16
- 2025Autocomp: A Powerful and Portable Code Optimizer for Tensor Acceleratorscited by 12
- 2023Learning Compiler Pass Orders using Coreset and Normalized Value Predictioncited by 11
- 2022MLGOPerf: An ML Guided Inliner to Optimize Performancecited by 9
- 2025Compiler-R1: Towards Agentic Compiler Auto-tuning with Reinforcement Learningcited by 7
- 2023ArchGym: An Open-Source Gymnasium for Machine Learning Assisted Architecture Designcited by 6
- 2024CompilerDream: Learning a Compiler World Model for General Code Optimizationcited by 6
- 2022Transfer-Tuning: Reusing Auto-Schedules for Efficient Tensor Program Code Generationcited by 5
- 2022Reinforcement Learning in Practice: Opportunities and Challengescited by 5
- 2023qgym: A Gym for Training and Benchmarking RL-Based Quantum Compilationcited by 5
29 more
- 2026Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolvecited by 5
- 2022RL4ReAl: Reinforcement Learning for Register Allocationcited by 4
- 2025AwareCompiler: Agentic Context-Aware Compiler Optimization via a Synergistic Knowledge-Data Driven Frameworkcited by 4
- 2023PERFOGRAPH: A Numerical Aware Program Graph Representation for Performance Optimization and Program Analysiscited by 3
- 2024A Reinforcement Learning Environment for Automatic Code Optimization in the MLIR Compilercited by 3
- 2026Agentic Harness for Real-World Compilerscited by 3
- 2021Profile Guided Optimization without Profiles: A Machine Learning Approachcited by 2
- 2022BenchPress: A Deep Active Benchmark Generatorcited by 2
- 2024CATBench: A Compiler Autotuning Benchmarking Suite for Black-box Optimizationcited by 2
- 2023Target-independent XLA optimization using Reinforcement Learningcited by 1
- 2023LoopTune: Optimizing Tensor Computations with Reinforcement Learningcited by 1
- 2025DiTOX: Fault Detection and Localization in the ONNX Optimizercited by 1
- 2026Protean Compiler: An Agile Framework to Drive Fine-grain Phase Orderingcited by 1
- 2026Record-Remix-Replay: Hierarchical GPU Kernel Optimization using Evolutionary Searchcited by 1
- 2026PassNet: Scaling Large Language Models for Graph Compiler Pass Generationcited by 1
- 2026AutoPass: Evidence-Guided LLM Agents for Compiler Performance Tuningcited by 1
- 2023BenchDirect: A Directed Language Model for Compiler Benchmarkscited by 0
- 2023The Next 700 ML-Enabled Compiler Optimizationscited by 0
- 2024A Research Agenda for Usability and Generalisation in Reinforcement Learningcited by 0
- 2025Behavioral Embeddings of Programs: A Quasi-Dynamic Approach for Optimization Predictioncited by 0
- 2025GraphNet: A Large-Scale Computational Graph Dataset for Tensor Compiler Researchcited by 0
- 2025PerfDojo: Automated ML Library Generation for Heterogeneous Architecturescited by 0
- 2025A Deep Learning Model for Predicting Transformation Legalitycited by 0
- 2026The New Compiler Stack: A Survey on the Synergy of LLMs and Compilerscited by 0
- 2026ParEVO: Synthesizing Code for Irregular Data: High-Performance Parallelism through Agentic Evolutioncited by 0
- 2026From Pixels to Digital Agents: An Empirical Study on the Taxonomy and Technological Trends of Reinforcement Learning Environmentscited by 0
- 2026Can Large Language Models Recover Semantic Optimization Opportunities That Compilers Miss?cited by 0
- 2026Self-Evolving Coding Agents: From Digital Programs to Physical-World Intelligencecited by 0
- 2026AI as a Compiler: Compiling Triton kernels without the Triton compilercited by 0
- 2026AI as a Compiler: Compiling Triton kernels without the Triton compiler29 Sep 2026
- 2026Self-Evolving Coding Agents: From Digital Programs to Physical-World Intelligence28 Sep 2026
- 2026Can Large Language Models Recover Semantic Optimization Opportunities That Compilers Miss?4 Aug 2026
- 2026AutoPass: Evidence-Guided LLM Agents for Compiler Performance Tuning18 Jun 2026
- 2026PassNet: Scaling Large Language Models for Graph Compiler Pass Generation28 May 2026
- 2026Record-Remix-Replay: Hierarchical GPU Kernel Optimization using Evolutionary Search13 Apr 2026
- 2026From Pixels to Digital Agents: An Empirical Study on the Taxonomy and Technological Trends of Reinforcement Learning Environments25 Mar 2026
- 2026Agentic Harness for Real-World Compilers20 Mar 2026
- 2026ParEVO: Synthesizing Code for Irregular Data: High-Performance Parallelism through Agentic Evolution3 Mar 2026
- 2026Protean Compiler: An Agile Framework to Drive Fine-grain Phase Ordering5 Feb 2026
- 2026Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolve28 Jan 2026
- 2026The New Compiler Stack: A Survey on the Synergy of LLMs and Compilers5 Jan 2026
29 more
- 2025A Deep Learning Model for Predicting Transformation Legality8 Nov 2025
- 2025PerfDojo: Automated ML Library Generation for Heterogeneous Architectures5 Nov 2025
- 2025GraphNet: A Large-Scale Computational Graph Dataset for Tensor Compiler Research28 Oct 2025
- 2025Behavioral Embeddings of Programs: A Quasi-Dynamic Approach for Optimization Prediction15 Oct 2025
- 2025AwareCompiler: Agentic Context-Aware Compiler Optimization via a Synergistic Knowledge-Data Driven Framework13 Oct 2025
- 2025Compiler-R1: Towards Agentic Compiler Auto-tuning with Reinforcement Learning30 May 2025
- 2025Autocomp: A Powerful and Portable Code Optimizer for Tensor Accelerators24 May 2025
- 2025DiTOX: Fault Detection and Localization in the ONNX Optimizer3 May 2025
- 2024A Research Agenda for Usability and Generalisation in Reinforcement Learning22 Dec 2024
- 2024A Reinforcement Learning Environment for Automatic Code Optimization in the MLIR Compiler17 Sep 2024
- 2024Meta Large Language Model Compiler: Foundation Models of Compiler Optimization27 Jun 2024
- 2024CATBench: A Compiler Autotuning Benchmarking Suite for Black-box Optimization24 Jun 2024
- 2024CompilerDream: Learning a Compiler World Model for General Code Optimization24 Apr 2024
- 2023The Next 700 ML-Enabled Compiler Optimizations17 Nov 2023
- 2023Large Language Models for Compiler Optimization11 Sep 2023
- 2023LoopTune: Optimizing Tensor Computations with Reinforcement Learning4 Sep 2023
- 2023Target-independent XLA optimization using Reinforcement Learning28 Aug 2023
- 2023TpuGraphs: A Performance Prediction Dataset on Large Tensor Computational Graphs25 Aug 2023
- 2023qgym: A Gym for Training and Benchmarking RL-Based Quantum Compilation1 Aug 2023
- 2023ArchGym: An Open-Source Gymnasium for Machine Learning Assisted Architecture Design15 Jun 2023
- 2023PERFOGRAPH: A Numerical Aware Program Graph Representation for Performance Optimization and Program Analysis31 May 2023
- 2023BenchDirect: A Directed Language Model for Compiler Benchmarks2 Mar 2023
- 2023Learning Compiler Pass Orders using Coreset and Normalized Value Prediction9 Jan 2023
- 2022BenchPress: A Deep Active Benchmark Generator13 Aug 2022
- 2022MLGOPerf: An ML Guided Inliner to Optimize Performance18 Jul 2022
- 2022RL4ReAl: Reinforcement Learning for Register Allocation5 Apr 2022
- 2022Reinforcement Learning in Practice: Opportunities and Challenges23 Feb 2022
- 2022Transfer-Tuning: Reusing Auto-Schedules for Efficient Tensor Program Code Generation14 Jan 2022
- 2021Profile Guided Optimization without Profiles: A Machine Learning Approach24 Dec 2021
- 2025Compiler-R1: Towards Agentic Compiler Auto-tuning with Reinforcement Learningcited by 7
- 2025AwareCompiler: Agentic Context-Aware Compiler Optimization via a Synergistic Knowledge-Data Driven Frameworkcited by 4
- 2026Agentic Harness for Real-World Compilerscited by 3
- 2026AutoPass: Evidence-Guided LLM Agents for Compiler Performance Tuningcited by 1
- 2026ParEVO: Synthesizing Code for Irregular Data: High-Performance Parallelism through Agentic Evolutioncited by 0
- 2026From Pixels to Digital Agents: An Empirical Study on the Taxonomy and Technological Trends of Reinforcement Learning Environmentscited by 0
- 2026AutoPass: Evidence-Guided LLM Agents for Compiler Performance Tuning18 Jun 2026
- 2026From Pixels to Digital Agents: An Empirical Study on the Taxonomy and Technological Trends of Reinforcement Learning Environments25 Mar 2026
- 2026Agentic Harness for Real-World Compilers20 Mar 2026
- 2026ParEVO: Synthesizing Code for Irregular Data: High-Performance Parallelism through Agentic Evolution3 Mar 2026
- 2025AwareCompiler: Agentic Context-Aware Compiler Optimization via a Synergistic Knowledge-Data Driven Framework13 Oct 2025
- 2025Compiler-R1: Towards Agentic Compiler Auto-tuning with Reinforcement Learning30 May 2025
- 2023Large Language Models for Compiler Optimizationcited by 52
- 2024Meta Large Language Model Compiler: Foundation Models of Compiler Optimizationcited by 39
- 2023TpuGraphs: A Performance Prediction Dataset on Large Tensor Computational Graphscited by 16
- 2025Autocomp: A Powerful and Portable Code Optimizer for Tensor Acceleratorscited by 12
- 2023Learning Compiler Pass Orders using Coreset and Normalized Value Predictioncited by 11
- 2022MLGOPerf: An ML Guided Inliner to Optimize Performancecited by 9
- 2023ArchGym: An Open-Source Gymnasium for Machine Learning Assisted Architecture Designcited by 6
- 2022Transfer-Tuning: Reusing Auto-Schedules for Efficient Tensor Program Code Generationcited by 5
- 2022Reinforcement Learning in Practice: Opportunities and Challengescited by 5
- 2023qgym: A Gym for Training and Benchmarking RL-Based Quantum Compilationcited by 5
- 2026Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolvecited by 5
- 2022RL4ReAl: Reinforcement Learning for Register Allocationcited by 4
12 most cited of 33 All 33 (JSON)
- 2026AI as a Compiler: Compiling Triton kernels without the Triton compiler29 Sep 2026
- 2026Can Large Language Models Recover Semantic Optimization Opportunities That Compilers Miss?4 Aug 2026
- 2026PassNet: Scaling Large Language Models for Graph Compiler Pass Generation28 May 2026
- 2026Record-Remix-Replay: Hierarchical GPU Kernel Optimization using Evolutionary Search13 Apr 2026
- 2026Protean Compiler: An Agile Framework to Drive Fine-grain Phase Ordering5 Feb 2026
- 2026Magellan: Autonomous Discovery of Novel Compiler Optimization Heuristics with AlphaEvolve28 Jan 2026
- 2026The New Compiler Stack: A Survey on the Synergy of LLMs and Compilers5 Jan 2026
- 2025A Deep Learning Model for Predicting Transformation Legality8 Nov 2025
- 2025PerfDojo: Automated ML Library Generation for Heterogeneous Architectures5 Nov 2025
- 2025GraphNet: A Large-Scale Computational Graph Dataset for Tensor Compiler Research28 Oct 2025
- 2025Behavioral Embeddings of Programs: A Quasi-Dynamic Approach for Optimization Prediction15 Oct 2025
- 2025Autocomp: A Powerful and Portable Code Optimizer for Tensor Accelerators24 May 2025
12 newest of 33 All 33 (JSON)