当前位置: X-MOL 学术arXiv.cs.SE › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
Learning Off-By-One Mistakes: An Empirical Study
arXiv - CS - Software Engineering Pub Date : 2021-02-24 , DOI: arxiv-2102.12429
Hendrig Sellik, Onno van Paridon, Georgios Gousios, Maurício Aniche

Mistakes in binary conditions are a source of error in many software systems. They happen when developers use, e.g., < or > instead of <= or >=. These boundary mistakes are hard to find and impose manual, labor-intensive work for software developers. While previous research has been proposing solutions to identify errors in boundary conditions, the problem remains open. In this paper, we explore the effectiveness of deep learning models in learning and predicting mistakes in boundary conditions. We train different models on approximately 1.6M examples with faults in different boundary conditions. We achieve a precision of 85% and a recall of 84% on a balanced dataset, but lower numbers in an imbalanced dataset. We also perform tests on 41 real-world boundary condition bugs found from GitHub, where the model shows only a modest performance. Finally, we test the model on a large-scale Java code base from Adyen, our industrial partner. The model reported 36 buggy methods, but none of them were confirmed by developers.

中文翻译:

学习人为错误:一项实证研究

在许多软件系统中,二进制条件下的错误是导致错误的原因。它们发生在开发人员使用例如<或>而不是<=或> =时。这些边界错误很难发现,并且需要软件开发人员进行繁重的手工工作。尽管先前的研究一直在提出解决方案以识别边界条件中的错误,但问题仍然存在。在本文中,我们探索了深度学习模型在学习和预测边界条件中的错误方面的有效性。我们在大约160万个示例中训练了不同的模型,这些示例在不同的边界条件下具有故障。在平衡的数据集上,我们可以达到85%的精度和84%的召回率,但是在不平衡的数据集中,召回率更低。我们还对从GitHub找到的41个现实世界的边界条件错误进行了测试,该模型仅显示适度的性能。最后,我们在工业合作伙伴Adyen的大规模Java代码库上测试了该模型。该模型报告了36种错误的方法,但没有一个方法得到开发人员的确认。
更新日期:2021-02-25
down
wechat
bug