[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Let's shrink Packages.xz



I performed a few little experiments, too.

First, I tried encoding the various digests as base64 or base93, rather
than hex.  In each case, the file grew in size; base93 was the worst.

Eliminating all the headers (e.g., replacing Package: foo with simply
foo) saved 3.2%.  Replacing each one with an integer after its first
occurrence (e.g., since the first line is "Packages:", every subsequent
"Packages:" line starts "0:" instead) saved 1.7%.

Using "\0" instead of ": " and "\n" saved 1.5%.  Using ":" instead of ": "
saved 1.8%.

None of these do as much good as simply getting rid of one file hash.  I
know this has been talked about in the past, and as far as I recall the
result, nobody could agree on a hash to drop, in light of both the
expected future security of various hashes, as well as the hashes
actually used by current versions of apt. (ideally you'd just go sha256,
but iirc it's the md5sum that is used in practice, even today.  but
please find that thread, don't trust my summary)

Jeff


Reply to: