← Back to team overview

bzr-windows team mailing list archive

Re: Compressing library.zip is probably not worth it

 

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Adrian Wilkins wrote:
> Short, unscientific testing on my work laptop.
> 
> Note that it's bogged down with all the usual corporate antiviral
> leechware, which I suppose makes it more representative of a typical
> Windows machine :-)
> 
> Tested 100 startups (in quick succession) to get an average time [1]
> 
> Results (in average ms per iteration of bzr rocks) :
> 
> 156# & 'C:\Program Files\Bazaar\lib\test-bzr-starttime.ps1'
> Store (16MB) : 318.26
> Deflate (5.8MB) : 335.52
> 
> So ; the difference is around 20ms or 6-7% of startup time, which isn't
> much, but slightly worse.
> 
> 10MB of disk space no one is going to miss.
> 
> Inno Setup uses solid LZMA. The "Store" version of the zip LZMAs better
> than the "Deflate" version.
> 
> MSI uses Deflate AFAICR.
> 
> Since the file is "Store" it should actually deflate better than the
> equivalent folder (it does, 4.9MB vs 5.8MB)
> 
> So - compressing the library.zip file, all round a silly idea.
> 
> 

Thanks for directly testing it. That was, indeed, about what I thought
it was going to be. You are testing the "hot cache" performance, which
is basically when all of that 16MB is already read into the kernel
buffers. So it basically takes 0 time to use them.

It probably only takes 20ms to do the decompression, which is pretty
fast. And for *cold* cache performance, it probably takes more than 20ms
to read 10MB.

Now, if I go find the 15GB of WoW data files, and cat them, I'm sure all
of it cannot be cached in memory. With that, I get about 39MB/s.

So reading 10MB from a cold cache takes 250ms. Which is quite a bit
longer than the 20ms to decompress it.

Though in theory you pay the cold cache time once per boot, and the hot
cache time for all other invocations.

John
=:->


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkqFa2IACgkQJdeBCYSNAAMbnwCgxO+18Q9Yj183sSUmlSbjPE4h
opAAoI+rMPwl9iwK0N9sibmZlEoaQRHf
=biSV
-----END PGP SIGNATURE-----



References