Click here to Skip to main content
13,085,936 members (88,188 online)
Rate this:
Please Sign up or sign in to vote.
Cpu0  : 68.9%us,  4.6%sy,  0.0%ni, 20.5%id,  0.0%wa,  1.0%hi,  5.0%si,  0.0%st
Cpu1  : 58.1%us,  4.3%sy,  0.0%ni, 33.6%id,  0.0%wa,  0.0%hi,  4.0%si,  0.0%st
Cpu2  : 56.1%us,  5.0%sy,  0.0%ni, 34.9%id,  0.0%wa,  0.3%hi,  3.7%si,  0.0%st
Cpu3  : 55.8%us,  4.0%sy,  0.0%ni, 36.2%id,  0.0%wa,  0.0%hi,  4.0%si,  0.0%st
Cpu4  : 53.0%us,  5.6%sy,  0.0%ni, 38.4%id,  0.0%wa,  0.0%hi,  3.0%si,  0.0%st
Cpu5  : 53.0%us,  5.6%sy,  0.0%ni, 36.8%id,  0.0%wa,  0.0%hi,  4.6%si,  0.0%st
Cpu6  : 54.0%us,  4.3%sy,  0.0%ni, 38.1%id,  0.0%wa,  0.0%hi,  3.6%si,  0.0%st
Cpu7  : 53.6%us,  4.6%sy,  0.0%ni, 37.4%id,  0.0%wa,  0.3%hi,  4.0%si,  0.0%st
Cpu8  : 49.8%us,  5.6%sy,  0.0%ni, 40.2%id,  0.0%wa,  0.0%hi,  4.3%si,  0.0%st
Cpu9  : 55.4%us,  5.0%sy,  0.0%ni, 36.3%id,  0.0%wa,  1.0%hi,  2.3%si,  0.0%st
Cpu10 : 54.3%us,  6.0%sy,  0.0%ni, 34.8%id,  0.0%wa,  0.0%hi,  5.0%si,  0.0%st
Cpu11 : 53.6%us,  6.3%sy,  0.0%ni, 36.4%id,  0.0%wa,  0.7%hi,  3.0%si,  0.0%st
Cpu12 : 55.0%us,  4.0%sy,  0.0%ni, 37.1%id,  0.0%wa,  0.0%hi,  4.0%si,  0.0%st
Cpu13 : 53.7%us,  4.0%sy,  0.0%ni, 38.7%id,  0.0%wa,  0.3%hi,  3.3%si,  0.0%st
Cpu14 : 52.8%us,  5.0%sy,  0.0%ni, 37.6%id,  0.0%wa,  0.0%hi,  4.6%si,  0.0%st
Cpu15 : 56.8%us,  4.0%sy,  0.0%ni, 34.9%id,  0.0%wa,  1.0%hi,  3.3%si,  0.0%st

The service process running on linux system of MIPS platform. The process had about 70 threads, 16 threads bond to the 16 cores, every core bond a single thread. The left threads do not bond operation. So from the result we can see that the 0th core's cpu usage very high. I doubt the linux system make the left threads running on the 0th core. So the 0th core's cpu usage very high. How can I handle this problem? Thanks.
Posted 1-Nov-12 21:25pm
Jochen Arndt 2-Nov-12 4:18am
Are some threads bound to specific cores by your application?
If so, remove the binding and let the kernel assign the cores to the threads.
gn7575 2-Nov-12 6:15am
Yes, the board has 16 cores, we bound 16 service threads to each cores. The other threads not bound. The 16 service threads do a lot of work. The other threads just auxiliary.
Jochen Arndt 2-Nov-12 6:22am
Just try it without binding and compare the loads. The kernel usually makes a good switching job. You may also give the service threads a higher priority than the auxiliary threads and/or lower the priority of the aux threads.
nv3 2-Nov-12 4:35am
I don't think that a slightly higher CPU usage on core 0 is so unusual. System processes or an uneven distribution of the remaining threads might easily cause that. As Jochen said, better leave the distribution of threads to cores to the operating system, except you know very well what you are doing.
gn7575 2-Nov-12 6:26am
You are right, but some time it will make some problem.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Generally the threads within an application will execute on a single CPU because of the complexities of managing shared memory and instruction pipe lining.

If you execute 2 or more processes then you will see more usage on other CPU's.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web02 | 2.8.170813.1 | Last Updated 2 Nov 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100