From: david@lang.hm Date: Thu, 28 Aug 2008 17:26:15 GMT Subject: Re: Git-aware HTTP transport Message-ID: In-Reply-To: <20080828145706.GB21072@spearce.org> On Thu, 28 Aug 2008, Shawn O. Pearce wrote: > Junio C Hamano wrote: >> "Shawn O. Pearce" writes: >> >> It appears that you really meant "Binary", as opposed to "Hexadecimal" >> that show-ref example illustrate, judging from the later 3,276 number. >> I'd prefer hexadecimal here. > > Yes, I really did mean for this part of the protocol to be in binary. > We have to exchange a bunch of commits to figure out what is common. > The binary form is 1/2 the size of the hexadecimal form, resulting > in fewer TCP packets for the same request. except that HTTP cannot transport binary data, if you feed it binary data it then encodes it into 7-bit safe forms for transport. while it's true that it can pack it more efficiantly than hex, it's not double the density. > Reading/writing the SHA-1s in binary is usually faster than doing > it in hex; you don't have to go through the formatting routines. > So there's a few less CPU cycles on the server end. except you then need to go through the formatting routines to send it via HTTP. David Lang