Why top(1) only shows time of the main thread?

Yuri yuri at rawbw.com
Sat Jan 8 07:37:42 UTC 2011


On 01/07/2011 14:33, Anonymous wrote:
> Yuri<yuri at rawbw.com>  writes:
>
>    
>> TIME column is supposed to show time of the process (according to its
>> man page).
>> But it seems like it only shows the time of its main thread.
>>
>> Why? Bug in documentation?
>>      
> Wasn't this fixed in r182966?
>    

You are right according to this revision log (in stable/8):
"
r182966 | sepotvin | 2008-09-12 10:54:50 -0700 (Fri, 12 Sep 2008) | 7 lines

Display the sum of the runtime of all the threads in a process when it's
multithreaded instead of picking the time of the first thread found.
"

But I have rebuilt my system 8.1-STABLE on Oct 11 2010 and my top only 
shows the main thread's CPU use.

How can this be?
Yuri



More information about the freebsd-questions mailing list