Page 1 of 1

Reserve a CPU core for GPU

Posted: Thu May 14, 2020 7:56 pm
by manalog
Hi,
I am a Boinc cruncher but I started crunching again on Folding after having seen the great effort you are doing to fight the coronavirus.
I am running an host H24, it is a Xeon L5420 quad core processor coupled with a Nvidia 750ti. If I find a good offer I am planning to change it soon with a 1660 or a 1650 in order to contribute more efficiently.
Now I am running Folding full power on both CPU and GPU; the client automatically choose to use 3 cpu threads and leave the other one for the GPU. Perhaps in the next days or weeks I will start using again the CPU for Boinc projects related with Covid (WCG, Rosetta, Tn-Grid, Ibercivis) so I was wondering if it makes sense to limit the number of Boinc tasks to three in order to leave one core for the GPU running on FAH.
Moreover, another option: do you think is a good idea to continue running Folding also on CPU even if I start running Boinc again?
Thank you

Re: Reserve a CPU core for GPU

Posted: Thu May 14, 2020 8:17 pm
by JimboPalmer
If you only use F@H for the GPUs, you still want to reserve a CPU for the GPU.

This more important for Nvidia GPUs than for AMD cards, but a good idea either way.

AMD uses interrupts, if a CPU is always available to handle the interrupt, F@H will be faster.

https://en.wikipedia.org/wiki/Interrupt

Nvidia on the other hand uses Polled I/O, where the program loop forever waiting for a response. It uses an entire thread even when nothing need attention.

https://en.wikipedia.org/wiki/Busy_waiting

So if you can, allocate one less CPU thread to the other DC program.

Re: Reserve a CPU core for GPU

Posted: Sun May 17, 2020 10:21 pm
by FireFox-89
So does the CPU feed the GPU with the calculations?

Re: Reserve a CPU core for GPU

Posted: Sun May 17, 2020 10:28 pm
by JimboPalmer
All Data gets on and off the Graphics card via CPU operations. Uploads/downloads and check points.
There is a sanity check calculation at every check point to be sure the GPU has not gone astray.

Re: Reserve a CPU core for GPU

Posted: Sun May 17, 2020 10:30 pm
by FireFox-89
JimboPalmer wrote:All Data gets on and off the Graphics card via CPU operations. Uploads/downloads and check points.
There is a sanity check calculation at every check point to be sure the GPU has not gone astray.
Ahh OK, that makes sense :)

Re: Reserve a CPU core for GPU

Posted: Sun May 17, 2020 10:52 pm
by bruce
I don't recommend running both FAH and BOINC on the remaining CPUs. They don't do a nice job of sharing. Choose one or the other.

Re: Reserve a CPU core for GPU

Posted: Mon May 18, 2020 12:19 am
by MeeLee
You can run boinc and FAH together, as long as enough CPU threads are reserved for the GPU.
In Boinc you can easily set your system to use only 75% of (3 out of 4) cores, and the OS will assign the 4th core for sharing the GPU and the rest of the OS and client programs.
A quad core system will work better doing only one project though.
Sharing is easier when you have plenty of cores. But even then, it's often better to assign one PC to one project.
But it is possible; so long both programs aren't fighting for resources allocated to the other (you can't for instance, run Boinc and FAH on the same GPU; you'll lose more than 50% of performance).