HyperPUT: Generating Synthetic Faulty Programs to Challenge Bug-Finding Tools
Riccardo Felici, Laura Pozzi, Carlo A. Furia
备注:
This preprint has not undergone peer review or any post-submission improvements or corrections. The Version of Record of this article is published in Empirical Software Engineering, and is available online at: https://doi.org/10.1007/s10664-023-10430-8
本文提出 HyperPUT,从种子缺陷出发通过增量程序变换自动生成可扩展规模的带缺陷 C 程序,用于多方面挑战现代缺陷发现工具并支持实证评估。
摘要:
随着自动检测缺陷研究的发展并产生新技术,拥有带有已知缺陷的合适程序集合,对于可靠且有意义地比较这些技术的有效性变得至关重要。现有大多数方法依赖于收集人工整理的真实世界缺陷的基准,或植入真实世界程序中的合成缺陷。使用真实世界程序意味着扩展现有的基准或创建新的基准仍然是一项复杂且耗时的任务。在本文中,我们提出了一种互补方法,可自动生成带有植入缺陷的程序。我们的技术称为 HyperPUT,通过从一个“种子”缺陷开始,增量式地应用程序变换(引入条件语句、循环等编程构造)来构建 C 程序,直到生成具有所需规模的程序。在实验评估中,我们展示了 HyperPUT 如何生成有缺陷的程序,这些程序能够以不同方式挑战现代缺陷发现工具的能力,并且其部分特征与现有基准中的缺陷具有可比性。这些结果表明,HyperPUT 可以成为支持缺陷发现技术进一步研究的有用工具,尤其是在其实证评估方面。
英文摘要:
As research in automatically detecting bugs grows and produces new techniques, having suitable collections of programs with known bugs becomes crucial to reliably and meaningfully compare the effectiveness of these techniques. Most of the existing approaches rely on benchmarks collecting manually curated real-world bugs, or synthetic bugs seeded into real-world programs. Using real-world programs entails that extending the existing benchmarks or creating new ones remains a complex time-consuming task.
In this paper, we propose a complementary approach that automatically generates programs with seeded bugs. Our technique, called HyperPUT, builds C programs from a "seed" bug by incrementally applying program transformations (introducing programming constructs such as conditionals, loops, etc.) until a program of the desired size is generated. In our experimental evaluation, we demonstrate how HyperPUT can generate buggy programs that can challenge in different ways the capabilities of modern bug-finding tools, and some of whose characteristics are comparable to those of bugs in existing benchmarks. These results suggest that HyperPUT can be a useful tool to support further research in bug-finding techniques -- in particular their empirical evaluation.
Bugs in the Shadows: Static Detection of Faulty Python Refactorings
Federal University of Campina Grande(坎皮纳格兰德联邦大学);Federal University of Alagoas(阿拉戈阿斯联邦大学);Pontifical Catholic University of Rio de Janeiro(里约热内卢天主教 Pontifical 大学)