lkml.org 
[lkml]   [2004]   [Mar]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: finding out the value of HZ from userspace
Tim Schmielau wrote:
> On Sun, 21 Mar 2004, Peter Williams wrote:
>
>
>>In the 2.6 kernels internal timing and task statistics (for i386
>>systems) are now kept in milliseconds where they were previously in
>>1/100ths of a second. By converting these statistics to 1/100ths of a
>>second for export to user space an order of magnitude (i.e. a factor of
>>10) loss of precision occurs.
>
>
> No. The statistics are not a result of full bookkeeping, but simply
> gained by periodically sampling the processor state. So they don't
> have a precision of 1/1000th of a second anyways.

1/1000th of a second IS the internal timing precision. The issue of how
tasks' CPU usage is allocated for reporting is a different matter but
from a statistical viewpoint this will just effect the variance (or
standard deviation) of the estimates and NOT their precision. As the
number of samples the variance (or standard deviation) decrease rapidly
so to all intents and purposes the statistics are accurate to the
nearest 1/1000th of a second.

Peter
--
Dr Peter Williams, Chief Scientist peterw@aurema.com
Aurema Pty Limited Tel:+61 2 9698 2322
PO Box 305, Strawberry Hills NSW 2012, Australia Fax:+61 2 9699 9174
79 Myrtle Street, Chippendale NSW 2008, Australia http://www.aurema.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:01    [W:0.120 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site