Re: git-index-pack really does suck..
From: Nicolas Pitre <hidden>
Date: 2016-06-15 22:43:02
On Tue, 3 Apr 2007, Linus Torvalds wrote:
All that extra memory is just for SHA1 commit ID information.
I don't see where that might be. The only thing that the paranoia check triggers is: foo = read_sha1_file(blah); memcmp(foo with bar); free(foo); So where is that commit ID information actually stored when using read_sha1_file()?
Btw, even if we don't have any of the objects, if you have tons and tons of objects and do a "git pull", just the *lookup* of the nonexistent objects will be expensive: first we won't find it in any pack, then we'll look at the loose objects, and then we'll look int he pack *again* due to the race avoidance. So looking up nonexistent objects is actually pretty expensive.
Not if you consider that it is performed _while_ receiving (and waiting for) the pack data over the net in the normal case. Nicolas