Announcement

Collapse
No announcement yet.

Linux Patches Allow Changing Hibernation Compression Format For Better Performance

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Linux Patches Allow Changing Hibernation Compression Format For Better Performance

    Phoronix: Linux Patches Allow Changing Hibernation Compression Format For Better Performance

    Currently when hibernating a Linux system LZO compression is used for preserving the memory contents while a new patch series posted today by Qualcomm allow for changing out the compression API used and makes LZ4 a new option during Linux hibernation...

    Phoronix, Linux Hardware Reviews, Linux hardware benchmarks, Linux server benchmarks, Linux benchmarking, Desktop Linux, Linux performance, Open Source graphics, Linux How To, Ubuntu benchmarks, Ubuntu hardware, Phoronix Test Suite

  • #2
    Any idea on how to setup hybernate on a laptop with full disk encryption (dev mapper & cryptsetup)?

    My partition setup is as explained in this article: https://blog.theodo.com/2022/01/disk...with-tutorial/

    Comment


    • #3
      Originally posted by pkese View Post
      Any idea on how to setup hybernate on a laptop with full disk encryption (dev mapper & cryptsetup)?

      My partition setup is as explained in this article: https://blog.theodo.com/2022/01/disk...with-tutorial/
      It varies by distribution and how you install it. You either get what you get with the OS's installation tools or can do a lot more exotic setups from a Live environment by doing everything manually.

      Based on the link you posted, I'm assuming Ubuntu XX.YY. I'm also assuming that since you're asking these questions that it'd probably be a lot easier for you to backup your $HOME data, get a list of anything you've installed (Snaps and Apt), and then reinstall the OS with Ubuntu's built-in stuff. Worst case scenario, buy an external HDD from Wal-Mart (or your country's equivalent) and return it once you've backed up and restored your data because it's a "crappy" drive that "doesn't work". Those are questions you should query on the Ubuntu forums for better answers from people that use Ubuntu and know its tricks.

      Speaking of returning products, I'm returning a circular saw to Lowe's today. Damn thing wouldn't cut a standard 2x4. Anything over 1" thick would jam it up. That's not a joke.

      Do not buy the $80 20V Craftsman circular saw. It's actual junk. They shouldn't be allowed to make tools that shitty.

      Comment


      • #4
        >>When switching over to LZO compression, the decompression rate jumped from 335 MB/s to 501 MB/s

        Probably you meant LZ4

        Comment


        • #5
          Was this tested on some low end ARM chip? Because I remember zstd reaching > 4000 MB/s and LZ4 should be even faster.

          Comment


          • #6
            They’ve already got zstd in the linux tree, why not use that?

            Comment


            • #7
              Originally posted by bumblebritches57 View Post
              They’ve already got zstd in the linux tree, why not use that?
              As people keep saying till their keyboards wear out from the typing every time this topic comes up, not every CPU Linux supports has the hardware instructions or resources necessary to make zstd a viable alternative in all cases.

              Comment


              • #8
                Originally posted by stormcrow View Post

                As people keep saying till their keyboards wear out from the typing every time this topic comes up, not every CPU Linux supports has the hardware instructions or resources necessary to make zstd a viable alternative in all cases.
                Not to mention that LZ4 is just faster by default. Zstd has to be tuned and configured for raw speed whereas that's LZ4's default. Plus the Linux kernel doesn't support tuning Zstd to LZ4 speeds. It stops at Zstd:1 and LZ4 is closer to Zstd:-5.

                zstd 1.4.5 -1 2.884 500 MB/s 1660 MB/s
                zlib 1.2.11 -1 2.743 90 MB/s 400 MB/s
                brotli 1.0.7 -0 2.703 400 MB/s 450 MB/s
                zstd 1.4.5 --fast=1 2.434 570 MB/s 2200 MB/s
                zstd 1.4.5 --fast=3 2.312 640 MB/s 2300 MB/s
                quicklz 1.5.0 -1 2.238 560 MB/s 710 MB/s
                zstd 1.4.5 --fast=5 2.178 700 MB/s 2420 MB/s
                lzo1x 2.10 -1 2.106 690 MB/s 820 MB/s
                lz4 1.9.2 2.101 740 MB/s 4530 MB/s
                lzf 3.6 -1 2.077 410 MB/s 860 MB/s
                snappy 1.1.8 2.073 560 MB/s 1790 MB/s

                That's why LZ4 is used. It's just faster than everything else in exchange for a slightly lower compression ratio.

                And for anyone curious, those are the numbers from Zstd's site. If I was going to pick a biased data point in favor of Zstd, it'd be from them.
                Last edited by skeevy420; 04 October 2023, 12:47 PM.

                Comment


                • #9
                  Originally posted by Anux View Post
                  Was this tested on some low end ARM chip? Because I remember zstd reaching > 4000 MB/s and LZ4 should be even faster.
                  Probably hitting a storage bottleneck at that point.

                  Comment


                  • #10
                    Originally posted by QwertyChouskie View Post
                    Probably hitting a storage bottleneck at that point.
                    With modern M.2 SSDs these are hardly the bottleneck. In fact I want my disk (de)compression to be massively faster than my storage because else the CPU is at 100% just for some I/O. And Encryption likewise.

                    Comment

                    Working...
                    X