Announcement

Collapse
No announcement yet.

XanMod, Liquorix Kernels Offer Some Advantages On AMD Ryzen 5 Notebook

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

  • misGnomer
    replied
    Something I think I've noticed about the CacULE version of Xanmod vs stable or edge after recently giving it a spin on two systems:

    On older Intel system (no HT) the system clock keeps stable time.

    On one-year-old 4000-series 8-core Ryzen APU (overclocked RAM but extremely stable) the system clock occasionally lagged using the "mainline" stable or edge Xanmod spins, but since switching to CacULE the time lags have become drastic. The other day I experienced a 6-minute lag, and just moments ago, after resetting time again in the morning, I watched a 1½ hour conference video on youtube and at the end noticed I was over 30 seconds behind again.

    I did have minor time lags with the "standard" Xanmod releases, but it would seem that the problem is exacerbated with the CacULE version.

    My uneducated hunch is that the clock lag has something to do with stress on the GPU part of the APU. I might have to fire up Steam and this time pay attention to the various forms of time waste...

    Otherwise I've been very happy with Xanmod releases though.
    Last edited by misGnomer; 04 August 2021, 11:39 AM.

    Leave a comment:


  • perpetually high
    replied
    Sorry to blow up the thread. Made some more changes if anyone is interested in the script. You can probably gut the thing and tweak it to your liking if you're on Arch, Gentoo, Fedora, OpenSUSE, Pop! OS, Debian, you name it. The patches is where the good stuff is, the rest is up to you, I just happened to be on Ubuntu.

    Quick link to the script

    Added this commit with 5.10 support and some instructions on getting different flavors like 5.4 LTS, 5.10 LTS, and 5.13 going. Can't really mess anything up so just experiment as much as you want. I'll get a readme going soon but at least this commit message has enough to get going. Cheers

    Leave a comment:


  • perpetually high
    replied
    Y'all I just pushed some updates to the Ubuntu build script in the post above. I was mistaken about CONFIG_EXTRA_FIRMWARE_DIR having to be /lib/firmware/ (with a trailing slash). It didn't matter. When you set just CONFIG_EXTRA_FIRMWARE, it automatically sets it to /lib/firmware so I removed that unnecessary line from the script, and all is just as well.

    Also, I won't edit that original post since it will likely keep tripping up the system.

    In case you already cloned it, start fresh this one time if you can. Remove ~/kernel_main and start a new fresh git clone, and then ./build_kernel.sh of your choice (fyi I'm on Haswel//RX480 and I use the following):

    5.4 LTS

    AMDGPU_BUILTIN=yes VBOX_SUPPORT=yes KERNEL_TYPE=full ./build_kernel.sh

    which gives CacULE scheduler, full tickless, 500 hz, PREEMPT Low-Latency Desktop. Those together work very well.

    If you don't want full tickless kernel, or don't plan on using CacULE, the standard idle tickless with CFS, 1000 hz, and PREEMPT Low-Latency Desktop work well also. If you're on a laptop, maybe drop down the tick to 500 Hz for a sweet spot.

    So to recap, I did a fresh clone of the repo, ran the above, and booted into this kernel and typing on it as we speak.

    Should look like this at the end for 5.4:

    Code:
    ....
    ....
    *** Compiled kernel directory doesn't exist, creating... ✓
    mkdir: created directory '/home/arvin/kernel_main/compiled'
    renamed '5.4.136-0504136+custom-full-1627624873' -> '/home/arvin/kernel_main/compiled/5.4.136-0504136+custom-full-1627624873'
    *** Enabling VirtualBox support for 5.4 kernel... ✓
    '/home/arvin/kernel_main/patches/custom-patches/virtualbox-5.4-support/module.lds' -> '/usr/src/linux-headers-5.4.136-0504136+customfull-generic/scripts/module.lds'
    vboxdrv.sh: Stopping VirtualBox services.
    vboxdrv.sh: Starting VirtualBox services.
    vboxdrv.sh: Building VirtualBox kernel modules.
    *** Finished installing kernel, cleaning up build dir... ✓
    total 12
    drwxrwxr-x 3 arvin arvin 4096 Jul 29 23:01 .
    drwxrwxr-x 6 arvin arvin 4096 Jul 29 23:01 ..
    drwxrwxr-x 2 arvin arvin 4096 Jul 29 23:01 5.4.136-0504136+custom-full-1627624873
    total 75408
    drwxrwxr-x 2 arvin arvin 4096 Jul 29 23:01 .
    drwxrwxr-x 3 arvin arvin 4096 Jul 29 23:01 ..
    -rw-r--r-- 1 arvin arvin 204444 Jul 29 23:00 linux-buildinfo-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 19656 Jul 29 23:01 linux-cloud-tools-5.4.136-0504136+customfull_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 2128 Jul 29 23:00 linux-cloud-tools-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 10927412 Jul 29 22:22 linux-headers-5.4.136-0504136+customfull_5.4.136-0504136+customfull.202107251230_all.deb
    -rw-r--r-- 1 arvin arvin 2247824 Jul 29 23:00 linux-headers-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 14950932 Jul 29 22:59 linux-image-unsigned-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 10353176 Jul 29 22:59 linux-modules-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 32860928 Jul 29 23:00 linux-modules-extra-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 5624616 Jul 29 23:01 linux-tools-5.4.136-0504136+customfull_5.4.136-0504136+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 2252 Jul 29 23:00 linux-tools-5.4.136-0504136+customfull-generic_5.4.136-0504136+customfull.202107251230_amd64.deb
    *** All done. ✓
    *** You can now reboot and select 5.4.136-0504136+customfull in GRUB.
    And like this for 5.13:

    Code:
    *** Finished installing kernel, cleaning up build dir... ✓
    total 16
    drwxrwxr-x 4 arvin arvin 4096 Jul 30 00:21 .
    drwxrwxr-x 6 arvin arvin 4096 Jul 30 00:21 ..
    drwxrwxr-x 2 arvin arvin 4096 Jul 30 00:21 5.13.6-051306+custom-full-1627629688
    drwxrwxr-x 2 arvin arvin 4096 Jul 29 23:01 5.4.136-0504136+custom-full-1627624873
    total 82944
    drwxrwxr-x 2 arvin arvin 4096 Jul 30 00:21 .
    drwxrwxr-x 4 arvin arvin 4096 Jul 30 00:21 ..
    -rw-r--r-- 1 arvin arvin 217712 Jul 30 00:20 linux-buildinfo-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 19792 Jul 30 00:21 linux-cloud-tools-5.13.6-051306+customfull_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 2112 Jul 30 00:20 linux-cloud-tools-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 11737168 Jul 29 23:59 linux-headers-5.13.6-051306+customfull_5.13.6-051306+customfull.202107251230_all.deb
    -rw-r--r-- 1 arvin arvin 2407364 Jul 30 00:20 linux-headers-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 17910028 Jul 30 00:19 linux-image-unsigned-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 11276192 Jul 30 00:19 linux-modules-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 34366296 Jul 30 00:20 linux-modules-extra-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 6969068 Jul 30 00:21 linux-tools-5.13.6-051306+customfull_5.13.6-051306+customfull.202107251230_amd64.deb
    -rw-r--r-- 1 arvin arvin 2240 Jul 30 00:20 linux-tools-5.13.6-051306+customfull-generic_5.13.6-051306+customfull.202107251230_amd64.deb
    *** All done. ✓
    *** You can now reboot and select 5.13.6-051306+customfull in GRUB.
    edit 2: (july 30, 2021) - Looks like the 5.13 kernel also needs that module.lds for the latest VirtualBox (6.1.25 r145887) to work. Originally I thought it was just for 5.4. (or, that might have been the case, and now 5.13 requires it too). Either way, I pushed a new commit that will add VirtualBox support. (Passing VBOX_SUPPORT=yes to the script). I was also thinking of adding all the binary blobs (Navi, Polaris, Vegas) in the EXTRA_FIRMWARE line to cover all amdgpu built-in scenarios, Highly doubt the extra overhead will affect everything and it's probably best to go this route. Gonna think about it a little more and maybe do some benchmarking when I get time

    Cheers and let me know if you run into any problems. This latest version has been tagged v1.00 (I deleted the old v1 tag to avoid any confusion)
    Last edited by perpetually high; 30 July 2021, 05:51 PM.

    Leave a comment:


  • ms178
    replied
    Originally posted by polarathene View Post

    Did you by any chance do a breakdown of where the bulk of the perf improvement was coming from? Or if it were bits here and there?
    It is mostly the Kernel and my compilation flags, as I have seen this improvement also on mainline Kernels, not just Xanmod. There is a chance that my custom Kernel configuration unlocks some of that performance as I also tune my config for my specific hardware and also disable some Spectre/Meltdown and other security related options. Compiling Mesa with aggressive compiler flags only yielded tiny improvements in comparison (at most 2 - 3 fps) but improved the smoothness a bit.

    Leave a comment:


  • perpetually high
    replied
    Originally posted by CochainComplex View Post

    I ran yesterday in a compilation error related to some AMD header file. But tbh due to lack of time i was not investigating it throughly. I will do it next days. Thx for adding additional infos by using gifs. Btw if you havent seen it yet you can also switch on O3 ...just search for O3 in menuconfig.
    Appreciate the feedback, let me know what that error is when you get a chance

    And yeah I'm back to the O3 as a couple of weeks also. Lucjan has a patch that makes O3 a little more sensible:

    KBUILD_CFLAGS += -O3
    +KBUILD_CFLAGS += $(call cc-option, -fno-tree-loop-vectorize)

    Otherwise, I'd probably stick to O2 to be honest.

    Leave a comment:


  • CochainComplex
    replied
    Originally posted by perpetually high View Post

    I added a bunch of pastebins and an imgur link and it must have tripped up the system. Going to be home soon and will repost it if Michael isn’t back by then

    edit: thanks Michael

    edit 2: added a gif of traversing through the main parts of the config: https://imgur.com/a/xGQysAu

    Didn't want to risk getting that last post flagged by the system. Definitely go through all the options, flip back on the ones I turned off that pissed you off. Do all of it. Grab a cup of coffee, and go

    edit 3: there was a setting in the config (CONFIG_NR_CPUS) that i had set to 4 because I'm a quad-core, but I updated the option now to 512, which is what Ubuntu defaults to. I also have the ubuntu defaults there if you need to refer to them. I've updated the github repo with that change and don't plan on touching it for a little bit to let it marinate. Everything else should be good, but you're encouraged to go through the config as well, but the default "perpetually high" default should be okay, too. Salute.
    I ran yesterday in a compilation error related to some AMD header file. But tbh due to lack of time i was not investigating it throughly. I will do it next days. Thx for adding additional infos by using gifs. Btw if you havent seen it yet you can also switch on O3 ...just search for O3 in menuconfig.

    Leave a comment:


  • perpetually high
    replied
    Originally posted by CochainComplex View Post
    perpetually high strange it was at least one time visible/respectively approved
    I added a bunch of pastebins and an imgur link and it must have tripped up the system. Going to be home soon and will repost it if Michael isn’t back by then

    edit: thanks Michael

    edit 2: added a gif of traversing through the main parts of the config: https://imgur.com/a/xGQysAu

    Didn't want to risk getting that last post flagged by the system. Definitely go through all the options, flip back on the ones I turned off that pissed you off. Do all of it. Grab a cup of coffee, and go

    edit 3: there was a setting in the config (CONFIG_NR_CPUS) that i had set to 4 because I'm a quad-core, but I updated the option now to 512, which is what Ubuntu defaults to. I also have the ubuntu defaults there if you need to refer to them. I've updated the github repo with that change and don't plan on touching it for a little bit to let it marinate. Everything else should be good, but you're encouraged to go through the config as well, but the default "perpetually high" default should be okay, too. Salute.
    Last edited by perpetually high; 30 July 2021, 02:47 AM.

    Leave a comment:


  • lyamc
    replied
    I tried Liquorix and Xanmod’s kernels on a 4000 series Ryzen laptop. Liquorix took some big hits to input delay which Xanmod didn’t, so I stuck with Xanmod

    Leave a comment:


  • CochainComplex
    replied
    perpetually high strange it was at least one time visible/respectively approved

    Leave a comment:


  • perpetually high
    replied
    Michael can you approve my kernel build post. Got unapproved after a couple edits. Anyway to get that feature to stop for Premium members??

    Leave a comment:

Working...
X