Linux: Slow down GPU processing when PC in use

If you think it might be a driver problem, see viewforum.php?f=79

Moderators: Site Moderators, FAHC Science Team

Post Reply
brunoais
Posts: 3
Joined: Wed Apr 01, 2020 1:02 pm

Linux: Slow down GPU processing when PC in use

Post by brunoais »

Currently, GPU running F@H appears to be using the GPU fairly aggressively, even if I choose the medium folding power.
I also tried comparing FPS of a few light programs while running at maximum folding power vs medium folding power.
I'm always getting 10FPS with long frame delays of 100-700ms.

I want to be part of the cause but I can't donate the GPU power if it is being used this aggressively.

Is there a way to regulate how much GPU power is used? Maybe select CPU sleep intervals to wait between each computation result and the next computation to execute?

Maybe there's a way using cgroupsv2?

I'm using Linux 5.3 on Ubuntu 18.04
davidcoton
Posts: 1102
Joined: Wed Nov 05, 2008 3:19 pm
Location: Cambridge, UK

Re: Linux: Slow down GPU processing when PC in use

Post by davidcoton »

Unfortunately the current GPU control systems do not allow meaningful task prioritization, as is done for CPU tasks.
The only option is to pause the GPU slot when you need to use it.
It's something which is a known issue with no known solution, I would expect something to be implemented when the GPU firmware (?) permits it.
Image
brunoais
Posts: 3
Joined: Wed Apr 01, 2020 1:02 pm

Re: Linux: Slow down GPU processing when PC in use

Post by brunoais »

What about pausing? As in, continuous use of calls to "usleep" inside the program to wait between each set of work instructions?
That wait could be configured alongside the already existing ability to determine if the user is using the system to turn off the wait time if the user is using the system.

Is that feasible?
I already tried to search for the code for this but it appears to be a part that is closed source.
katakaio
Posts: 27
Joined: Wed Oct 28, 2009 7:31 pm
Hardware configuration: Intel Core i5-6500 @ 3.2 GHz
EVGA GeForce RTX 2060 6GB XC Ultra
EVGA GeForce GTX 960 4GB FTW

Intel Core i5-3550 @ 3.3 GHz
EVGA GeForce GTX 750 Ti 2GB FTW
Location: Florida

Re: Linux: Slow down GPU processing when PC in use

Post by katakaio »

I've encountered the same issue on every Linux install that I've folded on. My solution (which may or may not make sense for you) was to attach my monitor(s) to the integrated GPU output when I knew that I would be folding for an extended period of time. This completely eliminated any input/render lag since the integrated GPU was driving the display and the discrete GPU was doing nothing but folding.

Again, this may or may not be a practical solution for you, but I thought I'd share.
Rescue_166
Intel Core i5-6500 @ 3.2 GHz
EVGA GeForce RTX 2060 6GB XC Ultra
EVGA GeForce GTX 960 4GB FTW

Intel Core i5-3550 @ 3.3 GHz
EVGA GeForce GTX 750 Ti 2GB FTW
bruce
Posts: 20910
Joined: Thu Nov 29, 2007 10:13 pm
Location: So. Cal.

Re: Linux: Slow down GPU processing when PC in use

Post by bruce »

Not really. The FAHCore contains some (very limited) logic to limit the temperature by pasuing/unpausing the GPU at regular intervals but it has essentially been abandoned. Turning a hot device on and off puts more thermal stressis on it that just letting it get not.

With the right software, you can adjust the thermal/power/etc. limits as regulated by the driver, which is probably the best way to do it. Within FAH, itself, you can set the GPU to only run when your OS determines the system idle (sort of like a screensaver but with a blank screen that pauses when you use the Keyboard/Mouse and resumes folding when you don't
brunoais
Posts: 3
Joined: Wed Apr 01, 2020 1:02 pm

Re: Linux: Slow down GPU processing when PC in use

Post by brunoais »

bruce wrote:With the right software, you can adjust the thermal/power/etc. limits as regulated by the driver, which is probably the best way to do it. Within FAH, itself, you can set the GPU to only run when your OS determines the system idle (sort of like a screensaver but with a blank screen that pauses when you use the Keyboard/Mouse and resumes folding when you don't
I'm not sure if that detector is working on my PC. I left it working for the night once and the PC did nothing all night besides an update and a short backup I had crons for.
Is that detector working with X.org and xfwm4?
Post Reply