diff options
author | Elijah Newren <newren@gmail.com> | 2021-02-03 20:03:46 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-02-12 12:04:00 -0800 |
commit | f15eb7c1cf2674df69c1ff8aebdc5536a580c65e (patch) | |
tree | 77e58af6bb73bba6ffc548f4ba6e327e72ec4570 /refs.h | |
parent | Sync with maint (diff) | |
download | tgif-f15eb7c1cf2674df69c1ff8aebdc5536a580c65e.tar.xz |
diffcore-rename: no point trying to find a match better than exact
diffcore_rename() had some code to avoid having destination paths that
already had an exact rename detected from being re-checked for other
renames. Source paths, however, were re-checked because we wanted to
allow the possibility of detecting copies. But if copy detection isn't
turned on, then this merely amounts to attempting to find a
better-than-exact match, which naturally ends up being an expensive
no-op. In particular, copy detection is never turned on by the merge
machinery.
For the testcases mentioned in commit 557ac0350d ("merge-ort: begin
performance work; instrument with trace2_region_* calls", 2020-10-28),
this change improves the performance as follows:
Before After
no-renames: 14.263 s ± 0.053 s 14.119 s ± 0.101 s
mega-renames: 5504.231 s ± 5.150 s 1802.044 s ± 0.828 s
just-one-mega: 158.534 s ± 0.498 s 51.391 s ± 0.028 s
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'refs.h')
0 files changed, 0 insertions, 0 deletions