Software debugging is tedious, time-consuming, and even error-prone by itself. So, various automated debugging techniques have been proposed in the literature to facilitate the debugging process. Automated Program Repair (APR) is one of the most recent advances in automated debugging, and can directly produce patches for buggy programs with minimal human intervention. Although various advanced APR techniques (including those that are either search-based or semantic-based) have been proposed, the simplistic mutation-based APR technique, which simply uses pre-defined mutation operators (e.g., changing a>=b into a>b) to mutate programs for finding patches, has not yet been thoroughly studied. In this paper, we implement the first practical bytecode-level APR technique, PraPR, and present the first extensive study on fixing real-world bugs (e.g., Defects4J bugs) using bytecode mutation. The experimental results show that surprisingly even PraPR with only the basic traditional mutators can produce genuine patches for 18 bugs. Furthermore, with our augmented mutators, PraPR is able to produce genuine patches for 43 bugs, significantly outperforming state-of-the-art APR. It is also an order of magnitude faster, indicating a promising future for bytecode-mutation-based APR.
An Empirical Analysis of the Influence of Fault Space on Search-Based Automated Program Repair
自动程序修复(Automated program repair,APR)已经引起了广泛的研究关注,并且已经提出了各种技术。基于搜索的APR是这些技术中最重要的类别之一。现有的研究集中在设计有效的变异算子和搜索算法,以更好地找到正确的补丁。尽管有各种努力,这些技术的有效性仍然受到搜索空间爆炸问题的限制。这个问题的关键因素之一是现有研究报告的故障空间的质量。这促使我们研究故障空间的重要性,成功地找到一个正确的补丁。我们的实证研究旨在回答三个问题。故障空间是否与基于搜索的APR的性能显著相关?如果是,在应用昂贵的APR技术之前,是否有任何指示性测量来近似故障空间的准确性?有没有自动化的方法可以提高故障空间的精度?我们观察到,故障空间的准确性影响基于搜索的APR技术的有效性和效率,例如,即使正确的补丁在搜索空间中,当实际定位位置的等级低于10时,GenProg的失败率也可能高达$60\%$。此外,GenProg能够找到更多的正确补丁,并与更少的尝试时,给定的故障空间具有更高的精度。我们还发现,负突变覆盖率,这是在这项研究中被设计来衡量一个测试套件的能力,杀死突变的语句执行失败的测试,是最具指示性的测量,以估计基于搜索的APR的效率。最后,我们证实,自动生成的测试用例可以帮助提高故障空间的准确性,并进一步提高基于搜索的APR技术的性能。
Attention: Not Just Another Dataset for Patch-Correctness Checking
自动程序修复(Automated Program Repair,APR)技术已引起学术界和工业界的广泛关注。同时,当前最先进的APR工具的一个主要限制是,通过所有原始测试的补丁不一定是开发人员想要的正确补丁,即,合理的补丁问题。迄今为止,已经提出了各种补丁正确性检查(PCC)技术来解决这个重要问题。然而,它们仅在非常有限的数据集上进行评估,因为用于生成此类补丁的APR工具只能探索可能补丁的搜索空间的一小部分,对现有PCC研究的外部有效性构成严重威胁。在本文中,我们构建了一个广泛的PCC数据集(据我们所知最大的手动标记的PCC数据集),以重新审视所有最先进的PCC技术。更具体地说,我们的PCC数据集包括从最近的PraPR APR工具生成的1,988个补丁,该工具利用高度优化的字节码级别补丁执行,并可以在其大型预定义的搜索空间内彻底探索所有可能的合理补丁(包括众所周知的修复模式)来自各种以前的APR工具)。我们对新数据集上代表性PCC技术的广泛研究揭示了各种令人惊讶的发现,并为未来的PCC研究提供了指导。
SPARC: Scenario Planning and Reasoning for Automated C Unit Test Generation
Bangladesh University of Engineering and Technology(孟加拉工程科技大学);National Taiwan University(台湾国立大学);University of Illinois at Urbana-Champaign(伊利诺伊大学厄巴纳-香槟分校)