Comments (5)
Discussion when LZMA or ZPAQ used:
Ramsize = total system ram
Usable ram = Ram size / 3 or 6 depending on whether or not STDIN/OUT is used
Stream out Limit = Usable ram / 2 (when compression is used)
Overhead = ram used by LZMA or ZPAQ (only applicable when LZMA or ZPAQ used)
Threads * Overhead has to be less than Limit
Instead of reducing Limit, we reduce threads and then overhead size.
Stream bufffer size should be Threads * Overhead, not Limit / Threads.
The goal is to have the largest possible buffer passed to backend.
from lrzip-next.
When lzma levels are low, the dictionary size is really low, so that passing such a small buffer is impractical. For example, at Level 1, the lzma dictSize is only 256KB. At Level 3, just 4MB. So, control->overhead just won't do it. Now, a focus will change to
MAX(limit/threads, control->overhead)
Work continues...
The same may be true with ZPAQ.
from lrzip-next.
The new stream_buffsize_fix branch is live. A test suite was run on a 22GB Android source file with lrzip
and lrzip-next
for all compression levels. The two takeaways were
- lrzip-next compressed better
- lrzip-next was slower
The following table explains.
Source file size: 22,186,711,040
Host machine 16GB ram, NVMe drives
Level | L-Version | Comp Size | Comp Ratio | Time Comp | Dictionary Size | Stream Buf Size |
---|---|---|---|---|---|---|
1 | lrzip | 8,631,012,019 | 2.571 | 07:28 | 65,536 | 303,083,217 |
1 | lrzip-next | 8,398,936,430 | 2.642 | 07:55 | 262,144 | 306,614,272 |
2 | lrzip | 8,404,895,681 | 2.640 | 08:35 | 65,536 | 303,083,217 |
2 | lrzip-next | 8,030,466,426 | 2.763 | 09:46 | 1,048,576 | 306,614,272 |
3 | lrzip | 7,981,495,752 | 2.780 | 09:43 | 262,144 | 301,952,721 |
3 | lrzip-next | 7,388,579,291 | 3.003 | 10:55 | 4,194,304 | 306,614,272 |
4 | lrzip | 7,566,017,145 | 2.932 | 11:29 | 1,048,576 | 297,430,737 |
4 | lrzip-next | 7,062,290,035 | 3.142 | 10:55 | 8,388,608 | 306,614,272 |
5 | lrzip | 7,350,404,281 | 3.018 | 11:29 | 1,048,576 | 297,430,737 |
5 | lrzip-next | 6,551,861,089 | 3.386 | 16:33 | 16,777,216 | 306,614,272 |
6 | lrzip | 7,105,457,377 | 3.122 | 12:29 | 4,194,304 | 279,342,801 |
6 | lrzip-next | 6,375,766,737 | 3.480 | 17:25 | 33,554,432 | 358,629,376 |
7 | lrzip | 6,406,880,370 | 3.463 | 21:09 | 16,777,216 | 206,991,057 |
7 | lrzip-next | 6,260,303,409 | 3.544 | 21:54 | 33,554,432 | 358,629,376 |
8 | lrzip | 6,343,430,552 | 3.498 | 22:37 | 33,554,432 | 110,522,065 |
8 | lrzip-next | 6,151,916,421 | 3.606 | 25:39 | 67,108,864 | 710,950,912 |
9 | lrzip | 6,711,450,403 | 3.306 | 23:53 | 67,108,864 | 10,485,760 |
9 | lrzip-next | 6,109,073,029 | 3.632 | 29.21 | 100,663,296 | 1,063,272,448 |
from lrzip-next.
Next step to optimize is this. If we know the size of the file being compressed, and it is less than the chunk limit we could possibly make a better computation for overhead size comparison and threads used.
from lrzip-next.
All done. Merged into lzma-sdk-21.04beta.
from lrzip-next.
Related Issues (20)
- ZPAQ Compression issue when lrizip-next block size > zpaq block size HOT 3
- :lady_beetle: linker warning: missing .note.GNU-stack section implies executable stack HOT 2
- Found typo in viewing compression info on a lrz file HOT 1
- :lady_beetle: lrzip-next segfaults when STDIN + -o filename used. HOT 2
- :lady_beetle: [Certain files compressed with ZPAQ fail to compress successfully] HOT 5
- :lady_beetle: [Slower than lrzip, same arguments, stuck at 99%] HOT 4
- :lady_beetle: [Broken Pipe at 55% on L9] HOT 21
- Huanglei3 reported a bug in lrzip that is not duplicated here HOT 3
- Read zero page memory HOT 1
- :bulb: Have lzma backend respect -p# option HOT 9
- :bulb: possible precomp support HOT 2
- :lady_beetle: Decompress/Test/Info fails with --bzip2, gzip, lzo
- :lady_beetle: Losing on ISO/Zip on rare cases HOT 11
- From lrzip: lrzip 0.631 occasionally hangs forever HOT 5
- Enhance lzo compression by using all 5 methods HOT 2
- :lady_beetle: double free detected in tcache 2 HOT 1
- :lady_beetle: zstd compression fails when all blocks are incompressible HOT 1
- :lady_beetle: fake_mremap does not compile HOT 3
- From lrzip: Suggestion to support encrypted Stdin/Stdout when password provided on command line #251 HOT 1
- :bulb: Allow PROCESSORS to be set in lrzip.conf file HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lrzip-next.