xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Anshul Makkar <anshul.makkar@citrix.com>
To: Dario Faggioli <dario.faggioli@citrix.com>,
	xen-devel@lists.xenproject.org
Cc: George Dunlap <george.dunlap@eu.citrix.com>,
	Andrew Cooper <andrew.cooper3@citrix.com>,
	Wei Liu <wei.liu2@citrix.com>,
	Ian Jackson <ian.jackson@eu.citrix.com>,
	Jan Beulich <jbeulich@suse.com>
Subject: Re: [PATCH 1/4] xen: credit2: implement utilization cap
Date: Thu, 15 Jun 2017 17:16:26 +0100	[thread overview]
Message-ID: <6ccdc293-26f6-efc9-817b-a5268f58200a@citrix.com> (raw)
In-Reply-To: <1497388423.26212.43.camel@citrix.com>

On 13/06/2017 22:13, Dario Faggioli wrote:
> On Tue, 2017-06-13 at 17:07 +0100, Anshul Makkar wrote:
>> On 12/06/2017 14:19, Dario Faggioli wrote:
>>>>> @@ -92,6 +92,82 @@
>>>>>   */
>>
>> what I want to ask is that if the budget of the domain is
>> replenished,
>> but credit for the vcpus of that domain is not available, then what
>> happens.
>>
> Yes, but the point is that budget can be available or not, while
> credits are always available. There's no such thing as credit not being
> available at all.
>
> The amount of credits each vcpu has decides which vcpu will run, in the
> sense that it will be the one that has the highest amount of credits.
> The others will indeed wait, but because they've got less credit than
> the one that runs, not because they don't have credits available.
>
Ok, as discussed, credits are resetted if it reaches 0. In that sense 
its being considered "always available"..

>> I believe, vcpus won't be scheduled (even if they have budget_quota)
>> till they get their credit replenished.
>>
> Credits are not exhausted or replenished.
>>>
>>> But... it's already totally dynamic.
>>
>> csched2_dom_cntl()
>> {
>> svc->budget_quota = max(sdom->tot_budget / sdom->nr_vcpus,
>>                                          CSCHED2_MIN_TIMER);
>> }
>> If domain->tot_budge = 200
>> nr_cpus is 4, then each cpu gets 50%.
>> How this is dynamic allocation ? We are not considering vcpu
>> utilization
>> of other vcpus of domain before allocating budget_quota for some
>> vcpu.
>>
> Right. Well, what this means is that each vcpu will get budget in
> chunks of tot_budget/nr_vcpus. But then, how much budget each vcpu will
> actually be able to get and consume in each period, it's impossible to
> know in advance, as it will depend on overall system load, and the
> behavior of the various vcpus of the domain.
Yeah, the current implementation is dynamic in the sense that vcpu can 
execute in total more than its quota across multiple budget cycles, but 
its static in the sense that vcpu can't execute more than its budget 
quota in a single budget cycle.s
>
>>>> In runq candidate we have a code base
>
> Regards,
> Dario
>
Reviewed-by: Anshul Makkar<anshul.makkar@citrix.com>
Anshul


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2017-06-15 16:16 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-08 12:08 [PATCH 0/4] xen/tools: Credit2: implement caps Dario Faggioli
2017-06-08 12:08 ` [PATCH 1/4] xen: credit2: implement utilization cap Dario Faggioli
2017-06-12 11:16   ` Anshul Makkar
2017-06-12 13:19     ` Dario Faggioli
2017-06-13 16:07       ` Anshul Makkar
2017-06-13 21:13         ` Dario Faggioli
2017-06-15 16:16           ` Anshul Makkar [this message]
2017-06-22 16:55   ` George Dunlap
2017-06-23 16:19     ` Dario Faggioli
2017-06-28 14:28       ` George Dunlap
2017-06-28 14:56         ` Dario Faggioli
2017-06-28 19:05           ` George Dunlap
2017-06-29 10:09             ` Dario Faggioli
2017-07-25 14:34               ` George Dunlap
2017-07-25 17:29                 ` Dario Faggioli
2017-07-25 15:08   ` George Dunlap
2017-07-25 16:05     ` Dario Faggioli
2017-06-08 12:08 ` [PATCH 2/4] xen: credit2: allow to set and get " Dario Faggioli
2017-06-28 15:19   ` George Dunlap
2017-06-29 10:21     ` Dario Faggioli
2017-06-29  7:39   ` Alan Robinson
2017-06-29  8:26     ` George Dunlap
2017-06-08 12:09 ` [PATCH 3/4] xen: credit2: improve distribution of budget (for domains with caps) Dario Faggioli
2017-06-28 16:02   ` George Dunlap
2017-06-08 12:09 ` [PATCH 4/4] libxl/xl: allow to get and set cap on Credit2 Dario Faggioli
2017-06-09 10:41   ` Wei Liu
2017-06-28 18:43   ` George Dunlap
2017-06-29 10:22     ` Dario Faggioli

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=6ccdc293-26f6-efc9-817b-a5268f58200a@citrix.com \
    --to=anshul.makkar@citrix.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=dario.faggioli@citrix.com \
    --cc=george.dunlap@eu.citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=jbeulich@suse.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /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;
as well as URLs for NNTP newsgroup(s).