Re: [PATCH v2] add: add --bulk to index all objects into a pack file
Nguyễn Thái Ngọc Duy pclo...@gmail.com writes: except that it does not deltifies nor sort objects. I think this should be mentionned in the doc. Otherwise, it seems like git add --bulk is like git add git repack. BTW, will the next git gc be efficient after a add --bulk? I mean: will it consider the pack as already pack and let it as-is, without deltification, or will it get a chance to actually repack efficiently? -- Matthieu Moy http://www-verimag.imag.fr/~moy/ -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] add: add --bulk to index all objects into a pack file
On Fri, Oct 4, 2013 at 2:10 PM, Matthieu Moy matthieu@grenoble-inp.fr wrote: Nguyễn Thái Ngọc Duy pclo...@gmail.com writes: except that it does not deltifies nor sort objects. I think this should be mentionned in the doc. Otherwise, it seems like git add --bulk is like git add git repack. Yep. Will do. BTW, will the next git gc be efficient after a add --bulk? I mean: will it consider the pack as already pack and let it as-is, without deltification, or will it get a chance to actually repack efficiently? gc does repack -A so all separate packs will be merged. It may delay gc time though because it'll take more time to hit the loose object limit. I think pack-objects will try to deltify so we're good. If we produce bad deltas in --bulk then that's another story because pack-objects will try to blindly reuse them. -- Duy -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] add: add --bulk to index all objects into a pack file
On Fri, Oct 4, 2013 at 1:57 PM, Nguyễn Thái Ngọc Duy pclo...@gmail.com wrote: It's not an all-win situation though. --bulk is slower than --no-bulk because: - Triple hashing: we need to calculate both object SHA-1s _and_ pack SHA-1. At the end we have to fix up the pack, which means rehashing the entire pack again. --no-bulk only cares about object SHA-1s. Oops, it's quadruple hashing: one for object sha-1 (1), one for pack sha-1 while writing pack (2), two for pack header fixup: one after the the header fixup (3), and one repeating the same (2) just to verify that it matches (2) exactly (4). Do we have to be this paranoid? I think we could drop (2) and (4) in this case. -- Duy -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html