WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

Re: [Xen-ia64-devel] [PATCH][3/3] Steal time accounting forPVdomain/IA64

To: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
Subject: Re: [Xen-ia64-devel] [PATCH][3/3] Steal time accounting forPVdomain/IA64 TAKE2
From: Atsushi SAKAI <sakaia@xxxxxxxxxxxxxx>
Date: Thu, 15 May 2008 18:02:00 +0900
Cc: Aron Griffis <aron@xxxxxx>, xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 15 May 2008 02:03:15 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20080515065619.GG26415%yamahata@xxxxxxxxxxxxx>
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20080515065619.GG26415%yamahata@xxxxxxxxxxxxx>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
Hi, Isaku

Thank you for your comments.

consider_steal_time() treats stolentick.
The stolentick is composed of l->itm_delta + alpha.
The stolentick can consider the large value(unsigned long).
So stolentick can take from 0 to unsigned long.
In this meaning, the value of alpha has no assumption in it.

As you suggested, if we consider the case of manu vcpu on one pcpu,
the alpha value expected to become large value.
But no problem in it.



Thanks
Atsushi SAKAI


Isaku Yamahata <yamahata@xxxxxxxxxxxxx> wrote:

> On Wed, May 14, 2008 at 06:24:07PM +0900, Atsushi SAKAI wrote:
> 
> > > local_cpu_data->itm_next can be past.
> > > i.e. It can be smaller than ia64_get_itc() - local_cpu_data->itm_delta.
> > 
> > As you know, the steal time accounting should count 
> > the time between previous interrupt to current interrupt.
> > 
> > So I should define 3 time values.
> > prev:(Previously accounted time) eq.1
> >     l->itm_next - l->itm_delta
> > last:(Expected Interrupt time) eq.2
> >     l->itm_next
> > current:(Current Interrupt Time) eq.3
> >     l->itm_next + alpha(=ia64_get_itc())
> > 
> > >From using prev:(eq.1) and current:(eq.3) eq.4
> >      stolentick( delta_cpu in x86) = l->itm_delta + alpha.
> > 
> > >From eq.3  and subtract l->itm_delta. eq.5
> >      l->itm_next + alpha - l->itm_delta = ia64_get_itc() - l->itm_delta
> > 
> > In eq.5,
> >     alpha - l->itm_delta is not guaranteed to positive.
> >     (it gets the value from - l->itm_delta  to positive value.)
> > 
> > l->itm_next can be past as you suggested,
> > but It can not be always smaller than ia64_get_itc() - 
> > local_cpu_data->itm_delta.
> > If only one domain is running on one cpu, alpha is very small.
> > In this case, alpha - l->itm_delta goes to negative.
> 
> At last we're reaching to the point.
> I had wanted to claim that the above "alpha" can easily become
> larger than l->idm_delta.
> You assumed that "If only one domain is running on one cpu",
> but clearly this assumption is not always true.
> What if many vCPU are running on same pCPU? It would be possible
> that alpha can be large.
> 
> Even "If only one domain is running on one cpu",
> assuming that "alpha is very small" would be a bad idea.
> Yes, surely timer interrupt handler shouldn't take so long time,
> and interruption shouldn't be masked for so long time.
> But I'm not sure on loaded system. timer_interrupt() surely is
> coded such that it is tolerable with large "alpha".
> Why not with consider_steal_time()?
> 
> 
> thanks,
> -- 
> yamahata



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