arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2605.01124cs.PL
收藏

MLIR程序的实用形式验证

Practical Formal Verification for MLIR Programs

Georgia Institute of Technology(佐治亚理工学院);Colorado State University(科罗拉多州立大学)

Emily Tucker, Louis-Noël Pouchet, Erika Hunhoff, Stephen Neuendorffer, Erwei Wang

AI总结:

本文提出通过语义等价性验证MLIR程序转换的正确性,采用混合具体-符号解释方法,实现线性时间等价性检测,并验证了AMD MLIR-AIR、MLIR-AIE工具链及mlir-opt在多个基准测试中的正确性。

摘要:

优化编译器已成为研究和工业中生成高性能程序的关键。优化包括用户手动实现的优化以及针对特定目标和非特定目标的优化,用于将程序转换以获得良好性能。尽管这些优化对性能至关重要,但评估其正确性仍是一个主要挑战;未经证明的优化流程会增加部署错误代码的风险。本文旨在通过计算两个程序是否语义等价来验证转换程序的正确性,其中一个程序是另一个的转换版本。我们限制支持的程序类别,以启用混合具体-符号解释方法来等价性,这在很大程度上与程序的实现方式(语法、调度、存储等)无关。这种方法可以以线性时间相对于程序执行的操作来显示等价性。我们为MLIR的一个有意义子集开发了验证器,并报告了对AMD MLIR-AIR和MLIR-AIE工具链以及标准mlir-opt在数百个基准测试变体上的验证结果。

英文摘要:

Optimizing compilers have become a cornerstone for high-performance program generation in research and industry. Optimizations, including those implemented manually by a user and those target-specific and non-target-specific, are used to transform programs to achieve good performance. Although these optimizations are necessary for performance, assessing their correctness has remained a major challenge; the risk of incorrect code being deployed increases with unproven optimization flows. In this work, we target the formal verification of correctness of a transformed program by computing whether a pair of programs are semantically equivalent, one being a transformed version of the other. We restrict the class of programs supported to enable a hybrid concrete-symbolic interpretation approach to equivalence, which in turn is mostly agnostic to how the programs are implemented (syntax, schedule, storage, etc.). This approach can show equivalence in linear time with respect to the operations executed by the programs. We develop a verifier for a meaningful subset of MLIR, and report on the verification of the AMD MLIR-AIR and MLIR-AIE toolchains, as well as the standard mlir-opt on hundreds of benchmarks variants.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