How process CPU percentage is calculated?

Yuri yuri at rawbw.com
Tue Jan 6 23:53:37 PST 2009


I have a process that is CPU intense.
'top -C' shows CPU usage for this process no higher than 20%, more like 
15-18%.
But TIME field grows 10 sec for every 15-17 secs or real time.

top(1) says: Each time -C flag is passed it  toggles between  "raw  
cpu"  mode  and  "weighted cpu" mode

So I am looking at "raw cpu". With 15-18% CPU every second of process 
TIME should correspond to ~6secs of real time, and in my case it's only 
~1.6sec of real time.

Why CPU field is so low?

Yuri



More information about the freebsd-questions mailing list