Re: [RFC] pack-objects: compression level for non-blobs
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- Dec 29, 2012, 05:25 UTC
- Message-ID
- <CACsJy8AN3y_4wcZ_w0zz+ZAaDasRT-+h8vA_fp2j4+FL00dbLw@mail.gmail.com>
- In-Reply-To
- <20121229050707.GA14475@sigill.intra.peff.net>
On Sat, Dec 29, 2012 at 12:07 PM, Jeff King <peff@peff.net> wrote:
Show 15 quoted lines
> On Sat, Dec 29, 2012 at 11:34:09AM +0700, Nguyen Thai Ngoc Duy wrote: > >> On Sat, Dec 29, 2012 at 7:41 AM, Jeff King <peff@peff.net> wrote: >> > I wonder if we could do even better, though. For a traversal, we only >> > need to look at the commit header. We could potentially do a progressive >> > inflate and stop before getting to the commit message (which is the bulk >> > of the data, and the part that is most likely to benefit from >> > compression). >> >> Commit cache should solve this efficiently as it also eliminates >> parsing cost. We discussed this last time as a side topic of the >> reachability bitmap feature. > > I agree that a commit cache would solve this (though it can not help the > tree traversal).
Yeah, caching trees efficiently is not easy.
> But just dropping the compression (or doing partial > decompression when we only care about the beginning part) is way less > code and complexity.
I think I tried the partial decompression for commit header and it did not help much (or I misremember it, not so sure).
> There's no cache to manage.
If reachability bitmap is implemented, we'll have per-pack cache infrastructure ready, so less work there for commit cache.
-- Duy