diff options
-rw-r--r-- | programs/lz4.1 | 4 | ||||
-rw-r--r-- | programs/lz4.1.md | 3 | ||||
-rw-r--r-- | programs/lz4cli.c | 4 |
3 files changed, 11 insertions, 0 deletions
diff --git a/programs/lz4.1 b/programs/lz4.1 index 3ca017a..d758ed5 100644 --- a/programs/lz4.1 +++ b/programs/lz4.1 @@ -120,6 +120,10 @@ Compression level, with # being any value from 1 to 12\. Higher values trade com Switch to ultra\-fast compression levels\. The higher the value, the faster the compression speed, at the cost of some compression ratio\. If \fB=#\fR is not present, it defaults to \fB1\fR\. This setting overrides compression level if one was set previously\. Similarly, if a compression level is set after \fB\-\-fast\fR, it overrides it\. . .TP +\fB\-\-best\fR +Set highest compression level\. Same as -12\. +. +.TP \fB\-\-favor\-decSpeed\fR Generate compressed data optimized for decompression speed\. Compressed data will be larger as a consequence (typically by ~0\.5%), while decompression speed will be improved by 5\-20%, depending on use cases\. This option only works in combination with very high compression levels (>=10)\. . diff --git a/programs/lz4.1.md b/programs/lz4.1.md index 8874467..56c0053 100644 --- a/programs/lz4.1.md +++ b/programs/lz4.1.md @@ -135,6 +135,9 @@ only the latest one will be applied. This setting overrides compression level if one was set previously. Similarly, if a compression level is set after `--fast`, it overrides it. +* `--best`: + Set highest compression level. Same as -12. + * `--favor-decSpeed`: Generate compressed data optimized for decompression speed. Compressed data will be larger as a consequence (typically by ~0.5%), diff --git a/programs/lz4cli.c b/programs/lz4cli.c index 3b5d61e..5da7654 100644 --- a/programs/lz4cli.c +++ b/programs/lz4cli.c @@ -146,6 +146,7 @@ static int usage_advanced(const char* exeName) DISPLAY( "--[no-]sparse : sparse mode (default:enabled on file, disabled on stdout)\n"); DISPLAY( "--favor-decSpeed: compressed files decompress faster, but are less compressed \n"); DISPLAY( "--fast[=#]: switch to ultra fast compression level (default: %i)\n", 1); + DISPLAY( "--best : same as -%d\n", LZ4HC_CLEVEL_MAX); DISPLAY( "Benchmark arguments : \n"); DISPLAY( " -b# : benchmark file(s), using # compression level (default : 1) \n"); DISPLAY( " -e# : test all compression levels from -bX to # (default : 1)\n"); @@ -414,6 +415,9 @@ int main(int argc, const char** argv) } continue; } + + /* For gzip(1) compatibility */ + if (!strcmp(argument, "--best")) { cLevel=LZ4HC_CLEVEL_MAX; continue; } } while (argument[1]!=0) { |