From: Junio C Hamano <gitster@pobox.com>
To: Orgad Shaneh <orgads@gmail.com>
Cc: Orgad Shaneh via GitGitGadget <gitgitgadget@gmail.com>,
git <git@vger.kernel.org>
Subject: Re: [PATCH v2] fetch: limit shared symref check only for local branches
Date: Wed, 18 May 2022 08:50:46 -0700 [thread overview]
Message-ID: <xmqqilq2yh49.fsf@gitster.g> (raw)
In-Reply-To: <CAGHpTBK_K+GK5z3XD-7ob7JPLrUnohfMCRVD2wrwbMhDyy3TEw@mail.gmail.com> (Orgad Shaneh's message of "Tue, 17 May 2022 13:41:14 +0300")
Orgad Shaneh <orgads@gmail.com> writes:
> This would require shuffling the code. check_not_current_branch() is
> called by do_fetch before fetch_and_consume_refs (which updates
> ref->old_oid and ref->new_oid).
Oh, that's unfortunate.
We may not be matching them with the current values of the local
copies in ref_map in today's code until fetch_and_consume_refs()
calls store_updated_refs() to update the .new_oid member, but I
would have thought that we learned the equivalent of "git ls-remote"
output a lot earlier, at least most of the time, via a call to
transport_get_remote_refs(), and that was why I thought such an
optimization was doable.
Thanks.
prev parent reply other threads:[~2022-05-18 15:51 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-16 8:37 [PATCH] fetch: limit shared symref check only for local branches Orgad Shaneh via GitGitGadget
2022-05-16 8:41 ` [PATCH v2] " Orgad Shaneh via GitGitGadget
2022-05-16 16:00 ` Junio C Hamano
2022-05-16 17:57 ` Junio C Hamano
2022-05-17 6:05 ` Orgad Shaneh
2022-05-17 10:27 ` Junio C Hamano
2022-05-17 10:41 ` Orgad Shaneh
2022-05-18 15:50 ` Junio C Hamano [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqilq2yh49.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=orgads@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.