Improving the Unification of Software Clones using Tree and Graph Matching Algorithms
Code duplication is common in all kind of software systems and is one of the most troublesome hurdles in software maintenance and evolution activities. Even though these code clones are created for the reuse of some functionality, they usually go through several modifications after their initial int...
id |
ndltd-LACETR-oai-collectionscanada.gc.ca-QMG.978599 |
---|---|
record_format |
oai_dc |
spelling |
ndltd-LACETR-oai-collectionscanada.gc.ca-QMG.9785992014-07-04T04:42:00Z Improving the Unification of Software Clones using Tree and Graph Matching Algorithms Panamoottil Krishnan, Giri Code duplication is common in all kind of software systems and is one of the most troublesome hurdles in software maintenance and evolution activities. Even though these code clones are created for the reuse of some functionality, they usually go through several modifications after their initial introduction. This has a serious negative impact on the maintainability, comprehensibility, and evolution of software systems. Existing code duplication can be eliminated by extracting the common functionality into a single module. In the past, several techniques have been developed for the detection and management of software clones. However, the unification and refactoring of software clones is still a challenging problem, since the existing tools are mostly focused on clone detection and there is no tool to find particularly refactoring-oriented clones. The programmers need to manually understand the clones returned by the clone detection tools, decide whether they should be refactored, and finally perform their refactoring. This obvious gap between the clone detection tools and the clone analysis tools, makes the refactoring tedious and the programmers reluctant towards refactoring duplicate codes. In this thesis, an approach for the unification and refactoring of software clones that overcomes the limitations of previous approaches is presented. More specifically, the proposed technique is able to detect and parameterize non-trivial differences between the clones. Moreover, it can find a mapping between the statements of the clones that minimizes the number of differences. We have also defined preconditions in order to determine whether the duplicated code can be safely refactored to preserve the behavior of the existing code. We compared the proposed technique with a competitive clone refactoring tool and concluded that our approach is able to find a significantly larger number of refactorable clones. 2014-04-28 Thesis NonPeerReviewed application/pdf http://spectrum.library.concordia.ca/978599/1/PanamoottilKrishnan_MCompSc_S2014.pdf Panamoottil Krishnan, Giri <http://spectrum.library.concordia.ca/view/creators/Panamoottil_Krishnan=3AGiri=3A=3A.html> (2014) Improving the Unification of Software Clones using Tree and Graph Matching Algorithms. Masters thesis, Concordia University. http://spectrum.library.concordia.ca/978599/ |
collection |
NDLTD |
format |
Others
|
sources |
NDLTD |
description |
Code duplication is common in all kind of software systems and is one of the most troublesome hurdles in software maintenance and evolution activities. Even though these code clones are created for the reuse of some functionality, they usually go through several modifications after their initial introduction. This has a serious negative impact on the maintainability, comprehensibility, and evolution of software systems.
Existing code duplication can be eliminated by extracting the common functionality into a single module. In the past, several techniques have been developed for the detection and management of software clones. However, the unification and refactoring of software clones is still a challenging problem, since the existing tools are mostly focused on clone detection and there is no tool to find particularly refactoring-oriented clones. The programmers need to manually understand the clones returned by the clone detection tools, decide whether they should be refactored, and finally perform their refactoring. This obvious gap between the clone detection tools and the clone analysis tools, makes the refactoring tedious and the programmers reluctant towards refactoring duplicate codes.
In this thesis, an approach for the unification and refactoring of software clones that overcomes the limitations of previous approaches is presented. More specifically, the proposed technique is able to detect and parameterize non-trivial differences between the clones. Moreover, it can find a mapping between the statements of the clones that minimizes the number of differences. We have also defined preconditions in order to determine whether the duplicated code can be safely refactored to preserve the behavior of the existing code. We compared the proposed technique with a competitive clone refactoring tool and concluded that our approach is able to find a significantly
larger number of refactorable clones. |
author |
Panamoottil Krishnan, Giri |
spellingShingle |
Panamoottil Krishnan, Giri Improving the Unification of Software Clones using Tree and Graph Matching Algorithms |
author_facet |
Panamoottil Krishnan, Giri |
author_sort |
Panamoottil Krishnan, Giri |
title |
Improving the Unification of Software Clones using Tree and Graph Matching Algorithms |
title_short |
Improving the Unification of Software Clones using Tree and Graph Matching Algorithms |
title_full |
Improving the Unification of Software Clones using Tree and Graph Matching Algorithms |
title_fullStr |
Improving the Unification of Software Clones using Tree and Graph Matching Algorithms |
title_full_unstemmed |
Improving the Unification of Software Clones using Tree and Graph Matching Algorithms |
title_sort |
improving the unification of software clones using tree and graph matching algorithms |
publishDate |
2014 |
url |
http://spectrum.library.concordia.ca/978599/1/PanamoottilKrishnan_MCompSc_S2014.pdf Panamoottil Krishnan, Giri <http://spectrum.library.concordia.ca/view/creators/Panamoottil_Krishnan=3AGiri=3A=3A.html> (2014) Improving the Unification of Software Clones using Tree and Graph Matching Algorithms. Masters thesis, Concordia University. |
work_keys_str_mv |
AT panamoottilkrishnangiri improvingtheunificationofsoftwareclonesusingtreeandgraphmatchingalgorithms |
_version_ |
1716706764869599232 |