paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Fuzzing MLIR Compiler Infrastructure via Operation Dependency Analysis

基于操作依赖分析的 MLIR 编译器基础设施模糊测试
ISSTA Proceedings of the 33rd ACM SIGSOFT International Symposium on Software Testing and Analysis2024匹配度 4/10 · 该论文属于编译器基础设施MLIR的模糊测试,使用操作依赖图与变异规则,与PL/编译器测试相关;但未涉及用户核心关注的LLM/Agent、静态分析在ML系统中的应用、浮点程序分析或贝叶斯程序分析。引用 12 inbox
Chenyao Suo, Junjie Chen, Shuang Liu, Jiajun Jiang, Yingquan Zhao, Jianrong Wang
crossref: 2026-09-12

AI 速览

一句话:利用操作依赖图与依赖覆盖引导变异,提升 MLIR 编译器模糊测试效果并发现 63 个新缺陷。

MLIR 编译器基础设施近年来被广泛使用,它通过 dialect 支持不同抽象层次的表示,其正确性至关重要。已有的基于文法的模糊测试技术 MLIRSmith 虽然有效,但以随机方式生成测试程序,限制了输入空间的探索,从而制约了整体模糊测试效果。本文提出新的模糊测试技术:由于复杂或不常见的操作间数据/控制依赖常有助于触发 MLIR 缺陷,该工作为 MLIR 程序构建操作依赖图,并定义相应的操作依赖覆盖率来引导模糊测试过程;为驱使测试向更高依赖覆盖推进,进一步设计了一组面向依赖的变异规则。作者将其实现在 MLIR 编译器基础设施的最新版本上运行,共检测到 63 个此前未知的缺陷,其中 38 个已被开发者修复、48 个已被确认。

问题
MLIR 作为编译器基础设施其正确性十分关键,而现有基于文法的 MLIRSmith 以随机方式生成测试程序,难以充分探索输入空间,限制了模糊测试的有效性。
方法
为 MLIR 程序构建操作依赖图,定义操作依赖覆盖率作为引导指标,并设计一组面向依赖的变异规则,驱动模糊测试朝更高的依赖覆盖推进。
评估
将所提技术应用于 MLIR 编译器基础设施的最新修订版本,检测到 63 个此前未知的缺陷,其中 38 个已被修复、48 个已获开发者确认。
原文摘要(Abstract)

MLIR (Multi-Level Intermediate Representation) compiler infrastructure has gained widespread popularity in recent years. It introduces dialects to accommodate various levels of abstraction within the representation. Due to its fundamental role in compiler construction, it is critical to ensure its correctness. Recently, a grammar-based fuzzing technique (i.e., MLIRSmith) has been proposed for it and achieves notable effectiveness. However, MLIRSmith generates test programs in a random manner, which restricts the exploration of the input space, thereby limiting the overall fuzzing effectiveness. In this work, we propose a novel fuzzing technique, called MLIR. As complicated or uncommon data/control dependencies among various operations are often helpful to trigger MLIR bugs, it constructs the operation dependency graph for an MLIR program and defines the associated operation dependency coverage to guide the fuzzing process. To drive the fuzzing process towards increasing operation dependency coverage, MLIR then designs a set of dependency-targeted mutation rules. By applying MLIR to the latest revisions of the MLIR compiler infrastructure, it detected 63 previously unknown bugs, among which 38/48 bugs have been fixed/confirmed by developers.

链接与引用

DOI 原文 ·

BibTeX
@inproceedings{paperbot8612,
  title = {Fuzzing MLIR Compiler Infrastructure via Operation Dependency Analysis},
  author = {Chenyao Suo and Junjie Chen and Shuang Liu and Jiajun Jiang and Yingquan Zhao and Jianrong Wang},
  booktitle = {ISSTA},
  year = {2024},
  doi = {10.1145/3650212.3680360}
}