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/
Home Products Support Community News


[Xen-devel] RE: The caculation of the credit in credit_scheduler

To: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>
Subject: [Xen-devel] RE: The caculation of the credit in credit_scheduler
From: "Zhang, Xiantao" <xiantao.zhang@xxxxxxxxx>
Date: Mon, 15 Nov 2010 12:29:37 +0800
Accept-language: en-US
Acceptlanguage: en-US
Cc: "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx>, "Dong, Eddie" <eddie.dong@xxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Sun, 14 Nov 2010 20:32:19 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4CD957C1.4050300@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <789F9655DD1B8F43B48D77C5D30659732FD0A5C9@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <BC00F5384FCFC9499AF06F92E8B78A9E1C06EC6BF5@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <4CD957C1.4050300@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcuAGL3G6X48julLSQe4HuiQ0/mqrwEZBfjg
Thread-topic: The caculation of the credit in credit_scheduler
George Dunlap wrote:
> Xiantao,
> Thanks for your comments.  All of the things you pointed out are
> things 
> I'm trying to address in credit2.  In fact, a huge amount of them can
> be 
> attributed to the fact that credit1 divides tasks into 3 priorities
> (OVER, UNDER, and BOOST) and will schedule tasks "round-robin" within
> a 
> each priority.  Round-robin is known to discriminate against tasks
> which 
> yield (such as tasks that do frequent I/O) in favor of tasks that
> don't 
> yield (such as cpu "burners").
> In credit2, I hope to address these issues in a couple of ways:
> * Always sort the runqueue by order of credit.  This addresses issues
> in 
> all of 1, 2, and 3.
> * When a VM wakes up, update the credit of all the running VMs to see
> if 
> any of them should be preempted (addressing #3)
> * When selecting how long to run, I have a mechanism to look at the
> next 
> VM in the runqueue, and calculate how long it would take for the
> current 
> VM's credit to equal the next VM's credit.  I.e., if the one chosen to
> run has 10ms of credit, and the next one on the runqueue has 7ms of
> credit, set the schedule time to 3ms.  This is limited by a "minimum
> schedule time" (currently 500us) and a "maximum schedule time"
> (currently 10ms).  This could probably use some more tweaking, but it
> seem to work pretty well.
> It's not clear to me how to address a lot of the issues you bring up
> without doing a big redesign -- which is what I'm already working on.
> If you're interested in helping test / develop credit2, let me know,
> I'd 
> love some help. :-)
Hi, George
    Sorry for late reply! Glad to see you are addressing these issues in 
Credit2 and I also think sheduler is very performance-critical component in 
Xen, and it should impact the whole system's scalability and performance, 
especailly for large system. And we are also working on solving such issues and 
also glad to work with you and community to make the scheduler better and more 
friendly to large systems.  

Xen-devel mailing list