Go Back   Cockos Incorporated Forums > REAPER Forums > REAPER for Linux

Reply
 
Thread Tools Display Modes
Old 12-13-2021, 03:34 AM   #1
XoechZ
Human being with feelings
 
Join Date: Oct 2008
Location: Austria
Posts: 325
Default RT priority - best setting? what for?

Hello!

I am using Arch Linux, installed the realtime-privileges package and added my user to the realtime group.

Now I discovered this "RT priority" setting in Reaper/preferences/Audio device setting.

Per default it is set to 0 (non-RT). But there is also 40 (suggested setting for RT use) and 50 (default hardware priority).

My question is: What is the best setting for a USB Audio Device? And what does this setting change? Latency? CPU usage? I have no idea how to set this correctly.

Please help!
XoechZ is offline   Reply With Quote
Old 12-13-2021, 06:19 AM   #2
Glennbo
Human being with feelings
 
Glennbo's Avatar
 
Join Date: Mar 2008
Location: Planet Earth
Posts: 9,097
Default

50 (default hardware priority) is how I have mine set.
__________________
Glennbo
Hear My Music - Click Me!!!
--
Glennbo is offline   Reply With Quote
Old 12-13-2021, 02:35 PM   #3
audiojunkie
Human being with feelings
 
audiojunkie's Avatar
 
Join Date: Nov 2011
Posts: 973
Default

I believe the reason 40 is the suggested setting is that if you ran into any ill behaved software while running at 50, there is a risk that you might not regain enough control of your desktop to recover from the ill behaved software. I've never tried 50 personally, but as Glennbo says, he uses it regularly. YMMV :-)
audiojunkie is online now   Reply With Quote
Old 12-13-2021, 03:16 PM   #4
XoechZ
Human being with feelings
 
Join Date: Oct 2008
Location: Austria
Posts: 325
Default

Thanks for the answers.

First, I had the setting on 0, because this is the default value after installing Reaper. Then I set it to 40, because this is the suggested value in Reaper. Now I have it on 50. And to be honest I do not notice any differences with the different settings. So I still wonder what this is good for...
XoechZ is offline   Reply With Quote
Old 12-13-2021, 05:13 PM   #5
audiojunkie
Human being with feelings
 
audiojunkie's Avatar
 
Join Date: Nov 2011
Posts: 973
Default

Quote:
Originally Posted by XoechZ View Post
Thanks for the answers.

First, I had the setting on 0, because this is the default value after installing Reaper. Then I set it to 40, because this is the suggested value in Reaper. Now I have it on 50. And to be honest I do not notice any differences with the different settings. So I still wonder what this is good for...
This setting is for privileges, not necessarily the actual changes needed. I believe you would still need a kernel that makes use of this. Are you using the kernel that Arch has available with the Zen patches?
audiojunkie is online now   Reply With Quote
Old 12-13-2021, 05:22 PM   #6
XoechZ
Human being with feelings
 
Join Date: Oct 2008
Location: Austria
Posts: 325
Default

No,I am using the normal (stock) kernel. The only thing I did, as mentioned in the first post, is that I have installed the realtime-privileges package from the arch repos and added my user to the realtime group.
XoechZ is offline   Reply With Quote
Old 12-13-2021, 06:13 PM   #7
PMan
Human being with feelings
 
Join Date: Aug 2019
Posts: 656
Default

"So I still wonder what this is good for... "

A lot of things are going on in your computer at any given moment. Among other things, the computer is scanning for mouse movements & qwerty keyboard keystrokes, converting those hardware inputs into changes in software, telling your video card what to draw on the screen, and generating audio. It seems like they are all happening at the same time, but really the computer is doing one thing at a time, one after the other, really fast. So fast that it seems like it's happening at the same time. Each of the "things" that the computer is doing is called a "task".

Priority settings are a sort of pecking order for computer tasks. If 2 tasks need to happen at the same time, for example an interrupt for the USB driver for your audio interface, and an interrupt for your video card driver, whichever task has the highest priority goes first. Also with a RT kernal, (this is all a bit over-simplified) if a task with a lower priority is running, but not finished, a higher priority task can interrupt it and take over to do it's thing. This is what makes RT kernals good for digital audio. High priority (audio related) tasks do not have to wait very long to get attention from the cpu (to get serviced).

Priorities insure that the most critical tasks happen first. In the case of digital audio, you want your audio interface to have a higher priority than any non-essential tasks.

I don't think it affects latency on it's own, but it can *definitely* allow you to configure your audio device with smaller buffer sizes (which gives you lower latency) without getting x-runs.

You will need a RT kernal to get those benefits, though.
PMan is offline   Reply With Quote
Old 12-13-2021, 07:52 PM   #8
audiojunkie
Human being with feelings
 
audiojunkie's Avatar
 
Join Date: Nov 2011
Posts: 973
Default

