[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] open Linux question



On 13/12/07 11:28, "Jan Beulich" <jbeulich@xxxxxxxxxx> wrote:

> I'm not talking about the whole time handling, just the sched_clock()
> implementation taking stolen time into account.
> 
> I have to admit that one of the reasons that I didn't try doing this so far
> is the odd 'if (offset < 0)' check in there - I would have expected that
> rather than doing this the xen_clocksource_read()/get_runstate_snapshot()
> pair would need to go in a loop checking that the time version didn't
> change (and then a negative offset ought to be a bug).

Oh, I see. I think the pv_ops sched_clock() implementation is fine.
xen_clocksource_read()/get_runstate_snapshot() do their own version-checkign
loops, and I don't think there is really an accuracy issue in not pulling
those checks into an outer loop. The 'offset < 0' check is cheap and
frankly, where time based on TSC is concerned, it's a nice safety catch. I'd
be happy to see that sched_clock() implementation ported into other trees.

 -- Keir



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.