cvs commit: src/sys/fs/msdosfs msdosfs_denode.c

Peter Jeremy PeterJeremy at optushome.com.au
Thu Sep 8 04:20:15 PDT 2005


On Thu, 2005-Sep-08 10:06:14 +0300, Dmitry Pryanishnikov wrote:
>it would be possible to keep this disk image as a regression test for
>this particular bug (it could be compressed just fine ;).

Compressing 4GB of NULs takes ~100 seconds on an Athlon XP-1800 and
the result occupies 4MB.  Uncompressing is about twice as fast but
that's still 50 seconds to wait to read the second directory.

I'd suggest keeping it as an uncompressed sparse file instead.  That
will be smaller than a compressed file (two real blocks - one at
offset zero and the other at 4GB - about 32K + a couple of indirect
blocks).  You just need to be very careful about copying it.
Accessing the directories is virtually instantaneous because there's
no decompression.

BTW, this is one case where you can compress compressed files - the
smallest file is 783 bytes with 4GB NULs | gzip | gzip | gzip | wc.
-- 
Peter Jeremy


More information about the cvs-all mailing list