git/list[1] front-page[2] threads[3] people[4] search[5] about
 

RFC: Merge-related plans

From
Elijah Newren <newren@gmail.com>
Date
May 28, 2018, 20:48 UTC
Message-ID
<CABPp-BFQJZHfCJZ1qvhvVcMd-_sOfi0Fkm5PexEwzzN+Zw2akw@mail.gmail.com>
Hi everyone,

I have some merge-related plans (and work in progress) that I'd like to get some feedback on in order to find what order would be best to address things in, if there are special steps I should take while approaching some of the bigger items, and even if folks disagree with any of the plans.

Currently, I would like to:
A) Fix cases where directory rename detection does not work with
   rebase/am due to how they call merge-recursive.
   Notes: Could just wait for D & E to land before fixing.
   Alternatively, email RFC to list now explaining issues and how the
   fix has performance implications; poll for opinions on whether to
   fix before or after D.
B) Implement a remerge-diff ability (compare a merge commit to what an
   "automatic merge" would look like)[1].
   Notes: Possibly for cherry-picks and reverts too.  Depends on C &
   E.
C) Modify/extend how path-based and mode-based conflicts are
   communicated to the user.
   Notes: Particularly important as a mechanism for handling
   challenges[2] with implementing the remerge-diff ability.  Need to
   send RFC to list with ideas to get feedback.
D) Improve merge performance.
   Notes: Includes 4-5 specific optimizations[5], some of which I
   expect to be somewhat invasive and thus may make more sense to just
   make part of the new merge strategy implemented in E.  Biggest
   optimization depends on F.
E) Write a new merge strategy meant to replace merge-recursive.
   Notes: Suggested by Junio[3][4].  Depends on F & G.
F) Make file collision conflict types more consistent.
   Notes: Specifically, make rename/rename(2to1) & rename/add
   conflicts behave more like add/add[6][7].  Depends on part of G.
   Would prefer H to be accepted first.
G) Improve merge-related portion of testsuite.
   Notes: Intended to help test new merge strategy with more
   confidence.  Will include approximately a dozen edge and corner
   cases where merge-recursive currently falls short.  Started at [8];
   see also [9].
H) Miscellaneous code cleanups irritating me while working on other
   changes[10].
My current plan was to work roughly in reverse, from H to A.  Some questions:
  * Does any of this look objectionable?
  * Should I post RFC questions on A and C earlier?
  * Should I split D and G?  (Current plan was to keep D together, but
    split G into five short slightly inter-dependent topics)
  * E is kind of big.  Are there any specific things folks would like to see
    with how that is handled?

Thanks, Elijah

[1] https://bugs.chromium.org/p/git/issues/detail?id=12 [remerge-diff]
[2] https://public-inbox.org/git/CABPp-BEsTOZ-tCvG1y5a0qPB8xJLLa0obyTU===mBgXC1jXgFA@mail.gmail.com/
    [remerge-diff challenges]
[3] https://public-inbox.org/git/xmqqd147kpdm.fsf@gitster.mtv.corp.google.com/
    [Ideal world merge strategy]
[4] https://public-inbox.org/git/xmqqk1ydkbx0.fsf@gitster.mtv.corp.google.com/
    [New strategy]
[5] Some of which are included in
    https://public-inbox.org/git/20171120221944.15431-1-newren@gmail.com/
    [perf improvements]
[6] https://public-inbox.org/git/CAPc5daVu8vv9RdGON8JiXEO3ycDVqQ38ySzZc-cpo+AQcAKXjA@mail.gmail.com/
    [discussion of add/add conflict resolution]
[7] https://public-inbox.org/git/20180305171125.22331-1-newren@gmail.com/
    [file collision consistency RFC series]
[8] https://public-inbox.org/git/20180524070439.6367-1-newren@gmail.com/
    [testcase cleanup]
[9] https://public-inbox.org/git/CABPp-BFc1OLYKzS5rauOehvEugPc0oGMJp-NMEAmVMW7QR=4Eg@mail.gmail.com/
    [weird corner cases]
[10] https://public-inbox.org/git/20180522004327.13085-1-newren@gmail.com/
     [code cleanups]
Next: Stefan Beller
Message 1 of 5 in “RFC: Merge-related plans”
  1. Elijah NewrenMay 28, 2018
  2. Stefan BellerMay 29, 2018
  3. Elijah NewrenMay 29, 2018
  4. Stefan BellerMay 29, 2018
  5. Elijah NewrenMay 30, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.