Page 1 of 2
Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 1:49 am
by Peter_Hucker
The documentation says FAHClient (only v8?) allows for using multiple GPUs and CPUs (I assume it means CPU cores for the last one unless it's going to spread across computers!) on a single task. I don't see this happening, each task is using 1 GPU and 1 CPU (I'm only doing GPU work, I've ticked all the GPUs to run and turned the CPU cores down to minimum). Is this something planned for the future and scientists haven't released tasks utilising it yet, since not many volunteers are using v8 yet?
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 2:39 am
by jonault
On my machine it's intermittent. Sometimes I'll get 7 of the 8 CPU cores attached to one of the GPU tasks, other times the GPU tasks will get just get 1 CPU each and the remaining 6 CPU cores will work on their own task. I just let it do what it wants. But I let my system use all the CPU cores - if you've told your system to minimize CPU usage it sounds like you're getting what you asked for.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 3:51 am
by calxalot
For now, you can get more control by making a Resource Group for each GPU, similar to v7 slots.
Set everything to Finish and wait for pause before changing resource allocation.
In client Settings, create a RG by adding a peer that begins with "/". Example /gpu1
Add resources to the group after removing those resources from the default unnamed group.
A GPU RG should have one cpu and one gpu selected.
If you don't want to do CPU folding, set cpus to zero for the default group.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:02 am
by Peter_Hucker
No I didn't ask it not to use the CPU. I asked it to use the CPU only to assist the GPUs. I assume pushing the slider all the way to the left means don't do CPU tasks, since as you add GPUs, the minimum increases by 1 per GPU.
I also don't get any tasks using both GPUs at once.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:21 am
by jonault
Peter_Hucker wrote: ↑Thu Feb 09, 2023 4:02 am
No I didn't ask it not to use the CPU. I asked it to use the CPU only to assist the GPUs. I assume pushing the slider all the way to the left means don't do CPU tasks, since as you add GPUs, the minimum increases by 1 per GPU.
I think the slider does exactly what it says & sets the number of CPU cores it will use for folding. Since you have to have one CPU per GPU, it won't go below that, but if you slide it all the way to the left that's all you get - one core per GPU and no more. If you want to devote all the remaining CPU cores to one of the GPU tasks, you'll need to do what calxalot said & create a Resource Group containing one GPU and all the CPU cores except one.
I also don't get any tasks using both GPUs at once.
I haven't seen any tasks like that yet either.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:23 am
by calxalot
Not quite. Each RG should only get one cpu and one gpu.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:32 am
by jonault
calxalot wrote: ↑Thu Feb 09, 2023 4:23 am
Not quite. Each RG should only get one cpu and one gpu.
But won't that limit each folding task to using just one CPU and one GPU?
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:33 am
by calxalot
You want the RG to only fold one GPU WU.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:37 am
by jonault
Right, but how many CPU cores would it use? Would it ever go above 1?
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:38 am
by calxalot
You create a RG for each GPU, using the Peers list.
Remaing cpus can be assigned to default unnamed group.
If you create a Resource Group Peer, this will be clearer.
RGs are an undocumented feature.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:42 am
by jonault
So the default group doesn't get assigned a folding task?
I guess I'll have to try doing this tomorrow.
Sorry for all the questions, I'm just trying to understand how this works.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:45 am
by Peter_Hucker
This is getting complicated. I want to do mainly GPU work, so no CPU-only work at all. On the remote chance of a GPU task wanting more than one CPU core for assistance, I want to allow that. If it happens a lot, I can turn down the Asteroids stuff to leave more CPU cores free.
Can someone explain how I would achieve this? Perhaps by setting each of the two GPUs to have 12 cores each?
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:46 am
by calxalot
The default group uses whatever resources you assign.
A GPU WU only needs one cpu.
You have to remove resources from default group before you can then add those resources to a RG.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 4:56 am
by Peter_Hucker
If a GPU only ever needs one CPU core, I don't need to change anything. I guess I just wait to see if any tasks use two GPUs. I have one machine with 3 identical GPUs, and one with two different ones (one is twice the speed). So I might see something one day.
Re: Multiple GPUs and CPUs?
Posted: Thu Feb 09, 2023 5:00 am
by jonault
A GPU WU needs one cpu, but some GPU work units will use more than that if they're available - I've had work units with 1 GPU and 7 CPU cores assigned. So I thin the quest Peter is asking is how can you make your CPU cores available to assist a GPU WU but prevent them from being assigned to a CPU WU.