On Tue, 18 Oct 2005, Junio C Hamano wrote: > > It strikes me that we could walk from our refs, depth reasonably > limited to say 20 or so commit chain and/or last 5 days of > commit time, to see if any of the remotes are reachable from our > refs and omit issuing "want" quite cheaply. Do you think that > would be a worthy change to make things more efficient? Probably doesn't make a huge difference, but it might be worth trying. There's a cheap test you can do _before_ you even start walking: check if you have the object that is pointed to by the remote ref at all. If you don't have it, then you know it can't be reachable from any of the local refs. And if you do have it, the likelihood that it _is_ reachable is likely pretty high. (I didn't do that for the current fetch-pack optimization, since just doing the read_ref() is likely faster than even bothering with the object lookup. But if you start traversing commit lists, it suddenly becomes more worthwhile). You'd need to look up the object anyway in order to figure out that it's a commit (or points to a commit). So it might be wasting a bit of time, but the good news is that it wastes time on the _client_ side, where we've got plenty. I'll see if I can come up with a good patch. Linus - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.htmlReceived on Wed Oct 19 06:39:17 2005
This archive was generated by hypermail 2.1.8 : 2005-10-19 06:39:20 EST