How much CPU for a GPU WU?

Moderators: Site Moderators, PandeGroup

How much CPU for a GPU WU?

Postby snapshot » Mon May 13, 2019 4:26 pm

How much CPU power does FAH need to feed a GPU? I thought it was supposed to be one core and one PC is using around 25% of an old dual core/four thread i3 to feed a GTX 1060 which seems bear that out. But my new PC with a new six-core i5 is using around 30% to feed a GTX 1050 Ti which is more like two cores. Is there an explanation of this that I've forgotten about?
User avatar
snapshot
 
Posts: 110
Joined: Thu Apr 09, 2009 7:25 pm
Location: Wiltshire, UK

Re: How much CPU for a GPU WU?

Postby bruce » Mon May 13, 2019 4:50 pm

The CPU utilization depends on several factors -- mostly on the driver. The original recommendation was allocate one free thread per GPU, and that's still a pretty good recommendation. If the GPU is powerful and the CPU is weak, that can limit GPU production. On the other hand, some recent versions of OpenMM can offload some of the calculations to the CPU which can increase total throughput -- but I think this is sill a rare phenomenon.

Is the 30% a constant load over time and does it go to 0% if you pause the GPU?
bruce
 
Posts: 22437
Joined: Thu Nov 29, 2007 10:13 pm
Location: So. Cal.

Re: How much CPU for a GPU WU?

Postby snapshot » Mon May 13, 2019 5:26 pm

Yes, it's constant with Task Manager showing FAHCore using about 28% and 4% for the rest. The 4% remains if I pause FAH.
Both PCs are on the same Nvidia driver but the one we're interested in is on W10, the other on W7. I'd happily blame W10.....
Come to think of it, the GTX 1050 didn't exhibit this behaviour when it was on W7. CPU usage under an i7 was the 12% or 13% one would expect.
User avatar
snapshot
 
Posts: 110
Joined: Thu Apr 09, 2009 7:25 pm
Location: Wiltshire, UK

Re: How much CPU for a GPU WU?

Postby MeeLee » Mon May 13, 2019 11:49 pm

If your new CPU has Hyperthreading, the system may occasionally use 2 cores instead of one on a non-hyperthreaded CPU.
I would recommend using Linux for folding.
It's difficult to get it to work, but once it works, it works a lot better than windows. Especially for folding.
MeeLee
 
Posts: 257
Joined: Tue Feb 19, 2019 10:16 pm

Re: How much CPU for a GPU WU?

Postby snapshot » Wed May 15, 2019 5:23 am

No, the old i7 had hyperthreading, the i5 doesn't. What I actually see is the opposite of your suggestion.
Donkey's years ago I used to run Linux in a VM for folding but these days it's about as much use to me as a bicycle is to a fish.
User avatar
snapshot
 
Posts: 110
Joined: Thu Apr 09, 2009 7:25 pm
Location: Wiltshire, UK

Re: How much CPU for a GPU WU?

Postby bruce » Wed May 15, 2019 3:07 pm

FAH will allocate one thread to each CPU. What it actually uses isn't equivalent to that.

With hyperthreading enabled, two threads are associated with the hardware that represents one CPU Core. Each CPU Core, whether on an i5 or an i7 is capable of doing about the same amount of work, but that's not the real question since the GPU drivers use spin-waits. That means the software that reports your CPU status will show 100% of a thread busy, whether it's actually doing necessary work or it's in a CPU-burning loop, wasting resources.

On an i5, one CPU will appear to be 100% busy.l On an I7 with hyperthreading enabled, one thread will appear to be 100% busy running the same Windows NV driver.

Spin-waits are distinctly different than when a CPU is used for actual 3D calculations, An i5 (or an i7 with HT disabled) will produce certain number of GFLOPS. Switch HT on, and the same hardware will produce the same number of GFLOPS but now two threads appear in the CPU monitoring program where there was only one. Those 2 threads can do about 15% more 3D calculations because threal CPU will be able to overlap 3D calculations with non-floating point operations.
bruce
 
Posts: 22437
Joined: Thu Nov 29, 2007 10:13 pm
Location: So. Cal.

Re: How much CPU for a GPU WU?

Postby MeeLee » Wed May 15, 2019 7:52 pm

Since it's only 4% of a CPU core, I wouldn't lie awake over it.
It's probably system overhead. Read/Writes, system background activity.
Gets worse with Windows than Linux.
On my Xeon system it uses 95% of an entire thread extra (out of 20 threads).

Folding from VM is worse, as Windows still uses the resources the same way.
If Linux folds at 100% efficiency, and Windows at 90%; running Linux in a VM in Windows, will reduce your efficiency to <85%.
It gives a lot more overhead.
A VM is great to learn to use Linux, but you'll have to boot in Linux natively for best results.
MeeLee
 
Posts: 257
Joined: Tue Feb 19, 2019 10:16 pm

Re: How much CPU for a GPU WU?

Postby snapshot » Fri May 17, 2019 6:26 am

I don't give a monkey's about the 4%. My question has always been why is FAH using 28% when we're all agreed it should be 17%.
User avatar
snapshot
 
Posts: 110
Joined: Thu Apr 09, 2009 7:25 pm
Location: Wiltshire, UK

Re: How much CPU for a GPU WU?

Postby bruce » Fri May 17, 2019 3:25 pm

snapshot wrote:I don't give a monkey's about the 4%. My question has always been why is FAH using 28% when we're all agreed it should be 17%.

Because newer versions of the software used in FAHCores have been enhanced to use assist the GPU bu use the CPU for additional portions of the calculations. The GPU drivers, themselves, will use up to 17% -- unless AMD/NVidia modify their drivers.

The FAHCore contains a variety of code segments, most of which can allocate a large number of parallel threads, but those segments are not uniform. It's not a good idea to have a GPU mostly idle when it's running a segment of the calculation that cannot use more that a few of shaders, so running that segment on a CPU allows the GPU to proceed with segments that are highly parallelizable.
bruce
 
Posts: 22437
Joined: Thu Nov 29, 2007 10:13 pm
Location: So. Cal.

Re: How much CPU for a GPU WU?

Postby Yavanius » Sun Jun 23, 2019 6:32 pm

Just for future reference... Task Manager does NOT give a true representation of everything that's running. There are processes (especially with VM) that don't show up on it. (Sofar as I know the ones with Linux distros do but there are so many distros it's impossible to say for certain.)

Here's an article for some alternatives, one of them being Process Explorer from Microsoft itself. Actually found about this couple years when I was running VirtualBox clients belonging to BOINC projects. We could tell there was an impact on the system but we couldn't see WHERE those resources were going to with just Task Manager (no sir, I don't know about any elephant in the room). I also came back to my system one day with my system swapping out memory like crazy. Couldn't find where the leak was coming from...
User avatar
Yavanius
 
Posts: 115
Joined: Thu Nov 03, 2016 4:55 am
Location: 92408


Return to V7.5.1 Public Release Windows/Linux/MacOS X

Who is online

Users browsing this forum: No registered users and 1 guest

cron