arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1504.05078cs.SE
收藏

无限循环的自动修复

Automatic Repair of Infinite Loops

Sebastian R. Lamelas Marcote, Martin Monperrus

摘要:

软件自动修复的研究主要是开发能够自动检测和修复缺陷的系统。一个著名的bug是无限循环。每个计算机程序员或用户都至少经历过一次这种类型的错误。我们陈述了在基于测试集的软件修复的上下文中修复无限循环的问题:给定至少一个失败测试的测试集,生成使所有测试用例通过的补丁。因此,修复无限循环意味着至少有一个测试用例通过触发无限循环而挂起。我们自动修复无限循环的系统称为$Infinitel$。我们开发了一种技术来操纵循环,以便可以动态地分析循环的迭代次数;决定中断循环执行;并动态地检查循环的状态在每个迭代的基础上。然后,为了合成新的循环条件,我们使用基于可满足性模理论(SMT)的技术将这组程序状态编码为代码合成问题。我们评估我们的技术在七个种子错误和七个真正的错误。$Infinitel$能够在标准笔记本电脑配置上在几秒钟到一个小时内修复所有这些问题。

英文摘要:

Research on automatic software repair is concerned with the development of systems that automatically detect and repair bugs. One well-known class of bugs is the infinite loop. Every computer programmer or user has, at least once, experienced this type of bug. We state the problem of repairing infinite loops in the context of test-suite based software repair: given a test suite with at least one failing test, generate a patch that makes all test cases pass. Consequently, repairing infinites loop means having at least one test case that hangs by triggering the infinite loop. Our system to automatically repair infinite loops is called $Infinitel$. We develop a technique to manipulate loops so that one can dynamically analyze the number of iterations of loops; decide to interrupt the loop execution; and dynamically examine the state of the loop on a per-iteration basis. Then, in order to synthesize a new loop condition, we encode this set of program states as a code synthesis problem using a technique based on Satisfiability Modulo Theory (SMT). We evaluate our technique on seven seeded-bugs and on seven real-bugs. $Infinitel$ is able to repair all of them, within seconds up to one hour on a standard laptop configuration.

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

↑