Meta Large Language Model Compiler: Foundation Models of Compiler Optimization

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Cummins, Chris, Seeker, Volker, Grubisic, Dejan, Roziere, Baptiste, Gehring, Jonas, Synnaeve, Gabriel, Leather, Hugh
Format: Preprint
Published: 2024
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866917711508930560
author Cummins, Chris
Seeker, Volker
Grubisic, Dejan
Roziere, Baptiste
Gehring, Jonas
Synnaeve, Gabriel
Leather, Hugh
author_facet Cummins, Chris
Seeker, Volker
Grubisic, Dejan
Roziere, Baptiste
Gehring, Jonas
Synnaeve, Gabriel
Leather, Hugh
contents Large Language Models (LLMs) have demonstrated remarkable capabilities across a variety of software engineering and coding tasks. However, their application in the domain of code and compiler optimization remains underexplored. Training LLMs is resource-intensive, requiring substantial GPU hours and extensive data collection, which can be prohibitive. To address this gap, we introduce Meta Large Language Model Compiler (LLM Compiler), a suite of robust, openly available, pre-trained models specifically designed for code optimization tasks. Built on the foundation of Code Llama, LLM Compiler enhances the understanding of compiler intermediate representations (IRs), assembly language, and optimization techniques. The model has been trained on a vast corpus of 546 billion tokens of LLVM-IR and assembly code and has undergone instruction fine-tuning to interpret compiler behavior. LLM Compiler is released under a bespoke commercial license to allow wide reuse and is available in two sizes: 7 billion and 13 billion parameters. We also present fine-tuned versions of the model, demonstrating its enhanced capabilities in optimizing code size and disassembling from x86_64 and ARM assembly back into LLVM-IR. These achieve 77% of the optimising potential of an autotuning search, and 45% disassembly round trip (14% exact match). This release aims to provide a scalable, cost-effective foundation for further research and development in compiler optimization by both academic researchers and industry practitioners.
format Preprint
id arxiv_https___arxiv_org_abs_2407_02524
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Meta Large Language Model Compiler: Foundation Models of Compiler Optimization
Cummins, Chris
Seeker, Volker
Grubisic, Dejan
Roziere, Baptiste
Gehring, Jonas
Synnaeve, Gabriel
Leather, Hugh
Programming Languages
Artificial Intelligence
Large Language Models (LLMs) have demonstrated remarkable capabilities across a variety of software engineering and coding tasks. However, their application in the domain of code and compiler optimization remains underexplored. Training LLMs is resource-intensive, requiring substantial GPU hours and extensive data collection, which can be prohibitive. To address this gap, we introduce Meta Large Language Model Compiler (LLM Compiler), a suite of robust, openly available, pre-trained models specifically designed for code optimization tasks. Built on the foundation of Code Llama, LLM Compiler enhances the understanding of compiler intermediate representations (IRs), assembly language, and optimization techniques. The model has been trained on a vast corpus of 546 billion tokens of LLVM-IR and assembly code and has undergone instruction fine-tuning to interpret compiler behavior. LLM Compiler is released under a bespoke commercial license to allow wide reuse and is available in two sizes: 7 billion and 13 billion parameters. We also present fine-tuned versions of the model, demonstrating its enhanced capabilities in optimizing code size and disassembling from x86_64 and ARM assembly back into LLVM-IR. These achieve 77% of the optimising potential of an autotuning search, and 45% disassembly round trip (14% exact match). This release aims to provide a scalable, cost-effective foundation for further research and development in compiler optimization by both academic researchers and industry practitioners.
title Meta Large Language Model Compiler: Foundation Models of Compiler Optimization
topic Programming Languages
Artificial Intelligence
url https://arxiv.org/abs/2407.02524