paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Detection of Optimizations Missed by the Compiler

检测编译器遗漏的优化
FSE Proceedings of the 31st ACM Joint European Software Engineering Conference and Symposium on the Foundations of Software Engineering2023匹配度 3/10 · 该论文属于编译器优化与静态分析领域的遗漏优化检测,与用户核心关注的 LLM/Agent 结合、浮点程序分析、贝叶斯程序分析均无直接交集;仅在程序分析与编译器测试层面存在间接关联。引用 1 inbox
Yi Zhang
crossref: 2026-09-12dblp: 2026-09-12

AI 速览

一句话:提出通用方法 MOD,通过优化间的人工映射检测编译器遗漏的优化,并在 LLVM 可用表达式上报告 20 个正确告警。

编译器优化遗漏会降低性能,但现有研究多针对特定分析,通用方法又常依赖不同编译器间的差分测试,难以发现多个编译器共有的优化缺陷。本文提出通用方法 MOD:它利用人工构建的优化映射,判断在相同代码上本应一致触发的优化是否同时发生;若一个优化触发而另一个未触发,则表明两者之一存在缺陷。作者将 MOD 实现为工具,用于检测 LLVM 可用表达式分析中遗漏的优化。实验表明,在对随机测试程序进行一小时的检测中,MOD 能报告 20 个正确告警。

问题
现有优化遗漏检测多局限于特定分析,或依赖跨编译器差分测试,难以发现多个编译器共有的优化缺陷。
方法
提出 MOD,通过人工策展的优化映射检查本应一致触发的优化是否同时发生,不一致即提示优化 bug。
评估
在 LLVM 可用表达式分析上实现工具,对随机测试程序检测一小时,报告 20 个正确告警。
原文摘要(Abstract)

With the increasing significance of compilers in software development, identifying optimization bugs and enhancing their performance has become a significant challenge. In recent years, many studies have targeted only specific analyses to identify missed optimizations (e.g., in data flow analyses). While there have been some general approaches, most rely on differential testing between different compilers, which makes it difficult to identify optimization bugs that are common to multiple compilers. This paper tackles these challenges by introducing an effective and general approach called MOD. MOD works by using a manually-curated mapping between optimizations, ensuring that code should be consistently optimized: if one optimization triggers but the other does not, that indicates a bug in either of the two optimizations. We implemented MOD as a tool to detect missed optimizations in the available expressions of the LLVM. Experimental results show that MOD can report 20 correct alerts in one hour of detection of random test programs.

链接与引用

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

BibTeX
@inproceedings{Zhang23,
  title = {Detection of Optimizations Missed by the Compiler},
  author = {Yi Zhang},
  booktitle = {FSE},
  year = {2023},
  doi = {10.1145/3611643.3617846}
}