xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Dario Faggioli <dario.faggioli@citrix.com>
To: Amin Fallahi <amin.fallahi@gmail.com>,
	"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Subject: Re: How to find out how much cpu time each domain used?
Date: Wed, 13 Jul 2016 10:07:44 +0200	[thread overview]
Message-ID: <1468397264.13039.13.camel@citrix.com> (raw)
In-Reply-To: <CAF-KA8-YRtCGBeBAw17OK_m-zTSO2zDem4cmvS6LdKnJTmBsyA@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 1569 bytes --]

On Mon, 2016-07-04 at 20:09 +0000, Amin Fallahi wrote:
> Dear all
> 
> I am modifying credit scheduler and I want to give credit to each
> vcpu based on cpu time which its domain has consumed.
> Suppose:
> credit_fair =((credit_total*sdom->weight)+(weight_total-
> 1))/weight_total
> 
Mind describing what your actual end goal is, and spending a little
more word describing how you were thinking to achieve it?

I see the formula, but I don't understand:
 - what is it that you are trying to improve/achieve? Better fairness, 
   I guess?
 - how do you plan to use such formula, i.e., where in the algorithm 
   you'd put it? Credits are already been burned basing on how much a 
   vcpu executes, is this about how much credits a vcpu is given at 
   the beginning/reset? How would it integrate with credits_per_tslice 
   and friends?

> I want to multiply something to this formula according to the domain
> cpu usage. Thus I need to somehow find out cpu time for each domain.
>
Cpu usage in terms of what? Time? Percentage? Over what time interval?

It is certainly possible to figure out how long a vcpu executed on a
pcpu on a given time interval, but depending from the characteristics
of such time interval, the way to actually do that varies.

Dario
-- 
<<This happens because I choose it to happen!>> (Raistlin Majere)
-----------------------------------------------------------------
Dario Faggioli, Ph.D, http://about.me/dario.faggioli
Senior Software Engineer, Citrix Systems R&D Ltd., Cambridge (UK)


[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

[-- Attachment #2: Type: text/plain, Size: 127 bytes --]

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

      reply	other threads:[~2016-07-13  8:07 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-04 20:09 How to find out how much cpu time each domain used? Amin Fallahi
2016-07-13  8:07 ` Dario Faggioli [this message]

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=1468397264.13039.13.camel@citrix.com \
    --to=dario.faggioli@citrix.com \
    --cc=amin.fallahi@gmail.com \
    --cc=xen-devel@lists.xen.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).