lkml.org 
[lkml]   [2005]   [Nov]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Patch 1/4] Delay accounting: Initialization
Andrew Morton wrote:
> Shailabh Nagar <nagar@watson.ibm.com> wrote:
>
>>+ *ts = sched_clock();
>
>
> I'm not sure that it's kosher to use sched_clock() for fine-grained
> timestamping like this. Ingo had issues with it last time this happened?
>
> <too lazy to read all the code> Do you normalise these numbers in some
> manner before presenting them to userspace? If so, by what means?

The cpu delay data collected by schedstats (which is jiffies based)
is normalized to nanosecs. The timestamps based on sched_clock() are exported
as is. As Marcelo pointed out, thats not good enough since sched_clock() itself
could return jiffie-based resolution. So some normalization will be needed for
that data as well.



-
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-11-15 16:07    [W:0.087 / U:0.752 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site