diff options
author | Julian Phillips <julian@quantumfyre.co.uk> | 2009-09-17 08:33:19 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-09-18 16:32:33 -0700 |
commit | e984c54ada086e7676419b6b1b8a2d7a2429da48 (patch) | |
tree | 34f5a36c98b2f7daef4ff7f4ba9442aa659b0448 /transport.c | |
parent | Merge 1.6.4.4 in (diff) | |
download | tgif-e984c54ada086e7676419b6b1b8a2d7a2429da48.tar.xz |
fetch: Speed up fetch by rewriting find_non_local_tags
When trying to get a list of remote tags to see if we need to fetch
any we were doing a linear search for the matching tag ref for the
tag^{} commit entries. This proves to be incredibly slow for large
numbers of tags. Rewrite the function so that we build up a
string_list of refs to fetch and then process that instead.
As an extreme example, for a repository with 50000 tags (and just a
single commit on a single branch), a fetch that does nothing goes from
~1m50s to ~4.1s.
Signed-off-by: Julian Phillips <julian@quantumfyre.co.uk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport.c')
0 files changed, 0 insertions, 0 deletions