快速排序的转换验证
Transformational Verification of Quicksort
摘要:
为约束逻辑程序开发的许多转换技术,也称为约束Horn子句(CHC),在程序验证领域中找到了新的有用的应用。在本文中,我们通过基于转换的验证方法进行了一个非平凡的案例研究。我们认为熟悉的Quicksort程序排序列表,写在一个功能性的程序设计语言,我们验证的前/后置条件,指定预期的正确性属性的功能中定义的程序。我们通过以下方式验证这些属性:(1)将它们转换为CHC,(2)通过删除所有列表出现来转换CHC,以及(3)通过使用布尔和整数的Eldarica求解器来检查转换后的CHC的可满足性。在第(2)点提到的转换需要对以前工作中提出的消除归纳定义的数据结构的算法进行扩展,因为在转换的一个阶段,我们使用在以前阶段已经证明的一些性质作为引理。
英文摘要:
Many transformation techniques developed for constraint logic programs, also known as constrained Horn clauses (CHCs), have found new useful applications in the field of program verification. In this paper, we work out a nontrivial case study through the transformation-based verification approach. We consider the familiar Quicksort program for sorting lists, written in a functional programming language, and we verify the pre/-postconditions that specify the intended correctness properties of the functions defined in the program. We verify these properties by: (1) translating them into CHCs, (2) transforming the CHCs by removing all list occurrences, and (3) checking the satisfiability of the transformed CHCs by using the Eldarica solver over booleans and integers. The transformation mentioned at Point (2) requires an extension of the algorithms for the elimination of inductively defined data structures presented in previous work, because during one stage of the transformation we use as lemmas some properties that have been proved at previous stages.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。