xen: sched_null: support soft affinity
Get series with b4
b4 am 149874017405.524.14075439009139766753.stgit@SolaceVersions newest first
- v1 Latest5 patches 6 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/5 | xen: sched: factor affinity helpers out of sched_credit.cxen/ xen/ | +79 | 0 replies | |
| 2/5 | xen: sched_null: check for pending tasklet work a bit earlierxen/ | +5 | 1 reply | |
| 3/5 | xen: sched-null: support soft-affinityxen/ | +77 | 1 reply | |
| 4/5 | xen: sched_null: add some tracingxen/ xen/ | +92 | 3 replies | |
| 5/5 | tools: tracing: handle null scheduler's eventstools/ tools/ | +72 | 1 reply |
Reviews trailers per patch
All 5 patches have a Reviewed-by or Acked-by.
| Patch | George Dunlap |
|---|---|
| 1/5 | R-b |
| 2/5 | R-b |
| 3/5 | R-b |
| 4/5 | R-b |
| 5/5 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/5] xen: sched_null: support soft affinity
In the null scheduler, we don't need either hard or soft affinity during online scheduling operations. In fact, the vCPUs are statically assigned to the pCPUs, and hence there's no scope for checking or enforcing any affinity.
We, however, use hard-affinity for 'placement', i.e., for deciding to what pCPU to statically assign a vCPU. Let's, therefore, use soft-affinity too, for the same purpose. Of course, in this case, if there's no free pCPU within the vCPU's soft-affinity, we go checking the hard-affinity, instead of putting the vCPU in the waitqueue.
This is particularly important because, as of now, libxl uses set a domain's soft-affinity, if the automatic NUMA placement logic run at domain creation succeds to find an ideal collocation for the domain, and Xen uses that for allocating the domain's memory.
Supporting soft-affinity like this would therefore mean that, even when using the null scheduler, we try to keep the vCPUs close to their memory (on NUMA hosts, of course).
Note also that this does has no impact on the online scheduling overhead, because soft-affinity is only considered in cold-paths (like when a vCPU joins the scheduler for the first time, or is manually moved between pCPUs by the user).
Note that what is patch 1 in this series, is the same patch 1 of the 'Soft affinity for Credit2' series:
https://lists.xenproject.org/archives/html/xen-devel/2017-06/msg01795.html
https://lists.xenproject.org/archives/html/xen-devel/2017-06/msg01796.html
Regards,
Dario
---
Dario Faggioli (5):
xen: sched: factor affinity helpers out of sched_credit.c
xen: sched_null: check for pending tasklet work a bit earlier
xen: sched-null: support soft-affinity
xen: sched_null: add some tracing
tools: tracing: handle null scheduler's events
tools/xentrace/formats | 7 + tools/xentrace/xenalyze.c | 65 ++++++++++++++ xen/common/sched_credit.c | 97 +++----------------- xen/common/sched_null.c | 209 ++++++++++++++++++++++++++++++++++++-------- xen/include/public/trace.h | 1 xen/include/xen/sched-if.h | 64 +++++++++++++ 6 files changed, 323 insertions(+), 120 deletions(-)
--
<<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)
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel