Pco (Pcodec) losslessly compresses and decompresses numerical sequences with high compression ratio and moderately fast speed.
Quick Start
use ;
use DEFAULT_COMPRESSION_LEVEL;
use PcoResult;
Compilation Notes
For best performance on x86_64, compile with any bmi*
and avx*
instruction sets your hardware supports.
Almost all x86_64 hardware these days supports bmi1
, bmi2
, and avx2
.
This improves compression speed slightly and decompression speed substantially!
To make sure you're using these, you can:
- Add the following to your
~/.cargo/config.toml
:
[]
= ["-C", "target-feature=+bmi1,+bmi2,+avx2"]
- OR compile with
RUSTFLAGS="-C target-feature=+bmi1,+bmi2,+avx2" cargo build --release ...
Note that settings target-cpu=native
does not always have the same effect,
since LLVM compiles for the lowest common denominator of instructions for a
broad CPU family.