Code implementing a crosscutting concern is often spread over many different parts of an application. Identifying such code automatically greatly improves both the maintainability and the evolvability of the application. First of all, it allows a developer to more easily find the places in the code that must be changed when the concern changes, and thus makes such changes less time consuming and less prone to errors. Second, it allows a developer to refactor the code, so that it uses modern and more advanced abstraction mechanisms, thereby restoring its modularity. In this paper, we evaluate the suitability of clone detection as a technique for the identification of crosscutting concerns. To that end, we manually identify four specific concerns in an industrial C application, and analyze to what extent clone detection is capable of finding these concerns. We consider our results as a stepping stone toward an automated 'concern miner' based on clone detection.

CWI
Software Engineering [SEN]
Software Analysis and Transformation

Bruntink, M., van Deursen, A., van Engelen, R., & Tourwé, T. (2004). An evaluation of clone detection techniques for identifying crosscutting concerns. Software Engineering [SEN]. CWI.