diff options
author | Chanho Min <[email protected]> | 2013-07-08 16:01:49 -0700 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2013-07-09 10:33:30 -0700 |
commit | c72ac7a1a926dbffb59daf0f275450e5eecce16f (patch) | |
tree | 11350b56ad27c7001bdd45ce35d95666c355dfa8 /lib/mpi/mpi-bit.c | |
parent | f9b493ac9b833fd9dd3bbd50460adb33f29e1238 (diff) |
lib: add lz4 compressor module
This patchset is for supporting LZ4 compression and the crypto API using
it.
As shown below, the size of data is a little bit bigger but compressing
speed is faster under the enabled unaligned memory access. We can use
lz4 de/compression through crypto API as well. Also, It will be useful
for another potential user of lz4 compression.
lz4 Compression Benchmark:
Compiler: ARM gcc 4.6.4
ARMv7, 1 GHz based board
Kernel: linux 3.4
Uncompressed data Size: 101 MB
Compressed Size compression Speed
LZO 72.1MB 32.1MB/s, 33.0MB/s(UA)
LZ4 75.1MB 30.4MB/s, 35.9MB/s(UA)
LZ4HC 59.8MB 2.4MB/s, 2.5MB/s(UA)
- UA: Unaligned memory Access support
- Latest patch set for LZO applied
This patch:
Add support for LZ4 compression in the Linux Kernel. LZ4 Compression APIs
for kernel are based on LZ4 implementation by Yann Collet and were changed
for kernel coding style.
LZ4 homepage : http://fastcompression.blogspot.com/p/lz4.html
LZ4 source repository : http://code.google.com/p/lz4/
svn revision : r90
Two APIs are added:
lz4_compress() support basic lz4 compression whereas lz4hc_compress()
support high compression or CPU performance get lower but compression
ratio get higher. Also, we require the pre-allocated working memory with
the defined size and destination buffer must be allocated with the size of
lz4_compressbound.
[[email protected]: make lz4_compresshcctx() static]
Signed-off-by: Chanho Min <[email protected]>
Cc: "Darrick J. Wong" <[email protected]>
Cc: Bob Pearson <[email protected]>
Cc: Richard Weinberger <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: Yann Collet <[email protected]>
Cc: Kyungsik Lee <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'lib/mpi/mpi-bit.c')
0 files changed, 0 insertions, 0 deletions