一句话:实证评估 Git 分支处理对文件修改历史挖掘及常用推荐/预测技术性能的影响。
现代分布式版本控制系统支持分支,但 MSR 研究对合并提交与分支的挖掘缺乏统一方法,且不清楚考虑分支会在多大程度上影响基于文件修改历史的研究结论。本文分析四个开源生态中 1,400 多个 Git 仓库、200 多万个文件,比较两种文件修改历史算法:仅沿提交第一父节点遍历,以及跨所有分支返回完整历史。实验表明两种算法结果持续不同,但差异规模随项目和生态变化。进一步用依赖文件历史的评审者推荐、变更推荐和缺陷预测任务评估,发现使用完整文件历史带来的性能提升相当有限。
Modern distributed version control systems, such as Git, offer support for branching — the possibility to develop parts of software outside the master trunk. Consideration of the repository structure in Mining Software Repository (MSR) studies requires a thorough approach to mining, but there is no well-documented, widespread methodology regarding the handling of merge commits and branches. Moreover, there is still a lack of knowledge of the extent to which considering branches during MSR studies impacts the results of the studies. In this study, we set out to evaluate the importance of proper handling of branches when calculating file modification histories. We analyze over 1,400 Git repositories of four open source ecosystems and compute modification histories for over two million files, using two different algorithms. One algorithm only follows the first parent of each commit when traversing the repository, the other returns the full modification history of a file across all branches. We show that the two algorithms consistently deliver different results, but the scale of the difference varies across projects and ecosystems. Further, we evaluate the importance of accurate mining of file histories by comparing the performance of common techniques that rely on file modification history — reviewer recommendation, change recommendation, and defect prediction — for two algorithms of file history retrieval. We find that considering full file histories leads to an increase in the techniques’ performance that is rather modest.