Installing and configuring a kernel on arch shouldn’t be too difficult—Arch based distros have the AUR. You shouldn’t need to compile anything by hand. You can get by with the Zen kernel (equivalent to the Liquorix kernel on Debian), or choose nearly any other kernel (including an RT kernel) through the AUR. I personally use the Zen kernel, offered as an install choice through Arch.

Edit: BTW, what video driver are you using? It might matter in your decision making process.
audiojunkie is online now   Reply With Quote
Old 12-13-2021, 08:26 PM   #9
XoechZ
Human being with feelings
 
Join Date: Oct 2008
Location: Austria
Posts: 325
Default

Thanks for the infos.

I use the Nvidia driver. My Laptop has a Nvidia 2060 built in. So I need the nvidia-dkms package as well I think, when I install an additional kernel. I will try the Zen, no problem, it is in the Arch repos.
XoechZ is offline   Reply With Quote
Old 12-13-2021, 10:06 PM   #10
audiojunkie
Human being with feelings
 
audiojunkie's Avatar
 
Join Date: Nov 2011
Posts: 973
Default

Quote:
Originally Posted by XoechZ View Post
Thanks for the infos.

I use the Nvidia driver. My Laptop has a Nvidia 2060 built in. So I need the nvidia-dkms package as well I think, when I install an additional kernel. I will try the Zen, no problem, it is in the Arch repos.
Yeah, try the Zen. The RT kernel doesn’t play well with the proprietary Nvidia drivers.
audiojunkie is online now   Reply With Quote
Old 12-13-2021, 10:16 PM   #11
XoechZ
Human being with feelings
 
Join Date: Oct 2008
Location: Austria
Posts: 325
Default

Cool, thanks for the tip!
XoechZ is offline   Reply With Quote
Old 12-14-2021, 11:49 PM   #12
4duhwinnn
Human being with feelings
 
Join Date: Mar 2017
Posts: 861
Default

The top or htop or similar apps list what priorities are used for each running program. There may be kernel background system utilities that are occasionally kleening house, that need priority over audio/video to prevent something bad from happening. I'm guessing that the more start-up utility, hard-disk, wireless, bluetooth, and internet activity there is, the higher the likelihood becomes of a conflict.

It's easy enough to shut those things down for a serious recording session. Remove extra hard-disks, move the data dross to back-up drives so there's no read-write drama in your audio/video diskspace, and establish a good swap file just in case.

I recently went through my linux setups, to be rid of apps I never use,
and the things that work notably better in one system, don't really need to clutter up the others.

I would get the results from the htop, and then make some priorities decisions. In a test session, you could start a game, watch a youtube, and download something, and browse a forum, to get a record of whats going on, then do a session devoid of the things I mentioned above, but with your typical recording session running, and compare the two lists of running softwares, their priorities, and if desired, set audio priorities higher than the others.

The weeds and documents grow fast and high,

https://linuxplumbersconf.org/event/...ntribution.pdf

https://www.suse.com/c/cpu-isolation...deoffs-part-4/

(it's all way over my head, but knowing that brains trusts are active,
is at least mildly comforting.)

My limits.conf priority is 95, and on qjackctl settings panel, priority
is 76. I've read that the qjackctl setting is less relevant now, due to
tech changes, but can't remember exactly why. I used to use 99 and 89, before
the high-powered vsts invaded Reaper...
4duhwinnn is offline   Reply With Quote
Old 12-15-2021, 12:23 PM   #13
audiojunkie
Human being with feelings
 
audiojunkie's Avatar
 
Join Date: Nov 2011
Posts: 973
Default

Quote:
Originally Posted by 4duhwinnn View Post
The top or htop or similar apps list what priorities are used for each running program. There may be kernel background system utilities that are occasionally kleening house, that need priority over audio/video to prevent something bad from happening. I'm guessing that the more start-up utility, hard-disk, wireless, bluetooth, and internet activity there is, the higher the likelihood becomes of a conflict.

It's easy enough to shut those things down for a serious recording session. Remove extra hard-disks, move the data dross to back-up drives so there's no read-write drama in your audio/video diskspace, and establish a good swap file just in case.

I recently went through my linux setups, to be rid of apps I never use,
and the things that work notably better in one system, don't really need to clutter up the others.

I would get the results from the htop, and then make some priorities decisions. In a test session, you could start a game, watch a youtube, and download something, and browse a forum, to get a record of whats going on, then do a session devoid of the things I mentioned above, but with your typical recording session running, and compare the two lists of running softwares, their priorities, and if desired, set audio priorities higher than the others.

The weeds and documents grow fast and high,

https://linuxplumbersconf.org/event/...ntribution.pdf

https://www.suse.com/c/cpu-isolation...deoffs-part-4/

(it's all way over my head, but knowing that brains trusts are active,
is at least mildly comforting.)

My limits.conf priority is 95, and on qjackctl settings panel, priority
is 76. I've read that the qjackctl setting is less relevant now, due to
tech changes, but can't remember exactly why. I used to use 99 and 89, before
the high-powered vsts invaded Reaper...
Very cool articles! I’m going to have to add them to my collection! Cheers!
audiojunkie is online now   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 11:04 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.