This specification relates to static analysis of computer software source code.
Static analysis refers to techniques for analyzing computer software source code without executing the source code as a computer software program. Static analysis may rely on one or more characteristic metrics associated with software development projects. Using characteristics metrics, static analysis systems attempt to determine accurate and reliable conclusions about various properties of software development projects. Such conclusions may be used for a variety of purposes, including software performance optimization, software debugging, and software development cost estimation.
Static analysis can be performed on a code base, which is a collection of source code files that is typically maintained by a version control system. Version control systems generally maintain multiple revisions of the source code in the code base, each revision being referred to as a snapshot. Each snapshot is a view of the source code of files of the code base as the files existed at a particular point in time. Snapshots stored in a version control system can be represented as a directed, acyclical revision graph. Each node in the revision graph represents a commit of the source code. A commit represents a snapshot as well as other pertinent information about the snapshot such as the author of the snapshot, and data about ancestor commits of the node in the revision graph.
In this specification, the term “software project,” or for brevity, a “project,” is a collection of source code files organized in a particular way, e.g., in a hierarchical directory structure, with each source code file in the project having a respective path. Each project has one or more respective owners. Typically, the source code files in a project provide one or more related functionalities.
Characteristic metrics associated with a software development project may be derived from the computer software code associated with a software development project, from the information associated with the development of the project maintained by a project development environment, from specification documents associated with the software development project, and from external information associated with third-party interactions with the software development project.