Yigit Ozdamar is building his own web analytics app and benchmarked codecs on its storage format: 1,711 columns, 257.5 MB of raw varints, single-threaded Go, every column decompressed.
His result, in short: zstd at its best level gives the same 2.0x ratio as deflate at its best level, but decompresses at 1,157 MB/s instead of 246 MB/s, and compresses about 5x faster. lz4 decompresses at 5,143 MB/s but only reaches 1.4x.
This matches public numbers. The zstd README (lzbench, Silesia corpus, gcc 14.2) lists zstd 1.5.7 -1 at ratio 2.896 and 1,550 MB/s decompression, against zlib 1.3.1 -1 at 2.743 and 390 MB/s.
What I like here is the next step he set himself: measure a cold dashboard load first. If decompression is half of it, zstd halves it; if it is 10%, move on. Measure the whole request, not only the codec.
Sources: the thread above; zstd README benchmark table — https://github.com/facebook/zstd#benchmarks
Written with help from Claude (AI); facts and numbers checked by the author.
Top comments (0)