From: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
To: Lei Wen <leiwen@marvell.com>
Cc: Paul Turner <pjt@google.com>, Alex Shi <alex.shi@intel.com>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@elte.hu>,
mingo@redhat.com, linux-kernel@vger.kernel.org,
kamalesh@linux.vnet.ibm.com
Subject: Re: [PATCH 1/2] sched: add trace events for task and rq usage tracking
Date: Mon, 1 Jul 2013 15:13:11 +0530 [thread overview]
Message-ID: <20130701094311.GA32363@linux.vnet.ibm.com> (raw)
In-Reply-To: <1372662634-12833-2-git-send-email-leiwen@marvell.com>
* Lei Wen <leiwen@marvell.com> [2013-07-01 15:10:32]:
> Since we could track task in the entity level now, we may want to
> investigate tasks' running status by recording the trace info, so that
> could make some tuning if needed.
>
> Signed-off-by: Lei Wen <leiwen@marvell.com>
> ---
> include/trace/events/sched.h | 73 ++++++++++++++++++++++++++++++++++++++++++
> kernel/sched/fair.c | 29 +++++++++++++++--
> 2 files changed, 100 insertions(+), 2 deletions(-)
[...]
>
> +TRACE_EVENT(sched_cfs_rq_runnable_load,
> +
> + TP_PROTO(int cpu, unsigned long load, unsigned long total),
> +
> + TP_ARGS(cpu, load, total),
> +
> + TP_STRUCT__entry(
> + __field(int, cpu)
> + __field(unsigned long, load)
> + __field(unsigned long, total)
> + ),
> +
> + TP_fast_assign(
> + __entry->cpu = cpu;
> + __entry->load = load;
> + __entry->total = total;
> + ),
> +
> + TP_printk("cpu=%d avg=%lu total=%lu",
> + __entry->cpu,
> + __entry->load,
> + __entry->total)
> +);
> +
> +TRACE_EVENT(sched_cfs_rq_blocked_load,
> +
> + TP_PROTO(int cpu, unsigned long load, unsigned long total),
> +
> + TP_ARGS(cpu, load, total),
> +
> + TP_STRUCT__entry(
> + __field(int, cpu)
> + __field(unsigned long, load)
> + __field(unsigned long, total)
> + ),
> +
> + TP_fast_assign(
> + __entry->cpu = cpu;
> + __entry->load = load;
> + __entry->total = total;
> + ),
> +
> + TP_printk("cpu=%d avg=%lu total=%lu",
> + __entry->cpu,
> + __entry->load,
> + __entry->total)
> +);
> +
> #endif /* _TRACE_SCHED_H */
above trace points are same and be folded using EVENT_CLASS:
+DECLARE_EVENT_CLASS(sched_cfs_rq_load_contri_template,
+
+ TP_PROTO(int cpu, unsigned long load, unsigned long total),
+
+ TP_ARGS(cpu, load, total),
+
+ TP_STRUCT__entry(
+ __field(int, cpu)
+ __field(unsigned long, load)
+ __field(unsigned long, total)
+ ),
+
+ TP_fast_assign(
+ __entry->cpu = cpu;
+ __entry->load = load;
+ __entry->total = total;
+ ),
+
+ TP_printk("cpu=%d avg=%lu total=%lu",
+ __entry->cpu,
+ __entry->load,
+ __entry->total)
+);
+
+DEFINE_EVENT(sched_cfs_rq_load_contri_template, sched_cfs_rq_runnable_load,
+ TP_PROTO(int cpu, unsigned long load, unsigned long total),
+ TP_ARGS(cpu, load, total));
+
+DEFINE_EVENT(sched_cfs_rq_load_contri_template, sched_cfs_rq_blocked_load,
+ TP_PROTO(int cpu, unsigned long load, unsigned long total),
+ TP_ARGS(cpu, load, total));
+
next prev parent reply other threads:[~2013-07-01 9:43 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-01 7:10 [PATCH 0/2] sched: add trace event for per-entity tracking Lei Wen
2013-07-01 7:10 ` [PATCH 1/2] sched: add trace events for task and rq usage tracking Lei Wen
2013-07-01 9:43 ` Kamalesh Babulal [this message]
2013-07-01 12:18 ` Lei Wen
2013-07-01 7:10 ` [PATCH 2/2] sched: update cfs_rq weight earlier in enqueue_entity Lei Wen
2013-07-01 8:06 ` [PATCH 0/2] sched: add trace event for per-entity tracking Alex Shi
2013-07-01 8:49 ` Lei Wen
2013-07-01 12:33 ` [PATCH V2 " Lei Wen
2013-07-01 12:33 ` [V2 1/2] sched: add trace events for task and rq usage tracking Lei Wen
2013-07-01 12:44 ` Peter Zijlstra
2013-07-01 13:25 ` Lei Wen
2013-07-01 12:33 ` [V2 2/2] sched: update cfs_rq weight earlier in enqueue_entity Lei Wen
2013-07-01 14:07 ` Paul Turner
2013-07-02 2:52 ` Lei Wen
2013-07-02 12:15 ` [PATCH V3 0/2] sched: add trace event for per-entity tracking Lei Wen
2013-07-02 12:15 ` [V3 1/2] sched: add trace events for task and rq usage tracking Lei Wen
2013-07-03 12:46 ` Lei Wen
2013-07-02 12:15 ` [V3 2/2] sched: update cfs_rq weight earlier in enqueue_entity Lei Wen
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=20130701094311.GA32363@linux.vnet.ibm.com \
--to=kamalesh@linux.vnet.ibm.com \
--cc=alex.shi@intel.com \
--cc=leiwen@marvell.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=pjt@google.com \
/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