arrow
返回

Fast Code Clone Detection Based on Weighted Recursive Autoencoders

delete2019-01-01
delete31
delete
OA
AI
J
Jie Zeng *
K
Kerong Ben
X
Xiaowei Li
张
张弦 (Xian Zhang)
DOI:10.1109/ACCESS.2019.2938825delete
delete原文链接
delete分享
delete收藏
查看原文
摘要

摘要

En 中文
Code cloning considerably facilitates software development but also leads to recurring bugs and other software quality problems. In this paper, we propose a fast code clone detection method based on weighted recursive autoencoders (RAE) to measure code similarity at the function level. Different from manually defining features for code clone detection, our deep learning-based method can automatically learn program features. First, we analyze program abstract syntax trees using weighted RAE, extract the program features and encode the functions to vectors. During the modeling process, we consider node weight information in abstract syntax trees to increase the proportion of information contributed by important nodes in the final vector representation of one program. Second, we report functions with similar vectors as code clone pairs. The second phase is time consuming when analyzing large software systems because it needs quadratic pairwise comparisons. To solve this problem, we transform the clone detection problem into an approximate nearest neighbors search (ANNS) in a high-dimensional vector set and use the navigating spreading-out graph to reduce the computational time complexity. Experimental results on BigCloneBench show that our method outperforms the compared algorithm based on unweighted RAE in terms of precision, recall, and AUC value and can return clone pairs in approximately 33 min, while the compared algorithm requires approximately 14 days when performing pairwise comparisons among 785,438 functions' vectors. Our method also outperforms many prominent tools, including Oreo, in detecting Moderately Type-3 or Type-4 clones, and our false positive rate (FPR) equals 0.055, which means few false positives. More importantly, our method has no need for labeled data, and all of the source code is released to guarantee experimental reproducibility.
Keyword:
Code clone
fast code clone detection
abstract syntax tree
weighted recursive autoen-coders
navigating spreading-out graph
AI总结

AI总结

对已上传原文的论文进行重点信息的提取,主要内容包括:简要概述、研究摘要、背景介绍、关键亮点、图文解析、展望与总结。

期刊

IEEE Access 封面图
IEEE Access
IF:
3.6
论文数:
9.8W
被引数:
29.4W

机构

W
wuhan naval university of engineering
学者数:
2.6K
论文数: 1.6K
被引数: 2
引用论文

引用论文

err分享
err收藏
Influence of algal organic matter of Microcystis aeruginosa on ferrate decay and MS2 bacteriophage inactivation
err2019-12-01
err0
PREAI
errXueyin Wu; Aixi Tang; Xiaochao Bi; Thanh H. Nguyen; Baoling Yuan
err分享
err收藏
Comparison and evaluation of clone detection tools克隆检测工具的比较与评价
err2007-09-01
err510
errOAAI
errBellon, Stefan; Koschke, Rainer; Antoniol, Giuliano; Krinke, Jens; Merlo, Ettore
err分享
err收藏
学者 查看更多内容