Beyond Scaling: Self-Evolving LLM Agents for Hardware Kernel Optimization via an Experience-Driven Workflow and Experience Graph Memory
cs.LG, cs.MA
Submitted: 2026-08-26
Updated: 2026-08-26
License: http://creativecommons.org/licenses/by/4.0/
The gist: Hardware kernel optimization requires repeated compilation, correctness testing, profiling, and revision.
Terminology
Abstract
Hardware kernel optimization requires repeated compilation, correctness testing, profiling, and revision. LLM agents can automate parts of this process, and stronger foundation models, longer context windows, and longer execution horizons have improved optimization within individual tasks. These advances alone do not enable an agent to learn from completed optimization runs. Existing kernel-optimization agents seldom preserve a decision, its observed execution feedback, and the later decisions that use that evidence. Retaining every prior trajectory is also impractical because an expanding history competes with the current task for context. We present KOPE, an experience-driven framework for hardware kernel optimization. KOPE records optimization trajectories with correctness and performance feedback in Experience Graph Memory, then uses Active Context Management and Injection to retrieve relevant experience under a fixed token budget. The graph retains decision order, observed outcomes, and alternative branches, allowing evidence collected on the target hardware to inform later optimization steps and tasks. Under the same GLM-5.2 setting, the geometric mean of KOPE's per-operator speedups is 1.54 times that of CANNBot, the strongest competing baseline. In a complete 53-operator ablation, Active Context Management and Injection raises pass rate from 60.0% to 84.6%, increases the evaluator-reported positive-field geometric mean from 0.0382 to 0.0661, and reduces optimization token consumption from 15.9B to 1.113B tokens relative to passive agent-led context construction. Enabling Experience Graph Memory raises full-suite pass rate from 55.2% to 84.6% and yields a 1.43 times geometric-mean speedup on valid timing comparisons. These results support continual optimization through external experience while the foundation model remains fixed.
Sources
- Make Each Token Count: Towards Improving Long-Context Performance with KV Cache Eviction
- Evaluating Large Language Models Trained on Code
- From Tokens to Regions: CUDA-Sensitive Instruction Tuning for GPU Kernel Generation
- CUDA Agent: Large-Scale Agentic RL for High-Performance CUDA Kernel Generation
- CANN Bench: Benchmarking Agent Generated Kernels against Real NPU and Algorithmic Limits
- DeepSeek-Coder: When the Large Language Model Meets Programming -- The Rise of Code Intelligence
- RULER: What's the Real Context Size of Your Long-Context Language Models?
- ChipNeMo: Domain-Adapted LLMs for Chip Design
- MemGPT: Towards LLMs as Operating Systems
- Fine-Tuning GPT-5 for GPU Kernel Generation
- Astra: A Multi-Agent System for GPU Kernel Performance Optimization
Related papers
- Polynomial-Augmented Neural Networks (PANNs) with Weak Orthogonality Constraints for Enhanced Function and PDE Approximation
- AIRL-S: Unifying Reinforcement Learning and Search-Based Test-Time Scaling via Adversarial Inverse Reinforcement Learning
- Transformers as Bayesian In-Context Experimenters: Smoothness-Adaptive Efficient ATE Estimation
- Convergence issues in Relational Concept Analysis based on AOC-posets
- Beliefs Beyond Posteriors: The Predictive Cost of ELBO Binding
- Understanding Diffusion Models via Ratio-Based Function Approximation with SignReLU Networks