Thread (10 messages) flat view 10 messages, 4 authors, 2016-06-15

Re: [PATCH 4/8] git-repack --max-pack-size: add fixup_header_footer()

From: Nicolas Pitre <hidden>
Date: 2016-06-15 22:43:03

On Mon, 9 Apr 2007, Dana How wrote:
Wouldn't the following address the "object count unknown
at the start of sequential pack writing" problem:
 Write 0 for object count in the header. This is a flag to look for
 another header of same format just before the final SHA-1 which
 has the correct count. The SHA-1 is still a checksum of everything
 before it and no seeking/rewriting is needed on generation.
No.  You really wants to know up front how many objects a pack contains 
when streaming it.  And this is not only for packs written to stdout.
Finally, when I generate several 2GB split packfiles,  I do notice
the slight delay for fixup_header_footer(), and I do think it's a bit
ugly, but in quantitative terms it's an insignificant part of a long
operation that's infrequently performed.  Does this need to be
optimized at all?
Maybe, maybe not.  That depends how much data we think GIT could be used 
to manage in the future.  With a 1TB pack file you definitely want to 
optimize that case.

OTOH this could wait for the real pack v4 too.


Nicolas
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help