A study of the uniqueness of source code
Authors:
Open Access
- 7 November 2010
- conference paper
- Published by Association for Computing Machinery (ACM)
- p. 147-156
Abstract
This paper presents the results of the first study of the uniqueness of source code. We define the uniqueness of a unit of source code with respect to the entire body of written software, which we approximate with a corpus of 420 million lines of source code. Our high-level methodology consists of examining a collection of 6,000 software projects and measuring the degree to which each project can be `assembled' solely from portions of this corpus, thus providing a precise measure of `uniqueness' that we call syntactic redundancy. We parameterized our study over a variety of variables, the most important of which being the level of granularity at which we view source code. Our suite of experiments together consumed approximately four months of CPU time, providing quantitative answers to the following questions: at what levels of granularity is software unique, and at a given level of granularity, how unique is software? While we believe these questions to be of intrinsic interest, we discuss possible applications to genetic programming and developer productivity tools.Keywords
This publication has 14 references indexed in Scilit:
- Amassing and indexing a large sample of version control systems: Towards the census of public source code history2009
- Semi-automating small-scale source code reuse via structural correspondence2008
- CodeGenie2007
- DECKARD: Scalable and Accurate Tree-Based Detection of Code Clones29th International Conference on Software Engineering (ICSE'07), 2007
- Very-Large Scale Code Clone Analysis and Visualization of Open Source Programs Using Distributed CCFinder: D-CCFinder29th International Conference on Software Engineering (ICSE'07), 2007
- Large-Scale Code Reuse in Open Source Software2007
- Sourcerer2006
- Cloning by accident: an empirical study of source code cloning across software systems2005
- CCFinder: a multilinguistic token-based code clone detection system for large scale source codeIEEE Transactions on Software Engineering, 2002
- Retrieving reusable software by sampling behaviorACM Transactions on Software Engineering and Methodology, 1993