Unishox2 icon indicating copy to clipboard operation
Unishox2 copied to clipboard

benchmarks available?

Open kolinfluence opened this issue 3 years ago • 1 comments

hi, any benchmarks for ratio, speed, cpu usage and memory usage for >800bytes, 2k and 10k? compared with zstd, lz4 and snappy? something like this extracted from zstd github

Compressor name | Ratio | Compression | Decompress.
-- | -- | -- | --
zstd 1.5.1 -1 | 2.887 | 530 MB/s | 1700 MB/s
zlib 1.2.11 -1 | 2.743 | 95 MB/s | 400 MB/s
brotli 1.0.9 -0 | 2.702 | 395 MB/s | 450 MB/s
zstd 1.5.1 --fast=1 | 2.437 | 600 MB/s | 2150 MB/s
zstd 1.5.1 --fast=3 | 2.239 | 670 MB/s | 2250 MB/s
quicklz 1.5.0 -1 | 2.238 | 540 MB/s | 760 MB/s
zstd 1.5.1 --fast=4 | 2.148 | 710 MB/s | 2300 MB/s
lzo1x 2.10 -1 | 2.106 | 660 MB/s | 845 MB/s
lz4 1.9.3 | 2.101 | 740 MB/s | 4500 MB/s
lzf 3.6 -1 | 2.077 | 410 MB/s | 830 MB/s
snappy 1.1.9 | 2.073 | 550 MB/s | 1750 MB/s

kolinfluence avatar Nov 18 '22 13:11 kolinfluence

Hi, Thanks for your query. I saw your other message too. Unishox is for compressing short strings and not a replacement for lz4/zstd/snappy. It can co-exist with these technologies though.

The current implementation of Unishox2 is not great on speed so I am working on it and also Unishox3. The spec for Unishox3 is complete, but it is taking time to build the dictionary from millions of records from Reddit and Twitter posts. However you could use Unishox3-Alpha for now if you find it suitable for your case as I don't indent to change it.

siara-cc avatar Nov 18 '22 17:11 siara-cc