xen: more scheduler tracing improvement
cover xen: more scheduler tracing improvement
Hi,
this is what remained uncommitted of these other series:
"Scheduling related tracing improvements"
v1: http://lists.xenproject.org/archives/html/xen-devel/2016-02/msg01016.html
v2: http://lists.xenproject.org/archives/html/xen-devel/2016-02/msg02233.html
What is patch 1 here, was there already in v2 of the previous submission, but it did not got reviewed.
What is patch 2 here, was not there before. George suggested doing it, to do better what is done in what is patch 3 here (which was there before, in a slightly different form).
Thanks and Regards,
Dario
---
Dario Faggioli (3):
xenalyze: handle DOM0 operaions events
xen: sched RTDS: use uint64_t for tracing time values
xenalyze: handle RTDS scheduler events
tools/xentrace/xenalyze.c | 78 +++++++++++++++++++++++++++++++++++++++++++++ xen/common/sched_rt.c | 30 ++++++----------- 2 files changed, 89 insertions(+), 19 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]
http://lists.xen.org/xen-devel
PATCH 1/3 xenalyze: handle DOM0 operaions events
(i.e., domain creation and destruction) so the trace will show properly decoded info, rather than just a bunch of hex codes.
---
Cc: George Dunlap <[email protected]>
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>
Cc: Konrad Rzeszutek Wilk <[email protected]>
---
Changes from v1:
* new patch in the series.
--- tools/xentrace/xenalyze.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)
tools/xentrace/xenalyze.c +26 -0
@@ -8388,6 +8388,30 @@ void hw_process(struct pcpu_info *p) } } + +#define TRC_DOM0_SUB_DOMOPS 1 +void dom0_process (struct pcpu_info *p) +{ +struct record_info *ri = &p->ri; + +switch (ri->evt.sub) + { +case TRC_DOM0_SUB_DOMOPS : +if (opt.dump_all) { +struct { +unsigned int domid; + } *r = (typeof (r ))ri->d; + +printf (" %s %s domain d%u\n" , ri->dump_header, + ri->event ==TRC_DOM0_DOM_ADD ?"creating" :"destroying" , + r->domid); + } +break ; +default : +process_generic (&p->ri); + } +} +/* ---- Base ----- */ void dump_generic (FILE * f,struct record_info *ri) {
@@ -9224,6 +9248,8 @@ void process_record(struct pcpu_info *p) {hw_process (p);break ;case TRC_DOM0OP_MAIN : +dom0_process (p); +break ;default :process_generic (ri); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events
Typo in email title "operaions".
Wei.
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events
In reply to Dario FaggioliQuoted 3 lines · Dario Faggioli
(i.e., domain creation and destruction) so the trace will show properly decoded info, rather than just a bunch of hex codes.
Weirdly you also lost your SoB.
Quoted 49 lines
---
Cc: George Dunlap <[email protected]>
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>
Cc: Konrad Rzeszutek Wilk <[email protected]>
---
Changes from v1:
* new patch in the series.--- tools/xentrace/xenalyze.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)tools/xentrace/xenalyze.c +24
-0@@ -8388,6 +8388,30 @@ void hw_process(struct pcpu_info *p) } } + +#define TRC_DOM0_SUB_DOMOPS 1 +void dom0_process (struct pcpu_info *p) +{ +struct record_info *ri = &p->ri; + +switch (ri->evt.sub) + { +case TRC_DOM0_SUB_DOMOPS : +if (opt.dump_all) { +struct { +unsigned int domid; + } *r = (typeof (r ))ri->d; + +printf (" %s %s domain d%u\n" , ri->dump_header, + ri->event ==TRC_DOM0_DOM_ADD ?"creating" :"destroying" , + r->domid); + } +break ; +default : +process_generic (&p->ri); + } +} +/* ---- Base ----- */ void dump_generic (FILE * f,struct record_info *ri) {
tools/xentrace/xenalyze.c void process_record(struct pcpu_info *p) { · line 9255
Quoted 8 lines
tools/xentrace/xenalyze.c +2
-0@@ -9224,6 +9248,8 @@ void process_record(struct pcpu_info *p) {hw_process (p);break ;case TRC_DOM0OP_MAIN : +dom0_process (p); +break ;default :process_generic (ri); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events
Quoted 7 lines · Konrad Rzeszutek Wilk
Quoted 4 lines · Dario Faggioli
(i.e., domain creation and destruction) so the
trace will show properly decoded info, rather
than just a bunch of hex codes.Weirdly you also lost your SoB.
So, typo in subject and no SoB... What a great patch I sent!! :-O
I guess I'll resend. :-)
Sorry and Regards,
Dario
Signature · 4 lines
<<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]
http://lists.xen.org/xen-devel
PATCH v2 1/3 xenalyze: handle DOM0 operations events
In reply to Dario Faggioli(i.e., domain creation and destruction) so the
trace will show properly decoded info, rather
than just a bunch of hex codes.
---
Changes from v2:
* fix typo in subject;
* add missing S-o-b.
Changes from v1:
* new patch in the series.
tools/xentrace/xenalyze.c +0 -0
@@ -8388,6 +8388,30 @@ void hw_process(struct pcpu_info *p)
}
}
+
+#define TRC_DOM0_SUB_DOMOPS 1
+void dom0_process(struct pcpu_info *p)
+{
+ struct record_info *ri = &p->ri;
+
+ switch(ri->evt.sub)
+ {
+ case TRC_DOM0_SUB_DOMOPS:
+ if(opt.dump_all) {
+ struct {
+ unsigned int domid;
+ } *r = (typeof(r))ri->d;
+
+ printf(" %s %s domain d%u\n", ri->dump_header,
+ ri->event == TRC_DOM0_DOM_ADD ? "creating" : "destroying", + r->domid);
+ }
+ break;
+ default:
+ process_generic(&p->ri);
+ }
+}
+
/* ---- Base ----- */
void dump_generic(FILE * f, struct record_info *ri)
{
@@ -9224,6 +9248,8 @@ void process_record(struct pcpu_info *p) { hw_process(p);
break;
case TRC_DOM0OP_MAIN:
+ dom0_process(p);
+ break;
default:
process_generic(ri);
}
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events
In reply to Dario FaggioliQuoted 4 lines · Dario Faggioli
(i.e., domain creation and destruction) so the trace will show properly decoded info, rather than just a bunch of hex codes.
---
For some reason git won't apply your 'v2', complaining: 'corrupt patch at line 14'.
But re the content (i.e., this patch with the SoB and the title fixed)
Sorry it took so long to get to this.
Quoted 48 lines
Cc George Dunlap <[email protected]>Cc Ian Jackson <[email protected]>Cc Wei Liu <[email protected]>Cc Konrad Rzeszutek Wilk <[email protected]>---
Changes from v1:
* new patch in the series.--- tools/xentrace/xenalyze.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)tools/xentrace/xenalyze.c +24
-0@@ -8388,6 +8388,30 @@ void hw_process(struct pcpu_info *p) } } + +#define TRC_DOM0_SUB_DOMOPS 1 +void dom0_process (struct pcpu_info *p) +{ +struct record_info *ri = &p->ri; + +switch (ri->evt.sub) + { +case TRC_DOM0_SUB_DOMOPS : +if (opt.dump_all) { +struct { +unsigned int domid; + } *r = (typeof (r ))ri->d; + +printf (" %s %s domain d%u\n" , ri->dump_header, + ri->event ==TRC_DOM0_DOM_ADD ?"creating" :"destroying" , + r->domid); + } +break ; +default : +process_generic (&p->ri); + } +} +/* ---- Base ----- */ void dump_generic (FILE * f,struct record_info *ri) {
tools/xentrace/xenalyze.c void process_record(struct pcpu_info *p) { · line 9255
Quoted 8 lines
tools/xentrace/xenalyze.c +2
-0@@ -9224,6 +9248,8 @@ void process_record(struct pcpu_info *p) {hw_process (p);break ;case TRC_DOM0OP_MAIN : +dom0_process (p); +break ;default :process_generic (ri); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events
Quoted 8 lines · George Dunlap
Quoted 4 lines · Dario Faggioli
(i.e., domain creation and destruction) so the trace will show properly decoded info, rather than just a bunch of hex codes.
---For some reason git won't apply your 'v2', complaining: 'corrupt patch at line 14'.
/me nods. Same here. I tried to check it in but couldn't.
Dariof could you make a git branch to pull in the Acked patches please?
Quoted 56 lines
But re the content (i.e., this patch with the SoB and the title fixed)
Acked-by George Dunlap <[email protected]>Sorry it took so long to get to this.
Quoted 48 lines
Cc George Dunlap <[email protected]>Cc Ian Jackson <[email protected]>Cc Wei Liu <[email protected]>Cc Konrad Rzeszutek Wilk <[email protected]>---
Changes from v1:
* new patch in the series.--- tools/xentrace/xenalyze.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)tools/xentrace/xenalyze.c +24
-0@@ -8388,6 +8388,30 @@ void hw_process(struct pcpu_info *p) } } + +#define TRC_DOM0_SUB_DOMOPS 1 +void dom0_process (struct pcpu_info *p) +{ +struct record_info *ri = &p->ri; + +switch (ri->evt.sub) + { +case TRC_DOM0_SUB_DOMOPS : +if (opt.dump_all) { +struct { +unsigned int domid; + } *r = (typeof (r ))ri->d; + +printf (" %s %s domain d%u\n" , ri->dump_header, + ri->event ==TRC_DOM0_DOM_ADD ?"creating" :"destroying" , + r->domid); + } +break ; +default : +process_generic (&p->ri); + } +} +/* ---- Base ----- */ void dump_generic (FILE * f,struct record_info *ri) {@@ -9224,6 +9248,8 @@ void process_record(struct pcpu_info *p) {hw_process (p);
Quoted 9 lines
tools/xentrace/xenalyze.c void process_record(struct pcpu_info *p) { · line 9255
Quoted 8 lines
tools/xentrace/xenalyze.c +2
-0break ;case TRC_DOM0OP_MAIN : +dom0_process (p); +break ;default :process_generic (ri); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
git branch for checking-in leftover patches [was: Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events]
Quoted 8 lines · Konrad Rzeszutek Wilk
Quoted 7 lines · George Dunlap
Quoted 5 lines · Dario Faggioli
(i.e., domain creation and destruction) so the
trace will show properly decoded info, rather
than just a bunch of hex codes.
---
Quoted 8 lines
Quoted 3 lines
For some reason git won't apply your 'v2', complaining: 'corrupt patch
at line 14'./me nods. Same here. I tried to check it in but couldn't.
Dariof could you make a git branch to pull in the Acked patches please?
Here it comes:
git://xenbits.xen.org/people/dariof/xen.git tracing/sched-events-improvements-leftover
http://xenbits.xen.org/gitweb/?p=people/dariof/xen.git;a=shortlog;h=refs/heads/tracing/sched-events-improvements-leftover
As far as I can tell, it is these two patches that are still unapplied, and can go in:
xenalyze: handle RTDS scheduler events
xenalyze: handle DOM0 operations events
(the first two commits of the branch, of course.)
Sorry it took a bit, but I lost track of what actually went in and what didn't for this series... :-/
Thanks and Regards,
Dario
Signature · 4 lines
<<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]
http://lists.xen.org/xen-devel
git branch for checking-in leftover patches [was: Re: [PATCH 1/3] xenalyze: handle DOM0 operaions events]
Dario Faggioli writes ("git branch for checking-in leftover patches [was: Re: [Xen-devel] [PATCH 1/3] xenalyze: handle DOM0 operaions events]"):
Quoted 8 lines
git://xenbits.xen.org/people/dariof/xen.gittracing/sched-events-improvements-leftover
http://xenbits.xen.org/gitweb/?p=people/dariof/xen.git;a=shortlog;h=refs/heads/tracing/sched-events-improvements-leftoverAs far as I can tell, it is these two patches that are still unapplied, and can go in:
xenalyze: handle RTDS scheduler events
xenalyze: handle DOM0 operations events
Thanks. I have rebased those onto staging and applied them.
Ian.
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
PATCH 2/3 xen: sched RTDS: use uint64_t for tracing time values
In reply to Dario Faggiolisuch as deadline and budget. Packing is necessary to make it possible for xentrace_format to properly interpreet the records.
---
Cc: George Dunlap <[email protected]>
Cc: Meng Xu <[email protected]>
--- xen/common/sched_rt.c | 30 +++++++++++------------------- 1 file changed, 11 insertions(+), 19 deletions(-)
xen/common/sched_rt.c +11 -19
@@ -361,17 +361,14 @@ rt_update_deadline(s_time_t now, struct rt_vcpu *svc)/* TRACE */ { -struct { +struct __packed {unsigned vcpu:16 , dom:16 ; -unsigned cur_deadline_lo, cur_deadline_hi; -unsigned cur_budget_lo, cur_budget_hi; +uint64_t cur_deadline, cur_budget; } d; d.dom = svc->vcpu->domain->domain_id; d.vcpu = svc->vcpu->vcpu_id; - d.cur_deadline_lo = (unsigned ) svc->cur_deadline; - d.cur_deadline_hi = (unsigned ) (svc->cur_deadline >>32 ); - d.cur_budget_lo = (unsigned ) svc->cur_budget; - d.cur_budget_hi = (unsigned ) (svc->cur_budget >>32 ); + d.cur_deadline = (uint64_t ) svc->cur_deadline; + d.cur_budget = (uint64_t ) svc->cur_budget;trace_var (TRC_RTDS_BUDGET_REPLENISH ,1 ,sizeof (d), (unsigned char *) &d);
@@ -711,16 +708,14 @@ burn_budget(const struct scheduler *ops, struct rt_vcpu *svc, s_time_t now)/* TRACE */ { -struct { +struct __packed {unsigned vcpu:16 , dom:16 ; -unsigned cur_budget_lo; -unsigned cur_budget_hi; +uint64_t cur_budget;int delta; } d; d.dom = svc->vcpu->domain->domain_id; d.vcpu = svc->vcpu->vcpu_id; - d.cur_budget_lo = (unsigned ) svc->cur_budget; - d.cur_budget_hi = (unsigned ) (svc->cur_budget >>32 ); + d.cur_budget = (uint64_t ) svc->cur_budget; d.delta = delta; trace_var(TRC_RTDS_BUDGET_BURN, 1, sizeof(d),
@@ -763,17 +758,14 @@ __runq_pick(const struct scheduler *ops, const cpumask_t *mask) {if ( svc !=NULL ) { -struct { +struct __packed {unsigned vcpu:16 , dom:16 ; -unsigned cur_deadline_lo, cur_deadline_hi; -unsigned cur_budget_lo, cur_budget_hi; +uint64_t cur_deadline, cur_budget; } d; d.dom = svc->vcpu->domain->domain_id; d.vcpu = svc->vcpu->vcpu_id; - d.cur_deadline_lo = (unsigned ) svc->cur_deadline; - d.cur_deadline_hi = (unsigned ) (svc->cur_deadline >>32 ); - d.cur_budget_lo = (unsigned ) svc->cur_budget; - d.cur_budget_hi = (unsigned ) (svc->cur_budget >>32 ); + d.cur_deadline = (uint64_t ) svc->cur_deadline; + d.cur_budget = (uint64_t ) svc->cur_budget;trace_var (TRC_RTDS_RUNQ_PICK ,1 ,sizeof (d), (unsigned char *) &d);
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 2/3] xen: sched RTDS: use uint64_t for tracing time values
Quoted 9 lines · Dario Faggioli
such as deadline and budget. Packing is necessary to make it possible for
xentrace_formatto properly interpreet the records.Signed-off-by Dario Faggioli <[email protected]>---
Cc: George Dunlap <[email protected]>
Cc: Meng Xu <[email protected]>
---
-----------
Meng Xu
PhD Student in Computer and Information Science
University of Pennsylvania
http://www.cis.upenn.edu/~mengxu/
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 2/3] xen: sched RTDS: use uint64_t for tracing time values
In reply to Dario FaggioliQuoted 12 lines
Quoted 1 line
Quoted 1 line · On 12.03.16 at 12:34, <[email protected]> wrote:
xen/common/sched_rt.c +1
-3@@ -361,17 +361,14 @@ rt_update_deadline(s_time_t now, struct rt_vcpu *svc)/* TRACE */ { -struct { +struct __packed {unsigned vcpu:16 , dom:16 ; -unsigned cur_deadline_lo, cur_deadline_hi; -unsigned cur_budget_lo, cur_budget_hi;
xen/common/sched_rt.c rt_update_deadline(s_time_t now, struct rt_vcpu *svc) · line 371
Quoted 10 lines
xen/common/sched_rt.c +3
-4+uint64_t cur_deadline, cur_budget; } d; d.dom = svc->vcpu->domain->domain_id; d.vcpu = svc->vcpu->vcpu_id; - d.cur_deadline_lo = (unsigned ) svc->cur_deadline; - d.cur_deadline_hi = (unsigned ) (svc->cur_deadline >>32 ); - d.cur_budget_lo = (unsigned ) svc->cur_budget; - d.cur_budget_hi = (unsigned ) (svc->cur_budget >>32 ); + d.cur_deadline = (uint64_t ) svc->cur_deadline; + d.cur_budget = (uint64_t ) svc->cur_budget;
I don't see the need for these cast (and similar ones further down), but you're the maintainer, so you know ...
Jan
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 2/3] xen: sched RTDS: use uint64_t for tracing time values
Quoted 17 lines · Jan Beulich
Quoted 17 lines
Quoted 1 line
Quoted 1 line · On 12.03.16 at 12:34, <[email protected]> wrote:
xen/common/sched_rt.c +0
-0@@ -361,17 +361,14 @@ rt_update_deadline(s_time_t now, struct rt_vcpu *svc)
/* TRACE */
{
- struct {
+ struct__packed{
unsigned vcpu:16, dom:16;
- unsignedcur_deadline_lo,cur_deadline_hi; - unsignedcur_budget_lo,cur_budget_hi; + uint64_tcur_deadline,cur_budget; } d;
d.dom =svc->vcpu->domain->domain_id; d.vcpu =svc->vcpu->vcpu_id;
Quoted 9 lines
Quoted 6 lines
- d.cur_deadline_lo = (unsigned)
svc->cur_deadline; - d.cur_deadline_hi = (unsigned) (svc->cur_deadline>> 32); - d.cur_budget_lo = (unsigned)svc->cur_budget; - d.cur_budget_hi = (unsigned) (svc->cur_budget>> 32); + d.cur_deadline = (uint64_t)svc->cur_deadline; + d.cur_budget = (uint64_t)svc->cur_budget;I don't see the need for these cast (and similar ones further down), but you're the maintainer, so you know ...
BTW, I saw you've committed this. Thanks for that, and sorry for not replying. I wanted to, but I've had a couple of day full of Internet connectivity issues.
I do think it's best to keep the casts, although strictly unnecessary.
About this series, I'm re-sending patch 1, by replying directly to that same email of this thread.
So, for other maintainers (which I'm Cc-ing to this message), or should I say, for George :-), this is what should be considered for review:
- [PATCH 1/3 v2] xenalyze: handle DOM0 operations events - [PATCH 3/3] xenalyze: handle RTDS scheduler events
Thanks and Regards,
Dario
Signature · 4 lines
<<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]
http://lists.xen.org/xen-devel
PATCH 3/3 xenalyze: handle RTDS scheduler events
In reply to Dario Faggioliso the trace will show properly decoded info,
rather than just a bunch of hex codes.
---
Cc: George Dunlap <[email protected]>
Cc: Meng Xu <[email protected]>
Cc: Tianyang Chen <[email protected]>
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>
---
Changes from v2:
* use 64 bits ints for time values (now that the scheduler does that too), as suggested during review.
Changes from v1:
* '} * r =' turned into '} *r =', as requested
during review.
--- tools/xentrace/xenalyze.c | 52 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+)
tools/xentrace/xenalyze.c +52 -0
@@ -7823,6 +7823,58 @@ void sched_process(struct pcpu_info *p) r->rq_avgload, r->b_avgload); }break ; +/* RTDS (TRC_RTDS_xxx) */ +case TRC_SCHED_CLASS_EVT (RTDS ,1 ):/* TICKLE */ +if (opt.dump_all) { +struct { +unsigned int cpu:16 ; + } *r = (typeof (r ))ri->d; + +printf (" %s rtds:runq_tickle cpu %u\n" , + ri->dump_header, r->cpu); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,2 ):/* RUNQ_PICK */ +if (opt.dump_all) { +struct { +unsigned int vcpuid:16 , domid:16 ; +uint64_t cur_dl, cur_bg; + } __attribute__((packed)) *r = (typeof (r ))ri->d; + +printf (" %s rtds:runq_pick d%uv%u, deadline = %" PRIu64", " +"budget = %" PRIu64"\n" , ri->dump_header, + r->domid, r->vcpuid, r->cur_dl, r->cur_bg); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,3 ):/* BUDGET_BURN */ +if (opt.dump_all) { +struct { +unsigned int vcpuid:16 , domid:16 ; +uint64_t cur_bg; +int delta; + } __attribute__((packed)) *r = (typeof (r ))ri->d; + +printf (" %s rtds:burn_budget d%uv%u, budget = %" PRIu64", " +"delta = %d\n" , ri->dump_header, r->domid, + r->vcpuid, r->cur_bg, r->delta); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,4 ):/* BUDGET_REPLENISH */ +if (opt.dump_all) { +struct { +unsigned int vcpuid:16 , domid:16 ; +uint64_t cur_dl, cur_bg; + } __attribute__((packed)) *r = (typeof (r ))ri->d; + +printf (" %s rtds:repl_budget d%uv%u, deadline = %" PRIu64", " +"budget = %" PRIu64"\n" , ri->dump_header, + r->domid, r->vcpuid, r->cur_dl, r->cur_bg); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,5 ):/* SCHED_TASKLET */ +if (opt.dump_all) +printf (" %s rtds:sched_tasklet\n" , ri->dump_header); +break ;default :process_generic (ri); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 3/3] xenalyze: handle RTDS scheduler events
Quoted 16 lines · Dario Faggioli
so the trace will show properly decoded info,
rather than just a bunch of hex codes.Signed-off-by Dario Faggioli <[email protected]>Reviewed-by Konrad Rzeszutek Wilk <[email protected]>---
Cc: George Dunlap <[email protected]>
Cc: Meng Xu <[email protected]>
Cc: Tianyang Chen <[email protected]>
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>
---
Changes from v2:
* use 64 bits ints for time values (now that the scheduler does that too), as suggested during review.
Quoted 4 lines
Changes from v1:
* '} * r =' turned into '} *r =', as requested
during review.
---
Thanks,
-----------
Meng Xu
PhD Student in Computer and Information Science
University of Pennsylvania
http://www.cis.upenn.edu/~mengxu/
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Re: [PATCH 3/3] xenalyze: handle RTDS scheduler events
In reply to Dario FaggioliQuoted 5 lines · Dario Faggioli
so the trace will show properly decoded info,
rather than just a bunch of hex codes.Signed-off-by Dario Faggioli <[email protected]>Reviewed-by Konrad Rzeszutek Wilk <[email protected]>
Quoted 72 lines
---
Cc: George Dunlap <[email protected]>
Cc: Meng Xu <[email protected]>
Cc: Tianyang Chen <[email protected]>
Cc: Ian Jackson <[email protected]>
Cc: Wei Liu <[email protected]>
---
Changes from v2:
* use 64 bits ints for time values (now that the scheduler does that too), as suggested during review.Changes from v1:
* '} * r =' turned into '} *r =', as requested
during review.--- tools/xentrace/xenalyze.c | 52 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+)tools/xentrace/xenalyze.c +45
-0@@ -7823,6 +7823,58 @@ void sched_process(struct pcpu_info *p) r->rq_avgload, r->b_avgload); }break ; +/* RTDS (TRC_RTDS_xxx) */ +case TRC_SCHED_CLASS_EVT (RTDS ,1 ):/* TICKLE */ +if (opt.dump_all) { +struct { +unsigned int cpu:16 ; + } *r = (typeof (r ))ri->d; + +printf (" %s rtds:runq_tickle cpu %u\n" , + ri->dump_header, r->cpu); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,2 ):/* RUNQ_PICK */ +if (opt.dump_all) { +struct { +unsigned int vcpuid:16 , domid:16 ; +uint64_t cur_dl, cur_bg; + } __attribute__((packed)) *r = (typeof (r ))ri->d; + +printf (" %s rtds:runq_pick d%uv%u, deadline = %" PRIu64", " +"budget = %" PRIu64"\n" , ri->dump_header, + r->domid, r->vcpuid, r->cur_dl, r->cur_bg); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,3 ):/* BUDGET_BURN */ +if (opt.dump_all) { +struct { +unsigned int vcpuid:16 , domid:16 ; +uint64_t cur_bg; +int delta; + } __attribute__((packed)) *r = (typeof (r ))ri->d; + +printf (" %s rtds:burn_budget d%uv%u, budget = %" PRIu64", " +"delta = %d\n" , ri->dump_header, r->domid, + r->vcpuid, r->cur_bg, r->delta); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,4 ):/* BUDGET_REPLENISH */ +if (opt.dump_all) { +struct { +unsigned int vcpuid:16 , domid:16 ; +uint64_t cur_dl, cur_bg; + } __attribute__((packed)) *r = (typeof (r ))ri->d; + + printf(" %s rtds:repl_budget d%uv%u, deadline = %"PRIu64", " + "budget = %"PRIu64"\n", ri->dump_header,
tools/xentrace/xenalyze.c void sched_process(struct pcpu_info *p) · line 7880
Quoted 10 lines
tools/xentrace/xenalyze.c +7
-0+ r->domid, r->vcpuid, r->cur_dl, r->cur_bg); + } +break ; +case TRC_SCHED_CLASS_EVT (RTDS ,5 ):/* SCHED_TASKLET */ +if (opt.dump_all) +printf (" %s rtds:sched_tasklet\n" , ri->dump_header); +break ;default :process_generic (ri); }
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel