Re: using xdl_merge(), was Re: Resolving conflicts
- From
Junio C Hamano <junkio@cox.net>
- Date
- Dec 5, 2006, 18:43 UTC
- Message-ID
- <7vwt56gp45.fsf@assigned-by-dhcp.cox.net>
- In-Reply-To
- <Pine.LNX.4.64.0612051023460.3542@woody.osdl.org>
Linus Torvalds <torvalds@osdl.org> writes:
Show 35 quoted lines
> On Tue, 5 Dec 2006, Ramsay Jones wrote:
>>
>> Have you had time to look at my test cases?
>> As I said, I found them very useful when debugging
>> my git-diff3 code, and (hopefully) you will find them
>> to be equally useful.
>
> It might be interesting to also do a simple test:
>
> - take every single merge in git (or the kernel, if you want even more)
>
> - ignore all the trivial ones that didn't have any file-level merging at
> all (ie done entirely in the index)
>
> - for all the rest, just compare what the end result is when re-doing the
> merge with "xdl_merge" vs "external 3-way merge".
>
> [ Side note: DO NOT COMPARE AGAINST THE ACTUAL RESULT IN GIT OR IN THE
> KERNEL ARCHIVE! Those will obviously have been fixed up by humans in the
> event of a data conflict, and sometimes even in the _absense_ of a data
> conflict (ie "git commit --amend" to fix up something that got mismerged
> perfectly automatically or whatever).
>
> So a script should literally re-do the merge two ways, and compare the
> end result ]
>
> Is that any "proof"? Of course not. And it will probably show differences
> due to any conflict handling, but a lot of the time you'd expect to get
> exactly the same end result, so the occasional differences are going to be
> just all the more interesting ("it resolved differently, but it was
> an equally good resolve" is interesting data on its own).
>
> Anybody want to write a small script to do this?
>
> LinusI was planning to do this today anyway. Thanks for the reminder.