code clones
Recently Published Documents


TOTAL DOCUMENTS

170
(FIVE YEARS 35)

H-INDEX

18
(FIVE YEARS 2)

2021 ◽  
Vol 7 ◽  
pp. e737
Author(s):  
Muhammad Hammad ◽  
Önder Babur ◽  
Hamid Abdul Basit ◽  
Mark van den Brand

Software developers frequently reuse source code from repositories as it saves development time and effort. Code clones (similar code fragments) accumulated in these repositories represent often repeated functionalities and are candidates for reuse in an exploratory or rapid development. To facilitate code clone reuse, we previously presented DeepClone, a novel deep learning approach for modeling code clones along with non-cloned code to predict the next set of tokens (possibly a complete clone method body) based on the code written so far. The probabilistic nature of language modeling, however, can lead to code output with minor syntax or logic errors. To resolve this, we propose a novel approach called Clone-Advisor. We apply an information retrieval technique on top of DeepClone output to recommend real clone methods closely matching the predicted clone method, thus improving the original output by DeepClone. In this paper we have discussed and refined our previous work on DeepClone in much more detail. Moreover, we have quantitatively evaluated the performance and effectiveness of Clone-Advisor in clone method recommendation.


2021 ◽  
Author(s):  
Ran Mo ◽  
Yang Zhao ◽  
Qiong Feng ◽  
Zengyang Li
Keyword(s):  

2021 ◽  
Vol 11 (14) ◽  
pp. 6613
Author(s):  
Young-Bin Jo ◽  
Jihyun Lee ◽  
Cheol-Jung Yoo

Appropriate reliance on code clones significantly reduces development costs and hastens the development process. Reckless cloning, in contrast, reduces code quality and ultimately adds costs and time. To avoid this scenario, many researchers have proposed methods for clone detection and refactoring. The developed techniques, however, are only reliably capable of detecting clones that are either entirely identical or that only use modified identifiers, and do not provide clone-type information. This paper proposes a two-pass clone classification technique that uses a tree-based convolution neural network (TBCNN) to detect multiple clone types, including clones that are not wholly identical or to which only small changes have been made, and automatically classify them by type. Our method was validated with BigCloneBench, a well-known and wildly used dataset of cloned code. Our experimental results validate that our technique detected clones with an average rate of 96% recall and precision, and classified clones with an average rate of 78% recall and precision.


2021 ◽  
Vol 12 (3) ◽  
pp. 17-31
Author(s):  
Amandeep Kaur ◽  
Munish Saini

In the software system, the code snippets that are copied and pasted in the same software or another software result in cloning. The basic cause of cloning is either a programmer‘s constraint or language constraints. An increase in the maintenance cost of software is the major drawback of code clones. So, clone detection techniques are required to remove or refactor the code clone. Recent studies exhibit the abstract syntax tree (AST) captures the structural information of source code appropriately. Many researchers used tree-based convolution for identifying the clone, but this technique has certain drawbacks. Therefore, in this paper, the authors propose an approach that finds the semantic clone through square-based convolution by taking abstract syntax representation of source code. Experimental results show the effectiveness of the approach to the popular BigCloneBench benchmark.


Author(s):  
Chavi Ralhan ◽  
Rakesh Bishnoi ◽  
Ankit ◽  
Anjali ◽  
Hitesh Kumar

Copied code or code clones are a sort of code that contrarily affect the improvement and support of software frameworks. Software clone research in the past generally cantered around the discovery. what's more, examination of code clones, while research lately reaches out to the entire range of clone the board. In the last decade, three reviews showed up in the writing, which cover the recognition, examination and transformative attributes of code clones. This paper presents a complete overview on the state of the workmanship in clone the board, with top to bottom examination of clone the executives exercise (e.g., following, refactoring, cost benefit investigation) past the recognition and examination. This is the main overview on clone the board, where we highlight the accomplishments up until now, and uncover roads for additional exploration essential towards an incorporated clone the board framework. We accept that we have worked really hard in studying the territory of clone the board and that this work may fill in as a guide for future research in the area.


Symmetry ◽  
2021 ◽  
Vol 13 (3) ◽  
pp. 447
Author(s):  
Aditi Gupta ◽  
Rinkaj Goyal

Software clones are code fragments with similar or nearly similar functionality or structures. These clones are introduced in a project either accidentally or deliberately during software development or maintenance process. The presence of clones poses a significant threat to the maintenance of software systems and is on the top of the list of code smell types. Clones can be simple (fine-grained) or high-level (coarse-grained), depending on the chosen granularity of code for the clone detection. Simple clones are generally viewed at the lines/statements level, whereas high-level clones have granularity as a block, method, class, or file. High-level clones are said to be composed of multiple simple clones. This study aims to detect high-level conceptual code clones (having granularity as java methods) in java-based projects, which is extendable to the projects developed in other languages as well. Conceptual code clones are the ones implementing a similar higher-level abstraction such as an Abstract Data Type (ADT) list. Based on the assumption that “similar documentation implies similar methods”, the proposed mechanism uses “documentation” associated with methods to identify method-level concept clones. As complete documentation does not contribute to the method’s semantics, we extracted only the description part of the method’s documentation, which led to two benefits: increased efficiency and reduced text corpus size. Further, we used Latent Semantic Indexing (LSI) with different combinations of weight and similarity measures to identify similar descriptions in the text corpus. To show the efficacy of the proposed approach, we validated it using three java open source systems of sufficient length. The findings suggest that the proposed mechanism can detect methods implementing similar high-level concepts with improved recall values.


2021 ◽  
Vol 9 (1) ◽  
pp. 20-36
Author(s):  
Mostefai Abdelkader

Software clone detection is a widely researched area over the last two decades. Code clones are fragments of code judged similar by some metric of similarity. This paper proposes an approach for code clone detection using dynamic time warping technique (i.e., DTW). DTW is a well-known algorithm for aligning and measuring similarity of time series and it has been found effective in many domains where similarity plays an important role such as speech and gesture recognition. The proposed approach finds clones in three steps. First software modules are extracted. Then, the extracted modules are turned to time series. Finally, the time series are compared using the DTW algorithm to find clones. The results of the experiment conducted on a well-known Benchmark show that the approach can detect clones effectively in software systems.


Sign in / Sign up

Export Citation Format

Share Document