paperbot · PL 论文追踪

全部论文 待读 收藏

P1 Phaedrus: Predicting Dynamic Application Behavior with Lightweight Generative Models and LLMs

Phaedrus:利用轻量级生成模型与 LLM 预测动态应用行为
OOPSLA 10(OOPSLA1)2026匹配度 5/10 · 该论文位于 AI→PL 交叉,用 LLM 与生成模型预测动态函数调用以指导编译优化,与“LLM/Agent 改进程序分析/编译”相关;但它不直接涉及静态分析/形式化验证、浮点程序分析、贝叶斯程序分析或 Agentic 程序,核心更偏 profile-guided compiler optimization。引用 0 inbox
Bodhisatwa Chatterjee, Neeraj Jadhav, Santosh Pande
crossref: 2026-09-10

AI 速览

一句话:提出 Phaedrus,用 LLM 与轻量生成模型预测动态函数调用,指导免执行、输入特定的编译优化。

现代应用在不同输入下行为差异显著,传统 profiling 依赖单一代表性执行,难以支撑输入特定的优化决策。Phaedrus 是一个编译器辅助的深度学习框架,专门预测动态函数调用序列并指导编译优化。它包含两种方法:Dynamis 免 profiling,利用 LLM 结合源码与静态编译器分析直接推断动态函数;Morpheus 在压缩并增强的 Whole Program Path(WPP)函数 profile 上训练生成模型,以预测未见输入下的程序行为。实验表明,Phaedrus 能准确识别占运行时间 85–99% 的热点函数;无需执行程序即可获得平均 6%(最高 25%)加速和 5.19%(最高 19%)二进制体积缩减,同时将 WPP 函数 profile 体积最多缩小 10^7 倍。

问题
现代应用行为随输入高度变化,传统依赖单一代表性执行的 profiling 难以捕捉这种输入相关差异,从而限制 profile-guided 优化的效果。
方法
提出 Phaedrus 编译器辅助框架,包含基于 LLM 的免 profiling 动态函数推断方法 Dynamis,以及基于压缩增强 WPP 函数 profile 训练生成模型、泛化到未见输入的 Morpheus,并用预测调用序列指导输入特定编译优化。
评估
在真实程序上评估热点函数识别与优化效果:热点覆盖总执行时间 85–99%,无需执行程序即可实现平均 6%(最高 25%)加速、最高 19% 二进制减小,并将 WPP profile 体积最多缩小 10^7 倍。
原文摘要(Abstract)

Application profiling is an indispensable technique for many software development tasks, such as code and memory layout optimizations, where optimization decisions are tailored to specific program profiles. Unfortunately, modern application codebases exhibit highly variant behavior across different inputs, creating challenges for conventional profiling approaches that rely on a single representative execution instance. In this paper, we propose Phaedrus , a new compiler-assisted deep learning framework designed to predict dynamic program behavior across varied execution instances, specifically focusing on dynamic function call prediction. These predicted call sequences are subsequently used to guide input-specific compiler optimizations, producing code specialized for each execution instance. Traditional profile-guided optimization methods struggle with the input-dependent variability of modern applications, where profiling on different inputs yields divergent application behaviors. To address this, Phaedrus proposes two new approaches: Application Profile Synthesis (Dynamis) , a profile-less approach where Large Language Models (LLMs) directly infer dynamic functions based on source code & static compiler analysis, bypassing the need for traditional profiling, and Application Profile Generalization (Morpheus) , which uses generative models trained on compressed and augmented Whole Program Path (WPP) based function profiles to predict application behavior under unseen inputs. Our experiments show that Phaedrus accurately identifies the most frequently executed and runtime-dominated hotspot functions, accounting for up to 85–99% of total execution time. Leveraging these predictions, Phaedrus enables superior profile-guided optimizations, delivering an average speedup of 6% (up to 25%) and a binary size reduction of 5.19% (up to 19%), without any program execution. In addition, Phaedrus reduces WPP function profile sizes by up to 10 7 ×.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot3810,
  title = {Phaedrus: Predicting Dynamic Application Behavior with Lightweight Generative Models and LLMs},
  author = {Bodhisatwa Chatterjee and Neeraj Jadhav and Santosh Pande},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {10},
  number = {OOPSLA1},
  year = {2026},
  doi = {10.1145/3798225}
}