论文标题

具有多个呼叫(长版)的不平衡递归功能的回归验证

Regression verification of unbalanced recursive functions with multiple calls (long version)

论文作者

Sayedoff, Chaked R. J., Strichman, Ofer

论文摘要

给定两个程序$ p_1 $和$ p_2 $,通常是同一程序的两个版本,回归验证的目标是标记$ p_1 $和$ p_2 $的功能对等效的定义。最常见的定义是部分等效性,即,如果两个功能都以相同的输入供输入并且它们都终止,则两个函数会发出相同的输出。回归验证工具(RVT)使用的策略是在$ p_1,p_2 $的呼叫图上进行自下而上,抽象已经证明已经证明与未解释的功能相同的功能,将循环转换为递归,并在未解释的功能上抽象递归呼叫。这使其能够以不含循环和递归的小程序的形式创建验证条件。只要它们同步,此方法就可以很好地适用于递归函数,并且通常会失败。在这项工作中,我们研究了当两个递归函数不同步时证明等效性的问题。有效地,我们将以前的工作扩展到了使用单个递归呼叫站点的功能研究此问题的一般情况。我们还引入了一种方法,用于自动检测到在可能的情况下进行两个递归函数同步所必需的展开。我们展示了具有多个递归调用的功能对的示例,这些函数现在可以证明与我们的方法相等,但不能证明与任何其他自动验证系统相等。

Given two programs $p_1$ and $p_2$, typically two versions of the same program, the goal of regression verification is to mark pairs of functions from $p_1$ and $p_2$ that are equivalent, given a definition of equivalence. The most common definition is that of partial equivalence, namely that the two functions emit the same output if they are fed with the same input and they both terminate. The strategy used by the Regression Verification Tool (RVT) is to progress bottom up on the call graphs of $P_1,P_2$, abstract those functions that were already proven to be equivalent with uninterpreted functions, turn loops into recursion, and abstract the recursive calls also with uninterpreted functions. This enables it to create verification conditions in the form of small programs that are loop- and recursion-free. This method works well for recursive functions as long as they are in sync, and typically fails otherwise. In this work we study the problem of proving equivalence when the two recursive functions are not in sync. Effectively we extend previous work that studied this problem for functions with a single recursive call site, to the general case. We also introduce a method for detecting automatically the unrolling that is necessary for making two recursive functions synchronize, when possible. We show examples of pairs of functions with multiple recursive calls that can now be proven equivalent with our method, but cannot be proven equivalent with any other automated verification system.

扫码加入交流群

加入微信交流群

微信交流群二维码

扫码加入学术交流群,获取更多资源