2 ms·
> It solves the problem that a e.g. browser eats all your memory. It doesn't solve that. You get a little bit more headroom, but that's it. Not much ram is con
by viraptor 3y ago
> It solves the problem that a e.g. browser eats all your memory.
It doesn't solve that. You get a little bit more headroom, but that's it. Not much ram is considered compressible anyway. On my Mac I'm barely reaching 10% of compressed memory anyway, so it doesn't make that much difference.
- noisem4ker 3y agoCurrent RAM usage from my Windows 10 dev machine, as reported by Task Manager: > In use: 18028 MB > In use, compressed: 2718 MB > Compressed memory stores an estimated 9013 MB of data, saving the system 6294 MB of memory. That's not a small amount.
- jowea 3y agoMy experience is that zram saves quite a bit. I have another old laptop with 4GB where it's essential. Maybe it differs by program type? NAME ALGORITHM DISKSIZE DATA COMPR TOTAL STREAMS MOUNTPOINT /dev/zram0 lzo-rle 15,6G 1,9G 248,6M 418M 16 [SWAP]
- viraptor 3y agoYup, it will depend on your workload a lot. Worth testing of course!
- ltbarcly3 3y ago> Not much ram is considered compressible anyway. What are you basing this on? Things in RAM are often very very compressible, usually between 3:1 and 4:1.
- viraptor 3y agoDepends on what things are in your ram. Code/configuration/simple data structures compress nicely. Images/videos/ML-models don't.
- ltbarcly3 3y ago> Depends on what things are in your ram. No offense, but you are being a very precise in defense but very broad in your (in general incorrect) claim. The representation of an image sitting in memory will be a bitmap array, and for sure that will compress quite well. Video data as well but any decompressed frames are so transient I agree they won't benefit. ML-models don't compress well, but training data certainly does. If you put aside mapping already compressed or non-compressable data into memory, all the rest of the things ram is used for can be compressed. Day to day you will have a lot of memory allocated that can be compressed. Most memory in use right now on most computers is compressible.
- therealmarv 3y agoyes, it's not the ultimate solution but if your machine behaves in 98% of cases snappy and does not slow down vs. let's say only 70% of cases then that's a huge usability difference. Sometimes you just need a little headroom on top and not more. As some user point out it really depends on the workload and data etc. Browsers are a good example because in my experience browser cache can be compressed quite good.