One month and counting without RT kernel on Arch Linux

Optimize your system for ultimate performance.

Moderators: MattKingUSA, khz

gimmeapill
Established Member
Posts: 526
Joined: Thu Mar 12, 2015 8:41 am

Re: One month and counting without RT kernel on Arch Linux

Postby gimmeapill » Wed Jan 09, 2019 9:22 am

merlyn wrote:
gimmeapill wrote:...and in the meantime, look what just made it to the AUR: linux-rt 4.19.10


You can install a pre-built RT kernel by adding this unofficial user repository.


I prefer to build stuff myself in a clean chroot rather than use third party repos whenever possible,
but it is true that 4.19 RT did take a solid 3,5 hours to compile on my old machine - this starts to call for a HW upgrade ;-)

Regarding 4.19 RT: So far it seems to be fairly solid: I could get Guitarix + jack running @96khz x 3 buffers and 32 periods (=~1ms) without a hitch - this is where the stock Arch kernel starts to choke. I suspect it might be slightly better than 4.18 RT also.

User avatar
sysrqer
Established Member
Posts: 1568
Joined: Thu Nov 14, 2013 11:47 pm
Contact:

Re: One month and counting without RT kernel on Arch Linux

Postby sysrqer » Wed Jan 09, 2019 9:49 am

Gimmeapill do you not disable obviously irrelevant stuff in your kernel config? I used to be able to build a trimmed down one in about 10mins on my old core2duo.

gimmeapill
Established Member
Posts: 526
Joined: Thu Mar 12, 2015 8:41 am

Re: One month and counting without RT kernel on Arch Linux

Postby gimmeapill » Wed Jan 09, 2019 10:16 am

sysrqer wrote:Gimmeapill do you not disable obviously irrelevant stuff in your kernel config? I used to be able to build a trimmed down one in about 10mins on my old core2duo.


Yes, I used to, but this became over time a lot more pain than it is worth.
I also used to build the spartan way with "make localmodconfig" which would give very slim kernels, also the 10 mins ballpark, by building only the modules loaded by the currently running kernel.
But I eventually gave up as this was more than often breaking the build (ex: when new upstream kernel modules are introduced or renamed).
Also, I never found any empirical evidence that latency improved, and this made the config pretty much useless for troubleshooting or comparing results.

So nowadays I just let my old CPU suffer and trust the RT kernel AUR maintainer - or even better, use the stock kernel ;-)

As XKCD put it back in the days:
Image

User avatar
sysrqer
Established Member
Posts: 1568
Joined: Thu Nov 14, 2013 11:47 pm
Contact:

Re: One month and counting without RT kernel on Arch Linux

Postby sysrqer » Wed Jan 09, 2019 10:54 am

Haha yeah it can take a lot of work maintaining when it is that minimal and not something I can be bothered to do anymore.

User avatar
raboof
Established Member
Posts: 1558
Joined: Tue Apr 08, 2008 11:58 am
Location: Deventer, NL
Contact:

Re: One month and counting without RT kernel on Arch Linux

Postby raboof » Wed Jan 09, 2019 11:51 am

I remember manually stripping down the kernel configuration because my machine had only 4mb of RAM instead of the then-recommended 8mb... I don't think I've bothered with it since :D

artofmusic
Established Member
Posts: 20
Joined: Mon Mar 17, 2014 8:01 pm

Re: One month and counting without RT kernel on Arch Linux

Postby artofmusic » Thu Jan 10, 2019 5:17 am

I think the Archlinux zen kernel is the way to go. Another plus is that it uses the newer I/O schedules like kyber/mq-deadline/bfq for better multi read/wrrite performance on HDD's. This kernel also has optimized the RCU timer threshold setting for more responsiveness. Attached is a zip I created to build the package. The advantage with my PKGBUILD is you can compile a bunch of different kernel versions and use them side by side, unlike Arch's Linux kernels. Lastly, I further tuned the kernels using a 1000HZ timer and set the default governor to performance.
Hope this helps.
You do not have the required permissions to view the files attached to this post.

gimmeapill
Established Member
Posts: 526
Joined: Thu Mar 12, 2015 8:41 am

Re: One month and counting without RT kernel on Arch Linux

Postby gimmeapill » Thu Jan 10, 2019 10:29 am

artofmusic wrote:I think the Archlinux zen kernel is the way to go. Another plus is that it uses the newer I/O schedules like kyber/mq-deadline/bfq for better multi read/wrrite performance on HDD's. This kernel also has optimized the RCU timer threshold setting for more responsiveness. Attached is a zip I created to build the package. The advantage with my PKGBUILD is you can compile a bunch of different kernel versions and use them side by side, unlike Arch's Linux kernels. Lastly, I further tuned the kernels using a 1000HZ timer and set the default governor to performance.
Hope this helps.


From your description, this is yet another desktop kernel optimized for responsiveness + throughput, not worst case latency.
I didn't go through the full config, but 1000hz is mostly deprecated since we have a full tickless kernel.
And messing around with the default governor is the last thing I need my kernel to do (this, and also deciding which I/O scheduler I should use).
Actually the whole point of this thread is to discuss if running one of those custom frankenkernels is still really worth the pain in 2019 - at least for audio stuff. Even the scope of the RT patch set sems to be seriously reduced.

I don't mean to be completely dismissive, but I don't see any compelling argument so that this nth custom kernel would allow lower audio latencies with less xruns than 4.19 Stock or RT.

Some cyclictest benchmarks maybe?

artofmusic
Established Member
Posts: 20
Joined: Mon Mar 17, 2014 8:01 pm

Re: One month and counting without RT kernel on Arch Linux

Postby artofmusic » Thu Jan 10, 2019 12:41 pm

I have found this kernel to lock up less personally, plus it would be nice if Archlinux made multiple version kernels viable for those of us who may use proprietary drivers. Also, on Nvidia I have found that RT is a real pain and can lead to a black screen when starting X11 and even more lockups during use. This config is the best balance when you need to use prop. drivers. I wish RT kernels would support hardware a bit better in this regard, as this is the main practical case against using RT.

gimmeapill
Established Member
Posts: 526
Joined: Thu Mar 12, 2015 8:41 am

Re: One month and counting without RT kernel on Arch Linux

Postby gimmeapill » Fri Jan 11, 2019 9:02 am

Yeah, Nvidia + RT is not the easiest going combo for audio (although it seems to be working for some people).
But it is not up to Arch to delay upgrades to support proprietary drivers - rather the opposite ;-)

Anyway, if you want to pitch Linux-ZEN against the latest stock or RT, why not run a few benchmarks and post the results here: https://linuxmusicians.com/viewtopic.php?f=27&t=19335

As for this thread, I guess it can be closed since the experiment is over: I went back to RT (4.19 RT is really that good).
But if something went sour, using the default Arch kernel wouldn't be dramatic by any mean.


Return to “System Tuning and Configuration”

Who is online

Users browsing this forum: No registered users and 1 guest