I heard of pigz in the discussions following my interview of Yann Collet, creator of LZ4 and zstd. If you'll excuse the plug, here is the LZ4 story: Yann was bored and working as a project manager. So he started working on a game for his old HP 48 graphing calculator. Eventually, this hobby led him to revolutionize the field of data compression, releasing LZ4, ZStandard, and Finite State Entropy coders. His code ende…
One wild thing is how much performance wins were available compared to ZLib. Pigz is parrellel, but what if you just had a better way to compress and decompress than DEFLATE? When zstd came out – and Brotli before it to a certain extent – they were 3x faster than ZLib with a slightly higher compression ratio. You'd think that such performance jumps in something as well explored as data compression would be hard to co…
Pigz: Parallel gzip for modern multi-processor, multi-core machines
61–70 of 197 posts
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#62> exploits multiple processors and multiple cores to the hilt when compressing data As s side note, this isn't always desirable for this class of coders. In some scenarios (like web server) you might want to favor throughput over response time.
`zstd --adapt` is pretty cool as it detects how much output buffer it has and changes compression effort on the fly to try to achieve maximum throughput.
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#63I've got news for you buddy :)
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#64I heard of pigz in the discussions following my interview of Yann Collet, creator of LZ4 and zstd. If you'll excuse the plug, here is the LZ4 story: Yann was bored and working as a project manager. So he started working on a game for his old HP 48 graphing calculator. Eventually, this hobby led him to revolutionize the field of data compression, releasing LZ4, ZStandard, and Finite State Entropy coders. His code ende…
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#65Best of luck with the implementation, but I do hope the authors realise they should avoid naming their software tools like an old-school pornographic film. I thought we had learned that from the GIMP[1]. [1] https://www.theregister.com/2019/08/28/gimp_open_source_imag...
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#66Unless the recipient of whatever you are compressing absolutely requires gzip, you should not use gzip or pigz. Instead you should use zstd as it compresses faster, decompresses faster, and yields smaller files. It also supports parallelism (via “-T”) which supplants the pigz use case. There literally are no trade-offs; it is better in every objective way. In 2023, friends don’t let friends use gzip.
Zstd is getting there but I personally don't bother with it on a daily basis except in situations where both performance and compression ratio are important, like build artifact pipelines or large archives.
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#67Earlier quoted context omitted.
> as well explored as data compression What's well explored is compression rate, where indeed it's difficult to improve, and true innovations, like arithmetic coding, are rare. Compressing speed on the other hand it's not very interesting to academics, it's more of an engineering problem. And there is plenty of work to do here, starting with stuff as simple as multi-threading and SIMD. ZLib and ZStandard are probably…
> What's well explored is compression rate not performance Exactly! And this seems like a shame to me with something burning so many cpu cycles. > true innovations, like arithmetic coding, are rare. Yeah, Yann tried to explain arithmetic coding to me, but I didn't get it.
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#68I heard of pigz in the discussions following my interview of Yann Collet, creator of LZ4 and zstd. If you'll excuse the plug, here is the LZ4 story: Yann was bored and working as a project manager. So he started working on a game for his old HP 48 graphing calculator. Eventually, this hobby led him to revolutionize the field of data compression, releasing LZ4, ZStandard, and Finite State Entropy coders. His code ende…
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#69The issue with pigz is that uncompressing doesn't really parallelize beyond a three stage read/uncompress/write pipeline. This is of course more of a problem of the gz format than pigz although last time I looked hacks are possible to parallelize decompression.
I implemented parallel decompression a while back. It is in Solaris 11.3 and later. https://github.com/oracle/solaris-userland/blob/master/compo... Shortly after submitting a PR the code went through major surgery, and my patch then needed a similar amount of surgery. Oracle then whacked most of the Solaris org, and I don’t think this ever got updated to work with the current pigz.
Re: Pigz: Parallel gzip for modern multi-processor, multi-core machines
#70Unless the recipient of whatever you are compressing absolutely requires gzip, you should not use gzip or pigz. Instead you should use zstd as it compresses faster, decompresses faster, and yields smaller files. It also supports parallelism (via “-T”) which supplants the pigz use case. There literally are no trade-offs; it is better in every objective way. In 2023, friends don’t let friends use gzip.
`tar czf` is a lot easier to remember than `tar -I zstd cf`
tar --create --zstd --file