All of lore.kernel.org
 help / color / mirror / Atom feed
From: NISHIGUCHI Naoki <nisiguti@jp.fujitsu.com>
To: George Dunlap <dunlapg@umich.edu>, xen-devel@lists.xensource.com
Cc: Ian.Pratt@eu.citrix.com, disheng.su@intel.com,
	Keir Fraser <keir.fraser@eu.citrix.com>
Subject: Re: [RFC][PATCH] scheduler: credit scheduler for client virtualization
Date: Thu, 04 Dec 2008 16:51:50 +0900	[thread overview]
Message-ID: <49378C16.1040106@jp.fujitsu.com> (raw)
In-Reply-To: <de76405a0812030446m38290b2ex9d624a0f7d788cfc@mail.gmail.com>

Thank you for your suggestions.

George Dunlap wrote:
> On Wed, Dec 3, 2008 at 9:16 AM, Keir Fraser <keir.fraser@eu.citrix.com> wrote:
>> Don't hack it into the existing sched_credit.c unless you are really sharing
>> significant amounts of stuff (which it looks like you aren't?).
>> sched_bcredit.c would be a cleaner name if there's no sharing. Is a new
>> scheduler necessary -- could the existing credit scheduler be generalised
>> with your boost mechanism to be suitable for both client and server?
> 
> I think we ought to be able to work this out; the functionality
> doesn't sound that different, and as you say, keeping two schedulers
> around is only an invitation to bitrot.

I had thought that the scheduler for client would be needed separately 
because this modification would influence a server workload. In order to 
minimize modifications, the bcredit scheduler was implemented by 
wrapping the current credit scheduler. I added the differences between 
original and bcredit. But as a result, almost functions were created newly.

Now, I agree that one scheduler is best.

> The more accurate credit scheduling and vcpu credit "balancing" seem
> like good ideas.  For the other changes, it's probably worth measuring
> on a battery of tests to see what kinds of effects we get, especially
> on network throughput.

I didn’t think about the battery and the performance.

> Nishiguchi-san, (I hope that's right!) as I understood from your
> presentation, you haven't tested this on a server workload, but you
> predict that the "boost" scheduling of 2ms will cause unnecessary
> overhead for server workloads.  Is that correct?

Yes, you are correct. I answered that in Q/A.

> Couldn't we avoid the overhead this way:  If a vcpu has 5 or more
> "boost" credits, we simply set the next-timer to 10ms.  If the vcpu
> yields before then, we subtract the amount of "boost" credits actually
> used.  If not, we subtract 5.  That way we're not interrupting any
> more frequently than we were before.

I set the next-timer to 2ms in any vcpu having “boost” credits since 
every vcpu having “boost” credits need to be run equally at short 
intervals. If there are vcpus having “boost” credits and the next-timer 
of a vcpu is set to 10ms, the other vcpus will be waited during 10ms.

At present, I am thinking that if the other vcpus don’t have “boost” 
credits then we may set the next-timer to 30ms.


> Come to think of it: won't the effect of setting the 'boost' time to
> 2ms be basically counteracted by giving domains boost credits?  I
> thought the purpose reducing the boost time was to allow other domains
> to run more quickly?  But if a domain has more than 5 'boost' credits,
> it will run for a full 10 ms anyway.  Is that not so?

I suppose that there are two domains given “boost” credits. One domain 
runs for 2ms, then the other domain runs for 2ms, then one domain runs 
for 2ms, then the other domain runs for 2ms, … Because I think to need 
that waited time of both is same.

> Could you test your video latency measurement with all the other
> optimizations, but with the "boost" time set to 10ms instead of 2?  If
> it works well, it's probably worth simply merging the bulk of your
> changes in and testing with server workloads.

I tested the video latency measurement with the “boost” time set to 
10ms. But it regretted not to work well. As I was mentioned above, the 
vcpu was occasionally waited during 10ms.

On my patch, “boost” time is tuneable. How about the default “boost” 
time is 30ms and if necessary, “boost” time is set? Is it acceptable?

In order to lengthen the “boost” time as much as possible, I will think 
about computing the length of the next-timer of the vcpu having “boost” 
credits.
I’ll try to revise the patch.

And thanks again.

Best regards,
Naoki Nishiguchi

  reply	other threads:[~2008-12-04  7:51 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-03  8:54 [RFC][PATCH] scheduler: credit scheduler for client virtualization NISHIGUCHI Naoki
2008-12-03  9:16 ` Keir Fraser
2008-12-03 12:46   ` George Dunlap
2008-12-04  7:51     ` NISHIGUCHI Naoki [this message]
2008-12-04 12:21       ` George Dunlap
2008-12-04 12:37         ` George Dunlap
2008-12-05  3:17           ` NISHIGUCHI Naoki
2008-12-18  2:49             ` NISHIGUCHI Naoki
2008-12-18 10:21               ` George Dunlap
2008-12-05  2:47         ` NISHIGUCHI Naoki
2008-12-05 11:37           ` George Dunlap
2008-12-08  8:37             ` NISHIGUCHI Naoki
2008-12-04  7:45   ` NISHIGUCHI Naoki
     [not found] ` <de76405a0901191232k19d910d5o77160fa5ee7bf06c@mail.gmail.com>
     [not found]   ` <de76405a0901191257p3b45304fi538d040b5634de23@mail.gmail.com>
     [not found]     ` <49768FDB.60609@jp.fujitsu.com>
2009-01-21 10:35       ` George Dunlap
2009-01-22  6:15         ` NISHIGUCHI Naoki

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=49378C16.1040106@jp.fujitsu.com \
    --to=nisiguti@jp.fujitsu.com \
    --cc=Ian.Pratt@eu.citrix.com \
    --cc=disheng.su@intel.com \
    --cc=dunlapg@umich.edu \
    --cc=keir.fraser@eu.citrix.com \
    --cc=xen-devel@lists.xensource.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.