A systematic literature review on source code similarity measurement and clone detection: Techniques, applications, and challenges

被引:36
作者
Zakeri-Nasrabadi, Morteza [1 ]
Parsa, Saeed [1 ]
Ramezani, Mohammad [1 ]
Roy, Chanchal [2 ]
Ekhtiarzadeh, Masoud [1 ]
机构
[1] Iran Univ Sci & Technol, Sch Comp Engn, Hengam St, Resalat Sq, Tehran 1684613114, Iran
[2] Univ Saskatchewan, Dept Comp Sci, Saskatoon, SK, Canada
关键词
Source code similarity; Code clone; Plagiarism detection; Code recommendation; Systematic literature review; SOFTWARE; BENCHMARK; FRAMEWORK; EFFICIENT; PROGRAMS; NICAD; COPY;
D O I
10.1016/j.jss.2023.111796
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Measuring and evaluating source code similarity is a fundamental software engineering activity that embraces a broad range of applications, including but not limited to code recommendation, duplicate code, plagiarism, malware, and smell detection. This paper proposes a systematic literature review and meta-analysis on code similarity measurement and evaluation techniques to shed light on the existing approaches and their characteristics in different applications. We initially found over 10,000 articles by querying four digital libraries and ended up with 136 primary studies in the field. The studies were classified according to their methodology, programming languages, datasets, tools, and applications. A deep investigation reveals 80 software tools, working with eight different techniques on five application domains. Nearly 49% of the tools work on Java programs and 37% support C and C++, while there is no support for many programming languages. A noteworthy point was the existence of 12 datasets related to source code similarity measurement and duplicate codes, of which only eight datasets were publicly accessible. The lack of reliable datasets, empirical evaluations, hybrid methods, and focuses on multi-paradigm languages are the main challenges in the field. Emerging applications of code similarity measurement concentrate on the development phase in addition to the maintenance.& COPY; 2023 Elsevier Inc. All rights reserved.
引用
收藏
页数:33
相关论文
共 257 条
[21]  
[Anonymous], 2023, Species Fungorum
[22]  
[Anonymous], 2015, P 19 INT C EVALUATIO, DOI DOI 10.1145/2745802.2745821
[23]   CodeBERT for Code Clone Detection: A Replication Study [J].
Arshad, Saad ;
Abid, Shamsa ;
Shamail, Shafay .
2022 IEEE 16TH INTERNATIONAL WORKSHOP ON SOFTWARE CLONES (IWSC 2022), 2022, :39-45
[24]  
Avetisyan A, 2015, TENTH INTERNATIONAL CONFERENCE ON COMPUTER SCIENCE AND INFORMATION TECHNOLOGIES REVISED SELECTED PAPERS CSIT-2015, P100, DOI 10.1109/CSITechnol.2015.7358259
[25]   Machine learning techniques for code smell detection: A systematic literature review and meta-analysis [J].
Azeem, Muhammad Ilyas ;
Palomba, Fabio ;
Shi, Lin ;
Wang, Qing .
INFORMATION AND SOFTWARE TECHNOLOGY, 2019, 108 :115-138
[26]   A Data Mining Approach for Detecting Higher-Level Clones in Software [J].
Basit, Hamid Abdul ;
Jarzabek, Stan .
IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2009, 35 (04) :497-514
[27]   Clone detection using abstract syntax trees [J].
Baxter, ID ;
Yahin, A ;
Moura, L ;
Sant'Anna, M ;
Bier, L .
INTERNATIONAL CONFERENCE ON SOFTWARE MAINTENANCE, PROCEEDINGS, 1998, :368-377
[28]   Comparison and evaluation of clone detection tools [J].
Bellon, Stefan ;
Koschke, Rainer ;
Antoniol, Giuliano ;
Krinke, Jens ;
Merlo, Ettore .
IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2007, 33 (09) :577-591
[29]  
Bhattacharjee A., 2013, P ACM S APPL COMPUTI, P846, DOI DOI 10.1145/2480362.2480525
[30]   SPAPE: A semantic-preserving amorphous procedure extraction method for near-miss clones [J].
Bian, Yixin ;
Koru, Gunes ;
Su, Xiaohong ;
Ma, Peijun .
JOURNAL OF SYSTEMS AND SOFTWARE, 2013, 86 (08) :2077-2093