Zstd: Multi-threading / multi-threaded support for multi-core system

Created on 19 Dec 2016  ·  4Comments  ·  Source: facebook/zstd

Please consider adding support for multithreading / multithreaded compresion and decompression for faster processing on systems with multiple CPU cores.

enhancement

Most helpful comment

pzstd is a command line tool that does multithreaded compression and decompression. The pzstd format uses zstd skippable frames to encode the information it needs for parallel decompression, so pzstd compressed data is compatible with standard zstd decompression.

Adding parallel compression to the zstd binary is planned. Issue #471 also tracks the addition of a parallel library function.

All 4 comments

pzstd is a command line tool that does multithreaded compression and decompression. The pzstd format uses zstd skippable frames to encode the information it needs for parallel decompression, so pzstd compressed data is compatible with standard zstd decompression.

Adding parallel compression to the zstd binary is planned. Issue #471 also tracks the addition of a parallel library function.

There is also an zstdmt library. But it's API is not considered stable currently... also the documentation is not finished.

FWIW, the Blosc library also has a multithreaded implementation for a series of codecs (currently BloscLZ, LZ4, LZ4HC, Snappy and Zstandard), plus support for shuffling filters with support for SSE2 and AVX2 SIMD instruction set in Intel-compatible processors.

Multi-threading support has been added to latest release v1.1.3.

Since it's still experimental, it needs to be explicitly targeted (make zstdmt from root file).
Then it's possible to request nb of threads from the command line, for example :
zstd -T4 file

Was this page helpful?
0 / 5 - 0 ratings

Related issues

planet36 picture planet36  ·  3Comments

itsnotvalid picture itsnotvalid  ·  3Comments

terrelln picture terrelln  ·  3Comments

animalize picture animalize  ·  3Comments

AbdulrahmanAltabba picture AbdulrahmanAltabba  ·  3Comments