[llvm] [LLVM] add LZMA for compression/decompression (PR #83297)

Artem Belevich via llvm-commits llvm-commits at lists.llvm.org
Sat Mar 2 12:44:53 PST 2024


Artem-B wrote:

I do get the part that multiple GPU variants give us a lot of redundancy in the data to compress away.

It's was not quite clear to me why compression ratio dramatically improves between `zstd-15` and `zstd -20` on the same blob. Or, another way to put it -- why don't se see such a high compression ratio at lower compression levels.

Though the bit that we're compressing multiple similar GPU blobs may be the likely explanation here, too. If compression window is smaller than the size of one GPU blob, it may not benefit from the commonality across multiple blobs. By the time we get to the beginning of the second GPU variant, we've essentially forgot what we had at the beginning of the first one.

> The following tables shows zstd level 20 results bundled bitcode for 2, 4, and 6 GPU arch:

Interesting. So, compression ratio for a single GPU blob is around 2.0-3.0x, and all subsequent blobs for other GPU variants get compressed essentially into nothing, as long as we can squeeze one complete GPU blob into compression window.

It sounds like there may be further room for improvement by tweaking zstd parameters to exploit specific properties of the data we're packing. 

https://github.com/llvm/llvm-project/pull/83297


More information about the llvm-commits mailing list