merge-ort: resolve paths early when we have sufficient information
commit785bf2088e54ed8a450edb5c7371286ff6405605
authorElijah Newren <newren@gmail.com>
Fri, 16 Jul 2021 05:22:31 +0000 (16 05:22 +0000)
committerJunio C Hamano <gitster@pobox.com>
Tue, 20 Jul 2021 21:47:39 +0000 (20 14:47 -0700)
treed0b6736e7b21d62e4c071a3456dd9d3149ded086
parentdaab8a564f8bbac55f70f8bf86c070e001a9b006
merge-ort: resolve paths early when we have sufficient information

When there are no directories involved at a given path, and all three
sides have a file at that path, and two of the three sides of history
match, we can immediately resolve the merge of that path in
collect_merge_info() and do not need to wait until process_entries().

This is actually a very minor improvement: half the time when I run it,
I see an improvement; the other half a slowdown.  It seems to be in the
range of noise.  However, this idea serves as the beginning of some
bigger optimizations coming in the following patches.

Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
merge-ort.c