paperbot · PL 论文追踪

全部论文 待读 收藏

P2 CF-GKAT: Efficient Validation of Control-Flow Transformations

CF-GKAT:控制流变换的高效验证
POPL 9(POPL)2025匹配度 4/10 · 论文属于形式化验证与控制流变换,兼具理论形式化和工具实现,与 PL/形式验证方向相邻。但它不涉及 LLM/Agent、浮点程序分析或贝叶斯程序分析,也未体现 AI×PL 交叉,因此与画像中的核心问题匹配有限。引用 5 inbox
Cheng Zhang, Tobias Kappé, David E. Narváez, Nico Naus
crossref: 2026-09-10

AI 速览

一句话:提出 CF-GKAT,扩展 GKAT 以支持非局部控制流和硬编码值,高效可靠完备地验证控制流变换的迹等价。

GKAT(带测试的守卫 Kleene 代数)为简单命令式程序的迹等价提供了可靠且完备的推理框架,但存在两个局限:它完全忽略原语的语义,且不支持 goto、break、return 等非局部控制流。为克服这些限制,本文引入 Control-Flow GKAT(CF-GKAT),该体系能够推理包含非局部控制流及硬编码值的程序。CF-GKAT 可对更大类程序进行可靠且完备的迹等价验证,同时保持 GKAT 近乎线性的效率。这使得它适用于验证控制流操作过程,如反编译和 goto 消除。作者通过验证多个高度非平凡的程序变换(包括 Erosa 和 Hendren 的 goto 消除过程以及 Ghidra 反编译器的输出)展示了 CF-GKAT 的能力,为 Kleene 代数在反编译与控制流变换领域开辟了更广泛的应用。

问题
GKAT 虽然能可靠且完备地判定简单命令式程序的迹等价,但它忽略原语语义且不支持 goto、break、return 等非局部控制流,限制了其适用范围。
方法
提出 CF-GKAT,在 GKAT 中融入非局部控制流和硬编码值,同时保持近乎线性的效率,从而对更广的一类程序实现可靠且完备的迹等价验证。
评估
通过验证 Erosa 和 Hendren 的 goto 消除过程以及 Ghidra 反编译器的输出等多个高度非平凡的程序变换,展示了 CF-GKAT 的有效性。
原文摘要(Abstract)

Guarded Kleene Algebra with Tests (GKAT) provides a sound and complete framework to reason about trace equivalence between simple imperative programs. However, there are still several notable limitations. First, GKAT is completely agnostic with respect to the meaning of primitives, to keep equivalence decidable. Second, GKAT excludes non-local control flow such as goto, break , and return . To overcome these limitations, we introduce Control-Flow GKAT (CF-GKAT) , a system that allows reasoning about programs that include non-local control flow as well as hardcoded values. CF-GKAT is able to soundly and completely verify trace equivalence of a larger class of programs, while preserving the nearly-linear efficiency of GKAT. This makes CF-GKAT suitable for the verification of control-flow manipulating procedures, such as decompilation and goto-elimination. To demonstrate CF-GKAT’s abilities, we validated the output of several highly non-trivial program transformations, such as Erosa and Hendren’s goto -elimination procedure and the output of Ghidra decompiler. CF-GKAT opens up the application of Kleene Algebra to a wider set of challenges, and provides an important verification tool that can be applied to the field of decompilation and control-flow transformation.

链接与引用

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

BibTeX
@article{ZhangKNN25,
  title = {CF-GKAT: Efficient Validation of Control-Flow Transformations},
  author = {Cheng Zhang and Tobias Kappé and David E. Narváez and Nico Naus},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {POPL},
  year = {2025},
  doi = {10.1145/3704857}
}