arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2410.09668cs.PL
收藏

使用约束Horn子句对树操作程序的自动验证

Automated Verification of Tree-Manipulating Programs Using Constrained Horn Clauses

Marco Faella, Gennaro Parlato

AI总结:

本文提出一种结合自动机和逻辑的自动验证技术,通过knitted-tree编码将程序执行映射为单一树结构,并利用约束Horn子句刻画其组合性质,将验证简化为求解CHC可满足性问题,广泛适用于树操作程序的多种验证任务。

摘要:

验证操作树数据结构的程序通常需要复杂、临时的证明,这些证明难以泛化和自动化。本文引入了一种自动分析此类程序的技术。我们的方法结合了自动机和逻辑,以统一应对由各种树数据结构带来的挑战。我们方法的核心是knitted-tree编码,它将程序执行映射到一个封装了输入、输出和中间配置的单一树数据结构中。通过利用knitted-tree的组合性质,我们使用约束Horn子句(CHCs)来刻画它们。这种编码将验证简化为求解CHC可满足性问题,受益于CHC求解器的持续进展。虽然我们以内存安全问题为例进行说明,但我们的技术广泛适用于涉及树数据结构的各种验证任务。

英文摘要:

Verifying programs that manipulate tree data structures often requires complex, ad-hoc proofs that are hard to generalize and automate. This paper introduces an automatic technique for analyzing such programs. Our approach combines automata and logics to tackle the challenges posed by diverse tree data structures uniformly. At the core of our methodology is the knitted-tree encoding, which maps a program execution into a tree data structure encapsulating input, output, and intermediate configurations, within a single structure. By leveraging the compositional properties of knitted-trees, we characterize them using constrained Horn clauses (CHCs). This encoding reduces verification to solving CHC satisfiability, benefiting from ongoing advancements in CHC solvers. While we focus on the memory safety problem for illustration, our technique applies broadly to various verification tasks involving tree data structures.

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

↑