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

Re: [PATCH] Re: [Xen-devel] Time went backwards



On Tue, 14 Mar 2006, Keir Fraser wrote:
> On 13 Mar 2006, at 23:07, Rik van Riel wrote:
> 
> > OK, finally nailed it!   When both stolen and blocked are rounded
> > down, it is possible for the final increment of the cpu local
> > processed_system_time to move the cpu local system time ahead a
> > bit further than expected - but still proper wrt. wall clock time.
> 
> Thanks for tracking this down!
> 
> I'm not sure how you mean that rounding down stolen and blocked causes 
> time to get progressed further than expected,

Not initially, but on the next timer tick.  Lets use jiffies as
the time unit in this example:

Tick N:
        delta = 2.2
        stolen = 0.9
        blocked = 0.7

        stolen and blocked will not get incremented, while
        the per-cpu processed_time gets 2 jiffies

Tick N+1:
        delta = 1.5
        stolen = 1.3    (includes the 0.9 from the last tick)
        blocked = 1.1   (includes the 0.7 from the last tick)

        stolen gets incremented by 1, blocked gets incremented
        by 1, and (as a consequence) the per-cpu procssed_time
        gets incremented by 2  -  1 more than it should be!

-- 
All Rights Reversed

_______________________________________________
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®.