public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jan Glauber <jang@linux.vnet.ibm.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>,
	LKML <linux-kernel@vger.kernel.org>,
	vatsa@linux.vnet.ibm.com, mschwid2@linux.vnet.ibm.com,
	efault@gmx.de, dmitry.adamushko@gmail.com, paulus@samba.org,
	anton@samba.org
Subject: Re: [PATCH] virtual sched_clock() for s390
Date: Thu, 19 Jul 2007 19:20:21 +0000	[thread overview]
Message-ID: <1184872821.5516.10.camel@localhost.localdomain> (raw)
In-Reply-To: <20070719160025.GA31815@elte.hu>

On Thu, 2007-07-19 at 18:00 +0200, Ingo Molnar wrote:
> * Jeremy Fitzhardinge <jeremy@goop.org> wrote:
> 
> > >  /*
> > > - * Monotonic_clock - returns # of nanoseconds passed since time_init()
> > > + * Scheduler clock - returns current time in nanosec units.
> > > + * Now based on virtual cpu time to only account time the guest
> > > + * was actually running.
> > 
> > Runn*ing*?  Does it include time the VCPU spends idle/blocked?  If 
> > not, then the scheduler won't be able to tell how long a process has 
> > been asleep.  Maybe this doesn't matter (I had this problem in a 
> > version of Xen's sched_clock, and I can't say I saw an ill effects 
> > from it).

No, it does not include idle time, if we're going idle the cpu timer
gets stopped.

> CFS does measure time elapsed across task-sleep periods (and does 
> something similar to what the old scheduler's 'sleep average' 
> interactivity mechanism did), but that mechanism measures "time spent 
> running during sleep", not "time spent idling".
> 
> still, CFS needs time measurement across idle periods as well, for 
> another purpose: to be able to do precise task statistics for /proc. 
> (for top, ps, etc.) So it's still true that sched_clock() should include 
> idle periods too.

I'm not sure, s390 already has an implemetation for precise accounting
in the architecture code, does CFS also improve accounting data? 

Jan


  reply	other threads:[~2007-07-19 19:20 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-19 10:57 [PATCH] virtual sched_clock() for s390 Jan Glauber
2007-07-19 15:29 ` Jeremy Fitzhardinge
2007-07-19 15:48   ` Srivatsa Vaddagiri
2007-07-19 16:00   ` Ingo Molnar
2007-07-19 19:20     ` Jan Glauber [this message]
2007-07-19 19:38       ` Ingo Molnar
2007-07-19 21:07         ` Jan Glauber
2007-07-20  1:01     ` Paul Mackerras
2007-07-20  6:03       ` Jeremy Fitzhardinge
2007-07-20  7:22       ` Ingo Molnar
2007-07-23  9:15         ` Jan Glauber
2007-07-23 13:24           ` Martin Schwidefsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1184872821.5516.10.camel@localhost.localdomain \
    --to=jang@linux.vnet.ibm.com \
    --cc=anton@samba.org \
    --cc=dmitry.adamushko@gmail.com \
    --cc=efault@gmx.de \
    --cc=jeremy@goop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=mschwid2@linux.vnet.ibm.com \
    --cc=paulus@samba.org \
    --cc=vatsa@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox