Message boards :
Graphics cards (GPUs) :
Why does GPU process take 0.5 (or whatever) CPU time?
Message board moderation
| Author | Message |
|---|---|
|
Send message Joined: 19 Mar 11 Posts: 30 Credit: 109,550,770 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Is the CPU usage for GPU tasks just dispatcher overhead or is there actual computational stuff going on too? |
skgivenSend message Joined: 23 Apr 09 Posts: 3968 Credit: 1,995,359,260 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Varies with different task types. Most of the more recent tasks are fairly CPU lite. Tasks that use more CPU are supposed to award slightly higher credit to compensate for the CPU usage. FAQ's HOW TO: - Opt out of Beta Tests - Ask for Help |
|
Send message Joined: 1 Mar 10 Posts: 147 Credit: 1,077,535,540 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Varies with different task types. Most of the more recent tasks are fairly CPU lite. Tasks that use more CPU are supposed to award slightly higher credit to compensate for the CPU usage. Since I changed my GTX460so for a GTX590 I noticed the following: GTX460: with CPU usage set to 85% of the 6 cores, it used 1 CPU with some percentage I forgot to notice (about 0.12 or higher) and 5 for WCG GTX590 (2GPUs) : Same CPU core ration set to 85%, it uses 0.51 of one CPU for each GPU, so 4 remaining for WCG. There's something wrong: It should not use more than one CPU for GPUGRID because 85% of 6 is 5.1 ! It seems that one CPU cannot be shared among 2 GPUs and it allocates one CPU for each GPU despite the CPU usage ratio I set. So what is the real allocation algorithm ? Lubuntu 16.04.1 LTS x64 |
skgivenSend message Joined: 23 Apr 09 Posts: 3968 Credit: 1,995,359,260 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
When you set Boinc to use 5 of the 6 CPU's, all you are doing is telling Boinc to free up one CPU to facilitate GPU usage. You are not specifically instructing Boinc to only use 1 CPU for GPU tasks. The GPU tasks will use whatever is needed. This is not unique to GPUGrid, it's the same on other GPU projects, and different projects require different amounts of the CPU to facilitate GPU tasks. If you don't free the CPU then you can often run into trouble. The system becomes sluggish, tasks compete for the same resources and failures increase. For a 6Core CPU (approx.) Boinc 6.10: (On Multi-processor systems use at most) 100% = use all 6 CPU cores to crunch CPU tasks & GPU tasks 83.33% to 99.99% = use 5cores for CPU tasks (GPU will use what it needs) 66.66% to 83.33% = use 4cores 50% to 66.66% = use 3cores 33.33% to 50% = use 2cores 16.66% to 33.33% = use 1core 0.01% to 16.66% = use 1core AFAICT 0.00% = use 6 CPU cores to crunch CPU and GPU tasks! In theory, GPU tasks run at a slightly higher priority than CPU tasks, so when the GPU needs to use the CPU it gets prioritized. However this is not exactly foolproof and typically the GPU tasks have to wait a small amount of time to use the CPU, which slows down the GPU task overall. Hence some people go to extreme lengths to optimize for the GPU (Process lasso, eFmer, SWAN_SYNC). A GTX460 is CC2.1 and your GTX590 is newer generation CC2.0 card. Your GTX590 performance is slightly more than four times that of a GTX460 at GPUGrid. So the amount of CPU required to accommodate the GPU has more than quadrupled from a single GTX460. If you use SWAN_SYNC you should free at least one CPU for every GPU. If not the requirement from the CPU to facilitate various GPU tasks will change somewhat with the task type. So for example, a TONI task might use 35% of one CPU core (while running on a GTX590), a GIANNI task might require 16% of one CPU core and a NATHAN task might require 51%. Personally, I never saturate the CPU, because I'm GPU orientated, I use my systems and I like responsiveness. With a GTX590 and a 6core (~57GFlops) I would free at least 2 CPU cores if I was going to use the system. FAQ's HOW TO: - Opt out of Beta Tests - Ask for Help |
|
Send message Joined: 1 Mar 10 Posts: 147 Credit: 1,077,535,540 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Personally, I never saturate the CPU, because I'm GPU orientated, I use my systems and I like responsiveness. With a GTX590 and a 6core (~57GFlops) I would free at least 2 CPU cores if I was going to use the system. Thanks a lot for these precisions I'm using my 6 cores Linux PC with the GTX590 only for GPUGRID and WCG. I use another one (Win7, 4cores) for GPUGRID,WCG and other works. PS : GIANNI and NATHAN take each 0.51 according to Boinc manager. For me using 4 cores for WCG needs to set 84% . SWAN_SYNC is set and 2 cores are used for GPU. Lubuntu 16.04.1 LTS x64 |
|
Send message Joined: 20 Jan 11 Posts: 6 Credit: 10,705,495 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Because CUDA requires that the CPU instructs the GPU calculations. |
|
Send message Joined: 8 Jan 12 Posts: 20 Credit: 5,132,859 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]()
|
I have 2 Phenom II X4 945 / GTX460 combo's, one (SC) crunching on GPUGRID and Malariacontrol and the other one (FTW) on GPUGRID and R@H. What would I gain in speed/production if I dedicate one core to GPUGRID ? And should I use the SWAN_SYNC=0 environmental setting to achieve this or just set boinc to 75% ? |
|
Send message Joined: 8 Jan 12 Posts: 20 Credit: 5,132,859 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]()
|
It looks like setting boinc to 75% slows speed down considerably. |
skgivenSend message Joined: 23 Apr 09 Posts: 3968 Credit: 1,995,359,260 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
As you use Windows SWAN_SYNC is not necessary, but it would still probably increase GPU task performance slightly (a few percent). If you use SWAN_SYNC you must free up a CPU core to gain any benefit and restart, but on a quad without HT and a mid range GPU it's a bit much to lose a full CPU core for such a small GPU increase. With a higher end GPU the picture would change significantly; a GTX590 for example would do 4times the work of a GTX460 and would use a full CPU core (or more) anyway. With your systems I would probably stick to crunching on 4 CPU cores and not use SWAN_SYNC (if I did not use the system much). If you use your system a lot, you might want to free up a CPU core just to improve system responsiveness. I did make a request one time for Boinc to facilitate using one CPU core less when the system is in use, but as yet this has not been implemented. When freeing up a CPU core you never actually loose a full core. Operating systems tend to use around 3% of an average quad CPU, and even a highly optimized high end system uses some CPU just for the operating system, even if it's only ~1%. When running a GPU application that requires some CPU (and all do to some extent) the loss is further reduced (say by 10% of one CPU core). The gain in GPU performance usually makes up for lost CPU performance (in terms of Boinc credit). Just remember SWAN_SYNC is different and does use a full CPU core. FAQ's HOW TO: - Opt out of Beta Tests - Ask for Help |
|
Send message Joined: 8 Jan 12 Posts: 20 Credit: 5,132,859 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]()
|
@ skgiven : Thanks for your info. At the moment I want to get my subteam (GP) as fast as possible into the top 30 (or higher) at DPC so I've set one core entirely on GPUGRID and SWAN_SYNC=0. |
|
Send message Joined: 8 Jan 12 Posts: 20 Credit: 5,132,859 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]()
|
And changed boinc preferences back to 100% 'cause boinc tends to change parameters randomly sometimes and than they all change as it did now. Left SWAN however but don't know it's doing something. And deleted that too after a SWAN: Using synchronization method 0 MDIO: cannot open file "restart.coor" error. |
|
Send message Joined: 5 Dec 11 Posts: 147 Credit: 69,970,684 RAC: 0 Level ![]() Scientific publications ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
I have an i7-2600k @4.5 1 560 ti 1 460 I let all 8 cores crunch gpu grid and the gpus take .5 cores each. seems to work fine crunches 8 wcg tasks and the 2 gpugrid at the same time. the wcg tasks may run a bit slower, but still easily complete before the due date, as do both my GPUS even on long runs. |
©2025 Universitat Pompeu Fabra