Re: [Xen-devel] [PATCH 3/3] xenalyze: handle RTDS scheduler events
On 12/03/16 11:34, Dario Faggioli wrote: > so the trace will show properly decoded info, > rather than just a bunch of hex codes. > > Signed-off-by: Dario Faggioli > Reviewed-by: Konrad Rzeszutek Wilk Acked-by: George Dunlap > --- > Cc: George Dunlap > Cc: Meng Xu > Cc: Tianyang Chen > Cc: Ian Jackson > Cc: Wei Liu > --- > 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(+) > > diff --git a/tools/xentrace/xenalyze.c b/tools/xentrace/xenalyze.c > index 353bed7..b949986 100644 > --- a/tools/xentrace/xenalyze.c > +++ b/tools/xentrace/xenalyze.c > @@ -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 Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Re: [Xen-devel] [PATCH 3/3] xenalyze: handle RTDS scheduler events
On Sat, Mar 12, 2016 at 6:34 AM, Dario Faggioli wrote: > so the trace will show properly decoded info, > rather than just a bunch of hex codes. > > Signed-off-by: Dario Faggioli > Reviewed-by: Konrad Rzeszutek Wilk > --- > Cc: George Dunlap > Cc: Meng Xu > Cc: Tianyang Chen > Cc: Ian Jackson > Cc: Wei Liu > --- > 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. > --- Reviewed-by: Meng Xu Thanks, --- Meng Xu PhD Student in Computer and Information Science University of Pennsylvania http://www.cis.upenn.edu/~mengxu/ ___ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
[Xen-devel] [PATCH 3/3] xenalyze: handle RTDS scheduler events
so the trace will show properly decoded info, rather than just a bunch of hex codes. Signed-off-by: Dario Faggioli Reviewed-by: Konrad Rzeszutek Wilk --- Cc: George Dunlap Cc: Meng Xu Cc: Tianyang Chen Cc: Ian Jackson Cc: Wei Liu --- 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(+) diff --git a/tools/xentrace/xenalyze.c b/tools/xentrace/xenalyze.c index 353bed7..b949986 100644 --- a/tools/xentrace/xenalyze.c +++ b/tools/xentrace/xenalyze.c @@ -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 Xen-devel@lists.xen.org http://lists.xen.org/xen-devel