TY - GEN
T1 - Code Clone Configuration as a Multi-Objective Search Problem
AU - Sousa, Denis
AU - Paixao, Matheus
AU - Ragkhitwetsagul, Chaiyong
AU - Uchoa, Italo
N1 - Publisher Copyright:
© 2024 ACM.
PY - 2024/10/24
Y1 - 2024/10/24
N2 - Clone detection is an automated process for finding duplicated code within a project's code base or between online sources. Nowadays, the code cloning community advocates that developers must be aware of the clones they may have in their code bases. In modern clone detection, rank-based tools appear as the ones able to handle the large code corpora that are necessary to identify online clones. However, such tools are sensitive to their parameters, which directly affects their clone detection abilities. Moreover, existing parameter optimization approaches for clone detectors are not meant for rank-based tools. To overcome this issue and facilitate empirical studies of code clones, we introduce Multi-objective Code Clone Configuration, a new approach based on multi-objective optimization to search for an optimal set of parameters for a rank-based clone detection tool. In our empirical evaluation, we ran 3 baseline search algorithms and NSGA-II to assess their performance in this new optimization problem. Additionally, we compared the optimized configurations with the default one. Our results show that NSGA-II was the algorithm that achieved the best performance, finding better configurations than those of the baseline algorithms. Finally, the optimized configurations achieved improvements of 71.08% and 46.29% for our fitness functions.
AB - Clone detection is an automated process for finding duplicated code within a project's code base or between online sources. Nowadays, the code cloning community advocates that developers must be aware of the clones they may have in their code bases. In modern clone detection, rank-based tools appear as the ones able to handle the large code corpora that are necessary to identify online clones. However, such tools are sensitive to their parameters, which directly affects their clone detection abilities. Moreover, existing parameter optimization approaches for clone detectors are not meant for rank-based tools. To overcome this issue and facilitate empirical studies of code clones, we introduce Multi-objective Code Clone Configuration, a new approach based on multi-objective optimization to search for an optimal set of parameters for a rank-based clone detection tool. In our empirical evaluation, we ran 3 baseline search algorithms and NSGA-II to assess their performance in this new optimization problem. Additionally, we compared the optimized configurations with the default one. Our results show that NSGA-II was the algorithm that achieved the best performance, finding better configurations than those of the baseline algorithms. Finally, the optimized configurations achieved improvements of 71.08% and 46.29% for our fitness functions.
KW - Clone Detection
KW - Multi-objective Optimization
KW - Search-based Software Engineering
UR - https://www.scopus.com/pages/publications/85210572093
U2 - 10.1145/3674805.3690757
DO - 10.1145/3674805.3690757
M3 - Conference contribution
AN - SCOPUS:85210572093
T3 - International Symposium on Empirical Software Engineering and Measurement
SP - 503
EP - 509
BT - Proceedings of the 18th ACM/IEEE International Symposium on Empirical Software Engineering and Measurement, ESEM 2024
PB - IEEE Computer Society
T2 - 18th ACM/IEEE International Symposium on Empirical Software Engineering and Measurement, ESEM 2024
Y2 - 24 October 2024 through 25 October 2024
ER -