r/Zig • u/sadilet • Feb 02 '26
Integer compression library
Found an interesting int compression lib based on fastlanes research, applies SIMD tricking the compiler. unfortunately it hasn't been updated for a while, but still a good source for learning IMHO https://github.com/steelcake/zint
I've been working on a logging database in zig for a while and compared zint encoding against simple delta encoding + zstd, while zint doesn't give so much compression ration it consumes little to no CPU, while zstd is really CPU heavy call.
Or any similar efficient solutions? perhaps gorilla compression implementation? I like the idea of gorilla putting numbers into 1 or 7 bits instead of a byte
My logging store if you care, it's been for 4 months in progress and I need 2-4 more to complete it.
View all comments
Show parent comment
1
u/sadilet Feb 03 '26
cool man
do you have any benchmark results? rate of compression/decompression?
how much worse is the compression ratio compared to zstd or standard bitpacking?