Blame Trees
Name
Demaine_Blame trees.pdf
Size
264.69 KB
Format
Adobe PDF
Checksum (MD5)
22c029242a1cca5192e1130f55938759
Author(s) • • •
Demaine, Erik D.
Panchekha, Pavel
Wilson, David A.
Yang, Edward Z.
Date Issued
2013
Journal
Algorithms and Data Structures
Publisher
Springer-Verlag Berlin Heidelberg
Citation
Demaine, Erik D., Pavel Panchekha, David A. Wilson, and Edward Z. Yang. “Blame Trees.” In Algorithms and Data Structures: 13th International Symposium, WADS 2013, London, ON, Canada, August 12-14, 2013. Proceedings (Lecture Notes in Computer Science; vol. 8037) (2013): 280–290.
Version
Author's final manuscript
Abstract
We consider the problem of merging individual text documents, motivated by the single-file merge algorithms of document-based version control systems. Abstracting away the merging of conflicting edits to an external conflict resolution function (possibly implemented by a human), we consider the efficient identification of conflicting regions. We show how to implement tree-based document representation to quickly answer a data structure inspired by the “blame” query of some version control systems. A “blame” query associates every line of a document with the revision in which it was last edited. Our tree uses this idea to quickly identify conflicting edits. We show how to perform a merge operation in time proportional to the sum of the logarithms of the shared regions of the documents, plus the cost of conflict resolution. Our data structure is functional and therefore confluently persistent, allowing arbitrary version DAGs as in real version-control systems. Our results rely on concurrent traversal of two trees with short circuiting when shared subtrees are encountered.
MIT Department
Massachusetts Institute of Technology. Department of Electrical Engineering and Computer Science
Terms of Use
Creative Commons Attribution-Noncommercial-Share Alike
Persistent DSpace Link
DOI of Published Version
https://doi.org/10.1007/978-3-642-40104-6_25