From: Chong Li <lichong659@gmail.com>
To: xen-devel@lists.xen.org
Cc: wei.liu2@citrix.com, george.dunlap@eu.citrix.com,
dario.faggioli@citrix.com, ian.jackson@eu.citrix.com,
ian.campbell@eu.citrix.com, mengxu@cis.upenn.edu,
jbeulich@suse.com, lichong659@gmail.com, dgolomb@seas.upenn.edu
Subject: [PATCH v6 for Xen 4.7 0/4] Enable per-VCPU parameter settings for RTDS scheduler
Date: Sun, 6 Mar 2016 11:55:54 -0600 [thread overview]
Message-ID: <1457286958-5427-1-git-send-email-lichong659@gmail.com> (raw)
[Goal]
The current xl sched-rtds tool can only set the VCPUs of a domain
to the same parameter although the scheduler supports VCPUs with
different parameters. This patchset is to enable xl sched-rtds
tool to configure the VCPUs of a domain with different parameters.
This per-VCPU settings can be used in many scenarios. For example,
based on Dario's statement in our pervious discussion
(http://lists.xen.org/archives/html/xen-devel/2014-09/msg00423.html),
if there are two real-time applications, which have different timing
requirements, running in a multi-VCPU guest domain, it is beneficial
to pin these two applications to two seperate VCPUs with different
scheduling parameters.
What this patchset includes is a wanted and planned feature for RTDS
scheudler(http://wiki.xenproject.org/wiki/RTDS-Based-Scheduler) in
Xen 4.7. The interface design of the xl sched-rtds tool is based on
Meng's previous discussion with Dario, George and Wei
(http://lists.xen.org/archives/html/xen-devel/2015-02/msg02606.html).
Basically, there are two main changes:
1) in xl, we create an array that records all VCPUs whose parameters
are about to modify or output.
2) in libxl, we receive the array and call different xc functions to
handle it.
3) in xen and libxc, we use
XEN_DOMCTL_SCHEDOP_getvcpuinfo/putvcpuinfo(introduced by this
patchset) as the hypercall for per-VCPU operations(get/set method).
[Usage]
With this patchset in use, xl sched-rtds tool can:
1) show the budget and period of each VCPU of each domain,
by using "xl sched-rtds -v all" command. An example would be like:
# xl sched-rtds -v all
Cpupool Pool-0: sched=RTDS
Name ID VCPU Period Budget
Domain-0 0 0 10000 4000
vm1 1 0 300 150
vm1 1 1 400 200
vm1 1 2 10000 4000
vm1 1 3 1000 500
vm2 2 0 10000 4000
vm2 2 1 10000 4000
Using "xl sched-rtds" will output the default scheduling parameters
for each domain. An example would be like:
# xl sched-rtds
Cpupool Pool-0: sched=RTDS
Name ID Period Budget
Domain-0 0 10000 4000
vm1 1 10000 4000
vm2 2 10000 4000
2) show the budget and period of each VCPU of a specific domain,
by using, e.g., "xl sched-rtds -d vm1 -v all" command. The output
would be like:
# xl sched-rtds -d vm1 -v all
Name ID VCPU Period Budget
vm1 1 0 300 150
vm1 1 1 400 200
vm1 1 2 10000 4000
vm1 1 3 1000 500
To show a subset of the parameters of the VCPUs of a specific domain,
please use, e.g.,"xl sched-rtds -d vm1 -v 0 -v 3" command.
The output would be:
# xl sched-rtds -d vm1 -v 0 -v 3
Name ID VCPU Period Budget
vm1 1 0 300 150
vm1 1 3 1000 500
Using command, e.g., "xl sched-rtds -d vm1" will output the default
scheduling parameters of vm1. An example would be like:
# xl sched-rtds -d vm1
Name ID Period Budget
vm1 1 10000 4000
3) Users can set the budget and period of multiple VCPUs of a
specific domain with only one command,
e.g., "xl sched-rtds -d vm1 -v 0 -p 100 -b 50 -v 3 -p 300 -b 150".
Users can set all VCPUs with the same parameters, by one command.
e.g., "xl sched-rtds -d vm1 -v all -p 500 -b 250".
---
Previous conclusion:
On PATCH v4, our concern was about the usage of hypercall_preemption_check
and the print of warning message (both in xen). These issues are addressed
in this patch.
CC: <dario.faggioli@citrix.com>
CC: <george.dunlap@eu.citrix.com>
CC: <dgolomb@seas.upenn.edu>
CC: <mengxu@cis.upenn.edu>
CC: <jbeulich@suse.com>
CC: <wei.liu2@citrix.com>
CC: <lichong659@gmail.com>
CC: <ian.jackson@eu.citrix.com>
CC: <ian.campbell@eu.citrix.com>
Chong Li (4):
xen: enable per-VCPU parameter settings for RTDS scheduler
libxc: enable per-VCPU parameter settings for RTDS scheduler
libxl: enable per-VCPU parameter settings for RTDS scheduler
xl: enable per-VCPU parameter settings for RTDS scheduler
docs/man/xl.pod.1 | 4 +
tools/libxc/include/xenctrl.h | 16 ++-
tools/libxc/xc_rt.c | 68 +++++++++
tools/libxl/libxl.c | 326 +++++++++++++++++++++++++++++++++++++++---
tools/libxl/libxl.h | 37 +++++
tools/libxl/libxl_types.idl | 14 ++
tools/libxl/xl_cmdimpl.c | 292 ++++++++++++++++++++++++++++++++-----
tools/libxl/xl_cmdtable.c | 10 +-
xen/common/sched_credit.c | 4 +
xen/common/sched_credit2.c | 4 +
xen/common/sched_rt.c | 130 +++++++++++++++--
xen/common/schedule.c | 15 +-
xen/include/public/domctl.h | 59 ++++++--
13 files changed, 885 insertions(+), 94 deletions(-)
--
1.9.1
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel
next reply other threads:[~2016-03-06 17:55 UTC|newest]
Thread overview: 51+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-06 17:55 Chong Li [this message]
2016-03-06 17:55 ` [PATCH v6 for Xen 4.7 1/4] xen: enable per-VCPU parameter settings for RTDS scheduler Chong Li
2016-03-07 12:59 ` Jan Beulich
2016-03-07 16:28 ` Chong Li
2016-03-07 16:40 ` Jan Beulich
2016-03-07 17:53 ` Dario Faggioli
2016-03-07 22:16 ` Chong Li
2016-03-08 9:10 ` Jan Beulich
2016-03-08 10:34 ` Dario Faggioli
2016-03-08 11:47 ` Jan Beulich
2016-03-08 19:09 ` Wei Liu
2016-03-09 16:10 ` Dario Faggioli
2016-03-09 16:38 ` Jan Beulich
2016-03-13 17:05 ` Chong Li
2016-03-14 8:37 ` Jan Beulich
2016-03-14 9:10 ` Dario Faggioli
2016-03-14 9:15 ` Jan Beulich
2016-03-14 10:05 ` Dario Faggioli
2016-03-15 16:22 ` Chong Li
2016-03-15 16:41 ` Dario Faggioli
2016-03-15 17:22 ` Chong Li
2016-03-16 3:14 ` Meng Xu
2016-03-16 3:32 ` Chong Li
2016-03-16 3:43 ` Meng Xu
2016-03-16 8:23 ` Dario Faggioli
2016-03-16 14:37 ` Meng Xu
2016-03-16 14:46 ` Chong Li
2016-03-16 14:53 ` Dario Faggioli
2016-03-16 14:46 ` Chong Li
2016-03-16 14:54 ` Dario Faggioli
2016-03-16 10:48 ` Jan Beulich
2016-03-10 22:35 ` Chong Li
2016-03-10 22:50 ` Wei Liu
2016-03-14 9:07 ` Dario Faggioli
2016-03-06 17:55 ` [PATCH v6 for Xen 4.7 2/4] libxc: " Chong Li
2016-03-08 19:09 ` Wei Liu
2016-03-08 19:32 ` Chong Li
2016-03-08 19:36 ` Wei Liu
2016-03-06 17:55 ` [PATCH v6 for Xen 4.7 3/4] libxl: " Chong Li
2016-03-08 19:12 ` Wei Liu
2016-03-09 0:38 ` Chong Li
2016-03-09 14:01 ` Wei Liu
2016-03-09 17:28 ` Dario Faggioli
2016-03-09 21:57 ` Chong Li
2016-03-09 17:09 ` Dario Faggioli
2016-03-09 17:28 ` Dario Faggioli
2016-03-06 17:55 ` [PATCH v6 for Xen 4.7 4/4] xl: " Chong Li
2016-03-08 19:12 ` Wei Liu
2016-03-08 21:24 ` Chong Li
2016-03-09 14:01 ` Wei Liu
2016-03-09 14:09 ` Wei Liu
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=1457286958-5427-1-git-send-email-lichong659@gmail.com \
--to=lichong659@gmail.com \
--cc=dario.faggioli@citrix.com \
--cc=dgolomb@seas.upenn.edu \
--cc=george.dunlap@eu.citrix.com \
--cc=ian.campbell@eu.citrix.com \
--cc=ian.jackson@eu.citrix.com \
--cc=jbeulich@suse.com \
--cc=mengxu@cis.upenn.edu \
--cc=wei.liu2@citrix.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).