Bye bye, rt-kernel!

publié le 7 September 2021

Back in 2010, when I first started using a (Linux) computer for realtime sound processing on stage, a rt-patched kernel was absolutely mandatory to achieve the low latencies I needed (for feedback on these early experiments, see my 2012 RMLL talk or the 2014 Linux Audio Conf's poster and listening kiosk).

LAC'14 Poster

A couple of years later, part of these patches were included in the mainline kernel and more and more musicians found that they did not need an rt-patched kernel any more. However, my particular experience was that I still needed these extra patches to get the sub-10ms roundtrip latency I was striving for.

A few weeks ago, I spent some time re-installing my gigging machine. I settled for Manjaro, installed and booted an rt-kernel, downloaded realtimeconfigquickscan and after a few configuration tweaks made a few tests... which were disastrous. Any activity, even moving my mouse, would cause xruns, even at relatively high latencies :-(

This seemed like the perfect time to install and configure rtirq (good, although slightly dated explanation here). It did add some stability, but it was still very far from satisfying.

Not knowing were to go next, I rebooted on Manjaro's default kernel and... voilà, everything worked beutifully, with a (jack) latency of 4ms. The system has been rock stable ever since and worked perfectly through hours of rehearsals and four gigs with no dropout at all!

No idea why the vanilla kernel is working better than the rt- one, but it seems I joined the cohort of musicians that don't need an rt-kernel any more.

NB: If you're curious about the details, I'm talking about an old Lenovo T410s laptop from 2010 (Intel i5 CPU @ 2.5Ghz) connected to a Presonus AudioBox 1818VSL. On this configuration jackd -P70 -S -dalsa -dhw:VSL -r48000 -p64 -n3 leads to a roundtrip latency just under 10ms (9.916ms as measured by jack_iodelay). Once my patches are loaded, I can surf the web, install (or even compile) new software and do pretty much everything without causing dropouts! If I don't need much processing power, I can even drop the jack latency to 2ms (-p32), but then my aging CPU doesn't allow me to do much before the DSP load peaks over 100%...