summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
AgeCommit message (Expand)Author
2018-11-05perf scripts python: exported-sql-viewer.py: Fall back to /usr/local/lib/libx...Adrian Hunter
2018-10-23perf scripts python: exported-sql-viewer.py: Add All branches reportAdrian Hunter
2018-10-23perf scripts python: exported-sql-viewer.py: Add ability to display all the d...Adrian Hunter
2018-10-23perf scripts python: exported-sql-viewer.py: Add ability to shrink / enlarge ...Adrian Hunter
2018-10-23perf scripts python: exported-sql-viewer.py: Add ability to find symbols in t...Adrian Hunter
2018-10-23perf scripts python: exported-sql-viewer.py: Add support for multiple sub-win...Adrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Rename to exported-sql-viewer.pyAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Refactor TreeItem classAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Add data helper functionsAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Factor out CallGraphModel from T...Adrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Remove use of setObjectName()Adrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Add a class for global dataAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Separate the database details in...Adrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Make a "Main" functionAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Change iconAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Set a minimum window sizeAdrian Hunter
2018-10-23perf scripts python: call-graph-from-sql.py: Provide better default column sizesAdrian Hunter
2018-10-22perf scripts python: call-graph-from-sql.py: Use SPDX license identifierAdrian Hunter
2018-09-25perf script python: Fix export-to-sqlite.py sample columnsAdrian Hunter
2018-09-25perf script python: Fix export-to-postgresql.py occasional failureAdrian Hunter
2018-07-11perf scripts python: Add Python 3 support to EventClass.pyJeremy Cline
2018-07-11perf scripts python: Add Python 3 support to sched-migration.pyJeremy Cline
2018-07-11perf scripts python: Add Python 3 support to Util.pyJeremy Cline
2018-07-11perf scripts python: Add Python 3 support to SchedGui.pyJeremy Cline
2018-07-11perf scripts python: Add Python 3 support to Core.pyJeremy Cline
2018-06-06perf script powerpc: Python script for hypervisor call statisticsRavi Bangoria
2018-02-19perf tools: Add Python 3 supportJaroslav Škarvada
2018-01-12perf script python: Add script to profile and resolve physical mem typeKan Liang
2017-11-02License cleanup: add SPDX GPL-2.0 license identifier to files with no licenseGreg Kroah-Hartman
2017-08-15perf script python: Add support for sqlite3 to call-graph-from-sql.pyAdrian Hunter
2017-08-15perf script python: Rename call-graph-from-postgresql.py to call-graph-from-s...Adrian Hunter
2017-08-15perf script python: Add support for exporting to sqlite3Adrian Hunter
2017-08-15perf scripts python: Fix query in call-graph-from-postgresql.pyAdrian Hunter
2017-08-15perf scripts python: Fix missing call_path_id in export-to-postgresql scriptAdrian Hunter
2017-08-11perf scripting python: Add ppc64le to audit uname listNaveen N. Rao
2017-06-30perf intel-pt: Add example script for power events and PTWRITEAdrian Hunter
2016-07-27Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-nextLinus Torvalds
2016-07-09net: tracepoint napi:napi_poll add work and budgetJesper Dangaard Brouer
2016-06-22perf script stackcollapse: Remove reference to the perl interpreterArnaldo Carvalho de Melo
2016-06-21perf script: Add stackcollapse.py scriptPaolo Bonzini
2016-05-06perf script: Update export-to-postgresql to support callchain exportChris Phlipot
2016-04-19perf script: Fix postgresql ubuntu install instructionsChris Phlipot
2016-02-12perf python scripting: Append examples to err msg about audit-libs-pythonTaeung Song
2016-01-06perf script: Add stat-cpi.py scriptJiri Olsa
2015-09-28perf tools: Add more documentation to export-to-postgresql.py scriptAdrian Hunter
2015-08-28perf scripts python: Add new compaction-times scriptTony Jones
2015-08-21perf tools: Add example call-graph scriptAdrian Hunter
2015-02-12perf build: Add scripts objects buildingJiri Olsa
2014-11-03perf tools: Add call information to Python exportAdrian Hunter
2014-11-03perf tools: Add branch_type and in_tx to Python exportAdrian Hunter
eter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> 2016-12-25clocksource: Use a plain u64 instead of cycle_tThomas Gleixner There is no point in having an extra type for extra confusion. u64 is unambiguous. Conversion was done with the following coccinelle script: @rem@ @@ -typedef u64 cycle_t; @fix@ typedef cycle_t; @@ -cycle_t +u64 Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: John Stultz <john.stultz@linaro.org> 2016-12-09tracing/fgraph: Have wakeup and irqsoff tracers ignore graph functions tooSteven Rostedt (Red Hat) Currently both the wakeup and irqsoff traces do not handle set_graph_notrace well. The ftrace infrastructure will ignore the return paths of all functions leaving them hanging without an end: # echo '*spin*' > set_graph_notrace # cat trace [...] _raw_spin_lock() { preempt_count_add() { do_raw_spin_lock() { update_rq_clock(); Where the '*spin*' functions should have looked like this: _raw_spin_lock() { preempt_count_add(); do_raw_spin_lock(); } update_rq_clock(); Instead, have the wakeup and irqsoff tracers ignore the functions that are set by the set_graph_notrace like the function_graph tracer does. Move the logic in the function_graph tracer into a header to allow wakeup and irqsoff tracers to use it as well. Cc: Namhyung Kim <namhyung.kim@lge.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2016-11-14tracing: Allow wakeup_dl tracer to be used by instancesZhou Chengming Allow wakeup_dl tracer to be used by instances, like wakeup tracer and wakeup_rt tracer. Link: http://lkml.kernel.org/r/1479093553-31264-1-git-send-email-zhouchengming1@huawei.com Signed-off-by: Zhou Chengming <zhouchengming1@huawei.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-11-06Merge tag 'trace-v4.4' of ↵Linus Torvalds git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracking updates from Steven Rostedt: "Most of the changes are clean ups and small fixes. Some of them have stable tags to them. I searched through my INBOX just as the merge window opened and found lots of patches to pull. I ran them through all my tests and they were in linux-next for a few days. Features added this release: ---------------------------- - Module globbing. You can now filter function tracing to several modules. # echo '*:mod:*snd*' > set_ftrace_filter (Dmitry Safonov) - Tracer specific options are now visible even when the tracer is not active. It was rather annoying that you can only see and modify tracer options after enabling the tracer. Now they are in the options/ directory even when the tracer is not active. Although they are still only visible when the tracer is active in the trace_options file. - Trace options are now per instance (although some of the tracer specific options are global) - New tracefs file: set_event_pid. If any pid is added to this file, then all events in the instance will filter out events that are not part of this pid. sched_switch and sched_wakeup events handle next and the wakee pids" * tag 'trace-v4.4' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: (68 commits) tracefs: Fix refcount imbalance in start_creating() tracing: Put back comma for empty fields in boot string parsing tracing: Apply tracer specific options from kernel command line. tracing: Add some documentation about set_event_pid ring_buffer: Remove unneeded smp_wmb() before wakeup of reader benchmark tracing: Allow dumping traces without tracking trace started cpus ring_buffer: Fix more races when terminating the producer in the benchmark ring_buffer: Do no not complete benchmark reader too early tracing: Remove redundant TP_ARGS redefining tracing: Rename max_stack_lock to stack_trace_max_lock tracing: Allow arch-specific stack tracer recordmcount: arm64: Replace the ignored mcount call into nop recordmcount: Fix endianness handling bug for nop_mcount tracepoints: Fix documentation of RCU lockdep checks tracing: ftrace_event_is_function() can return boolean tracing: is_legal_op() can return boolean ring-buffer: rb_event_is_commit() can return boolean ring-buffer: rb_per_cpu_empty() can return boolean ring_buffer: ring_buffer_empty{cpu}() can return boolean ring-buffer: rb_is_reader_page() can return boolean ... 2015-11-02tracing: report_latency() in trace_sched_wakeup.c can return booleanYaowei Bai This patch makes report_latency return bool to improve readability, indicating whether this new latency should be reported/recorded. No functional change. Link: http://lkml.kernel.org/r/1443537816-5788-2-git-send-email-bywxiaobai@163.com Signed-off-by: Yaowei Bai <bywxiaobai@163.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-10-06sched/core: Fix trace_sched_switch()Peter Zijlstra __trace_sched_switch_state() is the last remaining PREEMPT_ACTIVE user, move trace_sched_switch() from prepare_task_switch() to __schedule() and propagate the @preempt argument. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Steven Rostedt <rostedt@goodmis.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org> 2015-09-30tracing: Move trace_flags from global to a trace_array fieldSteven Rostedt (Red Hat) In preparation to make trace options per instance, the global trace_flags needs to be moved from being a global variable to a field within the trace instance trace_array structure. There's still more work to do, as there's some functions that use trace_flags without passing in a way to get to the current_trace array. For those, the global_trace is used directly (from trace.c). This includes setting and clearing the trace_flags. This means that when a new instance is created, it just gets the trace_flags of the global_trace and will not be able to modify them. Depending on the functions that have access to the trace_array, the flags of an instance may not affect parts of its trace, where the global_trace is used. These will be fixed in future changes. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-09-29tracing: Do not create function tracer options when not compiled inSteven Rostedt (Red Hat) When the function tracer is not compiled in, do not create the option files for it. Fix up both the sched_wakeup and irqsoff tracers to handle the change. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-09-29tracing: Only create function graph options when it is compiled inSteven Rostedt (Red Hat) Do not create fuction graph tracer options when function graph tracer is not even compiled in. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-09-29tracing: Move "display-graph" option to main optionsSteven Rostedt (Red Hat) In order to facilitate making all tracer options visible even when the tracer is not active, we need to get rid of duplicate options. Any option that is shared between multiple tracers really should be a main option. As the wakeup and irqsoff tracers both use the "display-graph" option, and use it exactly the same way, move that option from the tracer options to the main options and consolidate them. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-09-25tracing: Pass trace_array into trace_buffer_unlock_commit()Steven Rostedt (Red Hat) In preparation for having trace options be per instance, the trace_array needs to be passed to the trace_buffer_unlock_commit(). The trace_event_buffer_lock_reserve() already passes in the trace_event_file where the trace_array can be derived from. Also added a "__init" to the boot up test event plus function tracing function function_test_events_call(). Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-08-03sched: Introduce the 'trace_sched_waking' tracepointPeter Zijlstra Mathieu reported that since 317f394160e9 ("sched: Move the second half of ttwu() to the remote cpu") trace_sched_wakeup() can happen out of context of the waker. This is a problem when you want to analyse wakeup paths because it is now very hard to correlate the wakeup event to whoever issued the wakeup. OTOH trace_sched_wakeup() is issued at the point where we set p->state = TASK_RUNNING, which is right were we hand the task off to the scheduler, so this is an important point when looking at scheduling behaviour, up to here its been the wakeup path everything hereafter is due to scheduler policy. To bridge this gap, introduce a second tracepoint: trace_sched_waking. It is guaranteed to be called in the waker context. Reported-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Francis Giraldeau <francis.giraldeau@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20150609091336.GQ3644@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org> 2015-05-13tracing: Rename ftrace_event_{call,class} to trace_event_{call,class}Steven Rostedt (Red Hat) The name "ftrace" really refers to the function hook infrastructure. It is not about the trace_events. The structures ftrace_event_call and ftrace_event_class have nothing to do with the function hooks, and are really trace_event structures. Rename ftrace_event_* to trace_event_*. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2015-01-22tracing: Remove unneeded includes of debugfs.h and fs.hSteven Rostedt (Red Hat) The creation of tracing files and directories is for the most part encapsulated in helper functions in trace.c. Other files do not need to include debugfs.h or fs.h, as they may have needed to in the past. Remove them from the files that do not need them. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-11-11tracing: Move tracing_sched_{switch,wakeup}() into wakeup tracerSteven Rostedt (Red Hat) The only code that references tracing_sched_switch_trace() and tracing_sched_wakeup_trace() is the wakeup latency tracer. Those two functions use to belong to the sched_switch tracer which has long been removed. These functions were left behind because the wakeup latency tracer used them. But since the wakeup latency tracer is the only one to use them, they should be static functions inside that code. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-04-30tracing: Remove mock up poll wait functionSteven Rostedt (Red Hat) Now that the ring buffer has a built in way to wake up readers when there's data, using irq_work such that it is safe to do it in any context. But it was still using the old "poor man's" wait polling that checks every 1/10 of a second to see if it should wake up a waiter. This makes the latency for a wake up excruciatingly long. No need to do that anymore. Completely remove the different wait_poll types from the tracers and have them all use the default one now. Reported-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-04-21tracing: Allow wakeup tracers to be used by instancesSteven Rostedt (Red Hat) The wakeup and wakeup_rt tracers can now be used by instances. But they may only be used by one instance at a time (including the top level directory). This allows multiple tracers to run while the wakeup tracer is running simultaneously. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-04-21tracing: Move tracing_max_latency into trace_arraySteven Rostedt (Red Hat) In preparation for letting the latency tracers be used by instances, remove the global tracing_max_latency variable and add a max_latency field to the trace_array that the latency tracers will now use. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-04-21ftrace: Remove global function list and call function directlySteven Rostedt (Red Hat) Instead of having a list of global functions that are called, as only one global function is allow to be enabled at a time, there's no reason to have a list. Instead, simply have all the users of the global ops, use the global ops directly, instead of registering their own ftrace_ops. Just switch what function is used before enabling the function tracer. This removes a lot of code as well as the complexity involved with it. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-02-20tracing: Pass trace_array to flag_changed callbackSteven Rostedt (Red Hat) As options (flags) may affect instances instead of being global the flag_changed() callbacks need to receive the trace_array descriptor of the instance they will be modifying. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-02-20tracing: Pass trace_array to set_flag callbackSteven Rostedt (Red Hat) As options (flags) may affect instances instead of being global the set_flag() callbacks need to receive the trace_array descriptor of the instance they will be modifying. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> 2014-01-13sched/deadline: Add SCHED_DEADLINE inheritance logicDario Faggioli Some method to deal with rt-mutexes and make sched_dl interact with the current PI-coded is needed, raising all but trivial issues, that needs (according to us) to be solved with some restructuring of the pi-code (i.e., going toward a proxy execution-ish implementation). This is under development, in the meanwhile, as a temporary solution, what this commits does is: - ensure a pi-lock owner with waiters is never throttled down. Instead, when it runs out of runtime, it immediately gets replenished and it's deadline is postponed; - the scheduling parameters (relative deadline and default runtime) used for that replenishments --during the whole period it holds the pi-lock-- are the ones of the waiting task with earliest deadline. Acting this way, we provide some kind of boosting to the lock-owner, still by using the existing (actually, slightly modified by the previous commit) pi-architecture. We would stress the fact that this is only a surely needed, all but clean solution to the problem. In the end it's only a way to re-start discussion within the community. So, as always, comments, ideas, rants, etc.. are welcome! :-) Signed-off-by: Dario Faggioli <raistlin@linux.it> Signed-off-by: Juri Lelli <juri.lelli@gmail.com> [ Added !RT_MUTEXES build fix. ] Signed-off-by: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1383831828-15501-11-git-send-email-juri.lelli@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org> 2014-01-13sched/deadline: Add latency tracing for SCHED_DEADLINE tasksDario Faggioli It is very likely that systems that wants/needs to use the new SCHED_DEADLINE policy also want to have the scheduling latency of the -deadline tasks under control. For this reason a new version of the scheduling wakeup latency, called "wakeup_dl", is introduced. As a consequence of applying this patch there will be three wakeup latency tracer: * "wakeup", that deals with all tasks in the system; * "wakeup_rt", that deals with -rt and -deadline tasks only; * "wakeup_dl", that deals with -deadline tasks only. Signed-off-by: Dario Faggioli <raistlin@linux.it> Signed-off-by: Juri Lelli <juri.lelli@gmail.com> Signed-off-by: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1383831828-15501-9-git-send-email-juri.lelli@gmail.com Signed-off-by: Ingo Molnar <mingo@kernel.org>