Re: [PATCH] x86, AMD: Set sched_clock_stable

From: Peter Zijlstra
Date: Wed Feb 15 2012 - 10:30:58 EST


On Tue, 2012-02-07 at 13:08 +0100, Borislav Petkov wrote:
> Stephane Eranian reported that doing a scheduler latency measurements
> with perf on AMD doesn't work out as expected due to the fact that the
> sched_clock() granularity is too coarse, i.e. done in jiffies due to the
> sched_clock_stable not set, which, if set, would mean that we get to use
> the TSC as sample source which would give us much higher precision.

FWIW that's not entirely accurate, the problem with !sched_clock_stable
is that the time between CPUs can drift a little. So while timestamps on
the same CPU are high-res, when comparing them across CPUs you can
observe funnies.


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