From: Changbin Du <changbin.du@gmail.com>
To: rostedt@goodmis.org
Cc: mingo@redhat.com, corbet@lwn.net, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org, Changbin Du <changbin.du@gmail.com>
Subject: [PATCH 0/5] Improve the latency tracers
Date: Tue, 1 Jan 2019 23:46:09 +0800 [thread overview]
Message-ID: <20190101154614.8887-1-changbin.du@gmail.com> (raw)
Happy new year!
This series make some improments for the kernel latency tracers, especilly
for the wakeup tracers. The latency tracers will show us more useful
information. With this series, the wakeup tracers look like this
when display-graph is enabled:
# tracer: wakeup
#
# wakeup latency trace v1.1.5 on 4.20.0+
# --------------------------------------------------------------------
# latency: 593 us, #674/674, CPU#0 | (M:desktop VP:0, KP:0, SP:0 HP:0 #P:4)
# -----------------
# | task: kworker/0:1H-339 (uid:0 nice:-20 policy:0 rt_prio:0)
# -----------------
#
# _-----=> irqs-off
# / _----=> need-resched
# | / _---=> hardirq/softirq
# || / _--=> preempt-depth
# ||| /
# REL TIME CPU TASK/PID |||| DURATION FUNCTION CALLS
# | | | | |||| | | | | | |
0 us | 0) <idle>-0 | dNs. | | /* 0:120:R + [000] 339:100:R kworker/0:1H */
3 us | 0) <idle>-0 | dNs. | 0.000 us | (null)();
<idle>-0 0dNs. 66us : <stack trace>
=> try_to_wake_up
=> __queue_work
=> queue_work_on
=> call_timer_fn
=> run_timer_softirq
=> __do_softirq
=> irq_exit
=> smp_apic_timer_interrupt
=> apic_timer_interrupt
=> native_safe_halt
=> default_idle
=> default_idle_call
=> do_idle
=> cpu_startup_entry
=> start_kernel
=> secondary_startup_64
67 us | 0) <idle>-0 | dNs. | 0.721 us | ttwu_stat();
69 us | 0) <idle>-0 | dNs. | 0.607 us | _raw_spin_unlock_irqrestore();
71 us | 0) <idle>-0 | .Ns. | 0.598 us | _raw_spin_lock_irq();
72 us | 0) <idle>-0 | .Ns. | 0.584 us | _raw_spin_lock_irq();
73 us | 0) <idle>-0 | dNs. | 1.125 us | __next_timer_interrupt();
75 us | 0) <idle>-0 | dNs. | | call_timer_fn() {
76 us | 0) <idle>-0 | dNs. | | delayed_work_timer_fn() {
[...]
564 us | 0) kworker-13 | d... | | set_next_entity() {
565 us | 0) kworker-13 | d... | 0.524 us | __update_load_avg_se();
566 us | 0) kworker-13 | d... | 0.562 us | __update_load_avg_cfs_rq();
567 us | 0) kworker-13 | d... | 2.765 us | }
568 us | 0) kworker-13 | d... | + 10.077 us | }
569 us | 0) kworker-13 | d... | 0.000 us | __schedule();
kworker/-13 0d... 593us : <stack trace>
=> schedule
=> worker_thread
=> kthread
=> ret_from_fork
593 us | 0) kworker-13 | d... | | /* 13:120:I ==> [000] 339:100:R kworker/0:1H */
Changbin Du (5):
function_graph: Support displaying relative timestamp
sched/tracing: Show more info for funcgraph wakeup tracers
sched/tracing: Put a margin between flags and duration for wakeup
tracers
sched/tracing: Show stacktrace for wakeup tracers
trace/doc: Add latency tracer funcgraph example
Documentation/trace/ftrace.rst | 51 ++++++++++++++++++++++++++++
kernel/trace/trace.h | 9 ++---
kernel/trace/trace_functions_graph.c | 30 ++++++++++++++--
kernel/trace/trace_irqsoff.c | 2 +-
kernel/trace/trace_sched_wakeup.c | 11 ++++--
5 files changed, 94 insertions(+), 9 deletions(-)
--
2.17.1
next reply other threads:[~2019-01-01 15:47 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-01 15:46 Changbin Du [this message]
2019-01-01 15:46 ` [PATCH 1/5] function_graph: Support displaying relative timestamp Changbin Du
2019-01-01 15:46 ` [PATCH 2/5] sched/tracing: Show more info for funcgraph wakeup tracers Changbin Du
2019-01-01 15:46 ` [PATCH 3/5] sched/tracing: Put a margin between flags and duration for " Changbin Du
2019-01-01 15:46 ` [PATCH 4/5] sched/tracing: Show stacktrace " Changbin Du
2019-01-16 3:25 ` Steven Rostedt
2019-01-16 16:04 ` Changbin Du
2019-01-01 15:46 ` [PATCH 5/5] trace/doc: Add latency tracer funcgraph example Changbin Du
2019-01-12 4:05 ` [PATCH 0/5] Improve the latency tracers Changbin Du
2019-01-14 15:00 ` Steven Rostedt
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=20190101154614.8887-1-changbin.du@gmail.com \
--to=changbin.du@gmail.com \
--cc=corbet@lwn.net \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rostedt@goodmis.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).