Constructing universal version history
Hung-Fu Chang, Audris Mockus · 2006
Developers often copy code for parts or entire products to start a new product or a new release. In order to understand the software change history and to determine the code authorship, we propose to construct a universal version history from multiple version control repositories. To that end we create two practical code copy detection methods at the level of the source code file: prefix-postfix algorithm and prefix algorithm. The full pathname of a file and its version history are used to construct the universal version history of a file by linking together change histories of files that had the same code at any point in the past. The assumption of both algorithms is that developers often duplicate files by copying entire directories. Once the copying is identified we propose an algorithm to link version histories from multiple repositories in order to construct universal version history. The results show that about 41.32% of source files (in the repository involving more than 6M versions of around 2M files) were duplicated among the Avaya's source code repositories for more than ten different projects. The prefix-postfix algorithm is more suitable than prefix algorithm due to the reasonable error rates after validation of the known copying behaviors.
Cited by 10 works. doi:10.1145/1137983.1138002
Authors
References
- CCFinder: a multilinguistic token-based code clone detection system for large scale source code
- Clone detection using abstract syntax trees
- On finding duplication and near-duplication in large software systems
- A language independent approach for detecting duplicated code
- Assessing the benefits of incorporating function clone detection in a development process
- Software quality analysis by code clones in industrial legacy software
- Improved tool support for the investigation of duplication in software
- 2013 IEEE International Conference on Software Maintenance