Detail

Publication date: 1 de June, 2021

On the relationship between code cloning and maintenance

Code clones can improve programmer productivity through reuse of
semantic or syntactic constructs. However, they may increase the
software maintenance effort by introducing unnecessary hidden
dependencies. We investigated the relationships between clones and
maintenance effort. Given that maintenance comprises a substantial
proportion of the total software production effort, it is pertinent to
determine whether or not cloning is a significant threat to effective
software maintenance.

We presents a framework that extracts the history of cloned methods and
analyzes it automatically. For each cloned method and each pair of
cloned methods, the analysis compares, respectively, the amount and
frequency of change and cochange in periods when methods are cloned
versus periods when they are not.

The utility of our approach is validated through application to two Java
open source projects. The results show that clones are mostly stable
code. There is an increase of change and co-change in cloned periods,
but the frequency of change on cloned periods is at best similar and
even lower than for not cloned periods. We therefore think that there is
not enough evidence to suggest that clones have a noticeable impact on
maintenance effort.

Presenter

Michel Wermelinger,

Date 02/11/2006
State Concluded