Re: [PATCH 1/1] commit-graph.c: avoid unnecessary tag dereference when merging
- From
Derrick Stolee <stolee@gmail.com>
- Date
- Mar 22, 2020, 00:03 UTC
- Message-ID
- <a0de34e3-3f60-1838-dbaf-2ee3dddc7c89@gmail.com>
- In-Reply-To
- <xmqqfte1a6ew.fsf@gitster.c.googlers.com>
On 3/21/2020 2:50 PM, Junio C Hamano wrote:
> Do we need to worry about INFO_QUICK and SKIP_FETCH_OBJECT in this > codepath, by the way?
I was coming back to this thread to bring up these exact flags for consideration. The good news is that in a partial clone with any amount of filtering we will still have all reachable commits, which are necessary for the commit-graph to make sense. The only ones that would fail has_object_file() are ones removed by GC, but they may still exist on the remote. So without SKIP_FETCH_OBJECT, we would generate a network call even if the server has GC'd to remove the commits. This gets particularly bad when the server returns all reachable objects from that commit!
Thanks, -Stolee