paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Can Program Synthesis be Used to Learn Merge Conflict Resolutions? An Empirical Analysis

程序合成能否用于学习合并冲突解决方案?一项实证分析
ICSE 2021 IEEE/ACM 43rd International Conference on Software Engineering (ICSE)2021匹配度 3/10 · 论文将程序合成与DSL用于合并冲突解决,属于软件工程/程序合成应用,但用户核心关注静态分析/形式化验证与LLM/Agent的交叉,以及浮点或贝叶斯程序分析,本文均未涉及。虽包含Microsoft Edge工业实证和从示例学习DSL,但与研究画像核心方向匹配度较低。引用 33 inbox
Rangeet Pan, Vu Le, Nachiappan Nagappan, Sumit Gulwani, Shuvendu Lahiri, Mike Kaufman
crossref: 2026-09-12dblp: 2026-09-12arxiv: 2026-09-12

AI 速览

一句话:首次将程序合成用于学习合并冲突解决:提出DSL从示例学习策略,可解决11.4%冲突且准确率93.2%。

本文以 Microsoft Edge(从 Chromium 主线分叉的大规模协作项目)为背景,研究文本合并冲突问题。作者首先对 Edge 中的文本合并冲突进行实证分析,按文件类型、冲突在文件中的位置和冲突规模分类,发现约 28% 的冲突仅为 1-2 行改动,且许多解决方案具有重复模式。受此启发,作者首次探索用程序合成学习并解决结构性合并冲突:提出一种新的领域特定语言(DSL)来刻画常见解决模式,并从示例解决方案中学习该 DSL 程序作为解决策略。评估表明,学到的策略能解决 C++ 文件中 11.4% 的冲突(约占 1-2 行改动的 41%),准确率达 93.2%。

问题
大规模开源分叉(如 Microsoft Edge 从 Chromium 分叉)中频繁出现文本合并冲突,人工解决成本高,且缺乏对其模式和自动解决可行性的系统研究。
方法
先对 Edge 的合并冲突进行实证分类,再提出捕获重复解决模式的领域特定语言(DSL),并从示例解决方案中合成解决策略程序。
评估
在 Microsoft Edge 的 C++ 文件合并冲突上评估,所学策略解决 11.4% 的总冲突(约 41% 的 1-2 行改动),准确率为 93.2%。
原文摘要(Abstract)

Forking structure is widespread in the open-source repositories and that causes a significant number of merge conflicts. In this paper, we study the problem of textual merge conflicts from the perspective of Microsoft Edge, a large, highly collaborative fork off the main Chromium branch with significant merge conflicts. Broadly, this study is divided into two sections. First, we empirically evaluate textual merge conflicts in Microsoft Edge and classify them based on the type of files, location of conflicts in a file, and the size of conflicts. We found that ~28% of the merge conflicts are 1-2 line changes, and many resolutions have frequent patterns. Second, driven by these findings, we explore Program Synthesis (for the first time) to learn patterns and resolve structural merge conflicts. We propose a novel domain-specific language (DSL) that captures many of the repetitive merge conflict resolution patterns and learn resolution strategies as programs in this DSL from example resolutions. We found that the learned strategies can resolve 11.4% of the conflicts (~41% of 1-2 line changes) that arise in the C++ files with 93.2% accuracy.

链接与引用

DOI 原文 · arXiv · PDF(开放获取) · DBLP

BibTeX
@inproceedings{PanLNGLK21,
  title = {Can Program Synthesis be Used to Learn Merge Conflict Resolutions? An Empirical Analysis},
  author = {Rangeet Pan and Vu Le and Nachiappan Nagappan and Sumit Gulwani and Shuvendu Lahiri and Mike Kaufman},
  booktitle = {ICSE},
  year = {2021},
  doi = {10.1109/icse43902.2021.00077}
}