paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Oreo: detection of clones in the twilight zone

Oreo:暮光区克隆检测
FSE Proceedings of the 2018 26th ACM Joint Meeting on European Software Engineering Conference and Symposium on the Foundations of Software Engineering2018匹配度 2/10 · 论文是传统代码克隆检测,结合机器学习、信息检索与软件度量,虽属程序分析与ML交叉的宽泛方向,但未涉及用户核心关注的LLM/Agent、浮点程序分析或贝叶斯程序分析。引用 145 inbox
Vaibhav Saini, Farima Farmahinifarahani, Yadong Lu, Pierre Baldi, Cristina V. Lopes
crossref: 2026-09-12

AI 速览

一句话:提出 Oreo,结合机器学习、信息检索与软件度量,检测 Type-1 至 Type-3 及 Twilight Zone 代码克隆。

源代码克隆按检测难度分为四类,从纯文本的 Type-1 到纯语义的 Type-4。现有克隆检测器大多只能较好处理 Type-3,即句法差异克隆;而在 Type-3 与 Type-4 之间存在仍具有一定句法相似性但极难检测的“暮光区”(Twilight Zone)。本文提出 Oreo,一种结合机器学习、信息检索与软件度量的新型克隆检测方法,不仅准确检测 Type-1 至 Type-3 克隆,还能检测暮光区中更难检测的克隆。作者在 BigCloneBench 上评估 Oreo 的召回率,并通过人工评估精确率。结果表明 Oreo 同时具有高召回率和高精确率,并能以可扩展方式推进对中等到弱句法相似性克隆的检测边界。

问题
现有代码克隆检测器大多难以处理 Type-3 与 Type-4 之间、仍具一定句法相似性但极难检测的 Twilight Zone 克隆。
方法
Oreo 融合机器学习、信息检索和软件度量来检测源代码克隆,兼顾常规克隆与暮光区克隆。
评估
在 BigCloneBench 上评估召回率,并通过人工评估精确率;结果显示高召回率与高精确率,且具备可扩展性。
原文摘要(Abstract)

Source code clones are categorized into four types of increasing difficulty of detection, ranging from purely textual (Type-1) to purely semantic (Type-4). Most clone detectors reported in the literature work well up to Type-3, which accounts for syntactic differences. In between Type-3 and Type-4, however, there lies a spectrum of clones that, although still exhibiting some syntactic similarities, are extremely hard to detect – the Twilight Zone. Most clone detectors reported in the literature fail to operate in this zone. We present Oreo, a novel approach to source code clone detection that not only detects Type-1 to Type-3 clones accurately, but is also capable of detecting harder-to-detect clones in the Twilight Zone. Oreo is built using a combination of machine learning, information retrieval, and software metrics. We evaluate the recall of Oreo on BigCloneBench, and perform manual evaluation for precision. Oreo has both high recall and precision. More importantly, it pushes the boundary in detection of clones with moderate to weak syntactic similarity in a scalable manner

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@inproceedings{paperbot4640,
  title = {Oreo: detection of clones in the twilight zone},
  author = {Vaibhav Saini and Farima Farmahinifarahani and Yadong Lu and Pierre Baldi and Cristina V. Lopes},
  booktitle = {FSE},
  year = {2018},
  doi = {10.1145/3236024.3236026}
}