mirror of
https://github.com/emmanuel-marty/lzsa.git
synced 2024-12-24 13:32:21 +00:00
When verbose, display uncompressed bytes/token ratio
This commit is contained in:
parent
be54a4f889
commit
9c35d5115b
@ -249,8 +249,10 @@ static int lzsa_compress(const char *pszInFilename, const char *pszOutFilename,
|
||||
|
||||
double fDelta = ((double)(nEndTime - nStartTime)) / 1000000.0;
|
||||
double fSpeed = ((double)nOriginalSize / 1048576.0) / fDelta;
|
||||
fprintf(stdout, "\rCompressed '%s' in %g seconds, %.02g Mb/s, %d tokens, %lld into %lld bytes ==> %g %%\n",
|
||||
pszInFilename, fDelta, fSpeed, lzsa_compressor_get_command_count(&compressor), nOriginalSize, nCompressedSize, (double)(nCompressedSize * 100.0 / nOriginalSize));
|
||||
int nCommands = lzsa_compressor_get_command_count(&compressor);
|
||||
fprintf(stdout, "\rCompressed '%s' in %g seconds, %.02g Mb/s, %d tokens (%lld bytes/token), %lld into %lld bytes ==> %g %%\n",
|
||||
pszInFilename, fDelta, fSpeed, nCommands, nOriginalSize / ((long long)nCommands),
|
||||
nOriginalSize, nCompressedSize, (double)(nCompressedSize * 100.0 / nOriginalSize));
|
||||
}
|
||||
|
||||
lzsa_compressor_destroy(&compressor);
|
||||
|
Loading…
Reference in New Issue
Block a user