[Haifux] CPU usage percentage doesn't add up
ohad at lutzky.net
Fri Feb 25 17:37:28 MSK 2011
A peer of mine is developing a multi-platform C++ application, and would
like to test the CPU usage difference of the application between Windows and
Linux. However, running `top` shows him that his single process is using 20%
CPU, whereas the total CPU usage is only 0.5%-2%. This is a quad-core
machine, so even dividing the 20% by 4 will give 5%, which is still far too
high. Windows gives him a satisfactory measurement of this statistic. Can
anyone here explain why this happens?
Man is the only animal that laughs and weeps, for he is the only animal that
is struck with the difference between what things are and what they ought to
- William Hazlitt
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haifux