PerfDojo: Automated ML Library Generation for Heterogeneous Architectures

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Ivanov, Andrei, Shen, Siyuan, Gottardo, Gioele, Chrapek, Marcin, Boudaoud, Afif, Schneider, Timo, Benini, Luca, Hoefler, Torsten
Format: Preprint
Veröffentlicht: 2025
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866908631256006656
author Ivanov, Andrei
Shen, Siyuan
Gottardo, Gioele
Chrapek, Marcin
Boudaoud, Afif
Schneider, Timo
Benini, Luca
Hoefler, Torsten
author_facet Ivanov, Andrei
Shen, Siyuan
Gottardo, Gioele
Chrapek, Marcin
Boudaoud, Afif
Schneider, Timo
Benini, Luca
Hoefler, Torsten
contents The increasing complexity of machine learning models and the proliferation of diverse hardware architectures (CPUs, GPUs, accelerators) make achieving optimal performance a significant challenge. Heterogeneity in instruction sets, specialized kernel requirements for different data types and model features (e.g., sparsity, quantization), and architecture-specific optimizations complicate performance tuning. Manual optimization is resource-intensive, while existing automatic approaches often rely on complex hardware-specific heuristics and uninterpretable intermediate representations, hindering performance portability. We introduce PerfLLM, a novel automatic optimization methodology leveraging Large Language Models (LLMs) and Reinforcement Learning (RL). Central to this is PerfDojo, an environment framing optimization as an RL game using a human-readable, mathematically-inspired code representation that guarantees semantic validity through transformations. This allows effective optimization without prior hardware knowledge, facilitating both human analysis and RL agent training. We demonstrate PerfLLM's ability to achieve significant performance gains across diverse CPU (x86, Arm, RISC-V) and GPU architectures.
format Preprint
id arxiv_https___arxiv_org_abs_2511_03586
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle PerfDojo: Automated ML Library Generation for Heterogeneous Architectures
Ivanov, Andrei
Shen, Siyuan
Gottardo, Gioele
Chrapek, Marcin
Boudaoud, Afif
Schneider, Timo
Benini, Luca
Hoefler, Torsten
Performance
Artificial Intelligence
The increasing complexity of machine learning models and the proliferation of diverse hardware architectures (CPUs, GPUs, accelerators) make achieving optimal performance a significant challenge. Heterogeneity in instruction sets, specialized kernel requirements for different data types and model features (e.g., sparsity, quantization), and architecture-specific optimizations complicate performance tuning. Manual optimization is resource-intensive, while existing automatic approaches often rely on complex hardware-specific heuristics and uninterpretable intermediate representations, hindering performance portability. We introduce PerfLLM, a novel automatic optimization methodology leveraging Large Language Models (LLMs) and Reinforcement Learning (RL). Central to this is PerfDojo, an environment framing optimization as an RL game using a human-readable, mathematically-inspired code representation that guarantees semantic validity through transformations. This allows effective optimization without prior hardware knowledge, facilitating both human analysis and RL agent training. We demonstrate PerfLLM's ability to achieve significant performance gains across diverse CPU (x86, Arm, RISC-V) and GPU architectures.
title PerfDojo: Automated ML Library Generation for Heterogeneous Architectures
topic Performance
Artificial Intelligence
url https://arxiv.org/abs/2511.03586