10 Feb, 2015
2 commits
-
Pull perf updates from Ingo Molnar:
"Kernel side changes:- AMD range breakpoints support:
Extend breakpoint tools and core to support address range through
perf event with initial backend support for AMD extended
breakpoints.The syntax is:
perf record -e mem:addr/len:type
For example set write breakpoint from 0x1000 to 0x1200 (0x1000 + 512)
perf record -e mem:0x1000/512:w
- event throttling/rotating fixes
- various event group handling fixes, cleanups and general paranoia
code to be more robust against bugs in the future.- kernel stack overhead fixes
User-visible tooling side changes:
- Show precise number of samples in at the end of a 'record' session,
if processing build ids, since we will then traverse the whole
perf.data file and see all the PERF_RECORD_SAMPLE records,
otherwise stop showing the previous off-base heuristicly counted
number of "samples" (Namhyung Kim).- Support to read compressed module from build-id cache (Namhyung
Kim)- Enable sampling loads and stores simultaneously in 'perf mem'
(Stephane Eranian)- 'perf diff' output improvements (Namhyung Kim)
- Fix error reporting for evsel pgfault constructor (Arnaldo Carvalho
de Melo)Tooling side infrastructure changes:
- Cache eh/debug frame offset for dwarf unwind (Namhyung Kim)
- Support parsing parameterized events (Cody P Schafer)
- Add support for IP address formats in libtraceevent (David Ahern)
Plus other misc fixes"
* 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (48 commits)
perf: Decouple unthrottling and rotating
perf: Drop module reference on event init failure
perf: Use POLLIN instead of POLL_IN for perf poll data in flag
perf: Fix put_event() ctx lock
perf: Fix move_group() order
perf: Fix event->ctx locking
perf: Add a bit of paranoia
perf symbols: Convert lseek + read to pread
perf tools: Use perf_data_file__fd() consistently
perf symbols: Support to read compressed module from build-id cache
perf evsel: Set attr.task bit for a tracking event
perf header: Set header version correctly
perf record: Show precise number of samples
perf tools: Do not use __perf_session__process_events() directly
perf callchain: Cache eh/debug frame offset for dwarf unwind
perf tools: Provide stub for missing pthread_attr_setaffinity_np
perf evsel: Don't rely on malloc working for sz 0
tools lib traceevent: Add support for IP address formats
perf ui/tui: Show fatal error message only if exists
perf tests: Fix typo in sample-parsing.c
... -
Pull RCU updates from Ingo Molnar:
"The main RCU changes in this cycle are:- Documentation updates.
- Miscellaneous fixes.
- Preemptible-RCU fixes, including fixing an old bug in the
interaction of RCU priority boosting and CPU hotplug.- SRCU updates.
- RCU CPU stall-warning updates.
- RCU torture-test updates"
* 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (54 commits)
rcu: Initialize tiny RCU stall-warning timeouts at boot
rcu: Fix RCU CPU stall detection in tiny implementation
rcu: Add GP-kthread-starvation checks to CPU stall warnings
rcu: Make cond_resched_rcu_qs() apply to normal RCU flavors
rcu: Optionally run grace-period kthreads at real-time priority
ksoftirqd: Use new cond_resched_rcu_qs() function
ksoftirqd: Enable IRQs and call cond_resched() before poking RCU
rcutorture: Add more diagnostics in rcu_barrier() test failure case
torture: Flag console.log file to prevent holdovers from earlier runs
torture: Add "-enable-kvm -soundhw pcspk" to qemu command line
rcutorture: Handle different mpstat versions
rcutorture: Check from beginning to end of grace period
rcu: Remove redundant rcu_batches_completed() declaration
rcutorture: Drop rcu_torture_completed() and friends
rcu: Provide rcu_batches_completed_sched() for TINY_RCU
rcutorture: Use unsigned for Reader Batch computations
rcutorture: Make build-output parsing correctly flag RCU's warnings
rcu: Make _batches_completed() functions return unsigned long
rcutorture: Issue warnings on close calls due to Reader Batch blows
documentation: Fix smp typo in memory-barriers.txt
...
07 Feb, 2015
1 commit
-
Pull core kernel fixes from Ingo Molnar:
"Two liblockdep fixes and a CPU hotplug race fix"* 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
tools/liblockdep: don't include host headers
tools/liblockdep: ignore generated .so file
smpboot: Add missing get_online_cpus() in smpboot_register_percpu_thread()
30 Jan, 2015
10 commits
-
Adding host headers to include path may cause unexpected surprises when cross
compiling. Remove /usr/local/include from the default include path.Signed-off-by: Baruch Siach
Signed-off-by: Sasha Levin -
Signed-off-by: Baruch Siach
Signed-off-by: Sasha Levin -
When dso_cache__read() is called, it reads data from the given offset
using lseek + normal read syscall. It can be combined to a single pread
syscall.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-40-git-send-email-namhyung@kernel.org
[ Fixed it up when cherry picking it from the multi threaded patchkit ]
Signed-off-by: Arnaldo Carvalho de Melo -
Do not reference file->fd directly since we want hide the
implementation details from outside for possible future changes.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-8-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
The commit c00c48fc6e6e ("perf symbols: Preparation for compressed
kernel module support") added support for compressed kernel modules but
it only supports system path DSOs. When a dso is read from build-id
cache, its filename doesn't end with ".gz" but has build-id. In this
case, we should fallback to the original dso->name.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-2-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
The perf_event_attr.task bit is to track task (fork and exit) events but
it missed to be set by perf_evsel__config(). While it was not a problem
in practice since setting other bits (comm/mmap) ended up being in same
result, it'd be good to set it explicitly anyway.The attr->task is to track task related events (fork/exit) only but
other meta events like comm and mmap[2] also needs the task events. So
setting attr->comm and/or attr->mmap causes the kernel emits the task
events anyway. So the attr->task is only meaningful when other bits are
off but I'd like to set it for completeness.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-6-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
When check_magic_endian() is called, it checks the magic number in the
perf data file to determine version and endianness. But if it uses a
same endian the verison number wasn't updated and makes confusion.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-5-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
After perf record finishes, it prints file size and number of samples in
the file but this info is wrong since it assumes typical sample size of
24 bytes and divides file size by the value.However as we post-process recorded samples for build-id, it can show
correct number like below. If build-id post-processing is not requested
just omit the wrong number of samples.$ perf record noploop 1
[ perf record: Woken up 1 times to write data ]
[ perf record: Captured and wrote 0.159 MB perf.data (3989 samples) ]$ perf report --stdio -n
# To display the perf.data header info, please use --header/--header-only options.
#
# Samples: 3K of event 'cycles'
# Event count (approx.): 3771330663
#
# Overhead Samples Command Shared Object Symbol
# ........ ............ ....... ................ ..........................
#
99.90% 3982 noploop noploop [.] main
0.09% 1 noploop ld-2.17.so [.] _dl_check_map_versions
0.01% 1 noploop [kernel.vmlinux] [k] setup_arg_pages
0.00% 5 noploop [kernel.vmlinux] [k] intel_pmu_enable_allReported-by: Milian Wolff
Signed-off-by: Namhyung Kim
Reviewed-by: Jiri Olsa
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-4-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
It's only used for perf record to process build-id because its file size
it's not fixed at this time due to remaining header features.However data offset and size is available so that we can use the
perf_session__process_events() once we set the file size as the current
offset like for now.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-3-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
When libunwind tries to resolve callchains it needs to know the offset
of .eh_frame_hdr or .debug_frame to access the dso.Since it will always return the same result for a given DSO, just cache
the result as an optimization.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1422518843-25818-41-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo
28 Jan, 2015
3 commits
-
uClibc Linuxthreads.old doesn't support the pthread_attr_setaffinity_np()
functioo:----------------->8-----------------------
CC bench/futex-hash.o
CC bench/futex-wake.o
bench/futex-hash.c: In function 'bench_futex_hash':
bench/futex-hash.c:161:3: error: implicit declaration of function
'pthread_attr_setaffinity_np' [-Werror=implicit-function-declaration]
ret = pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t),
&cpu);
^
bench/futex-hash.c:161:3: error: nested extern declaration of
'pthread_attr_setaffinity_np' [-Werror=nested-externs]
----------------->8-----------------------So introduce a test to check that and if not available provide a stub.
Signed-off-by: Vineet Gupta
Acked-by: Jiri Olsa
Cc: Alexey Brodkin
Cc: Namhyung Kim
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1421156604-30603-6-git-send-email-vgupta@synopsys.com
Signed-off-by: Arnaldo Carvalho de Melo -
When running perf on ARC (uClibc based userspace), ran into this issue
------------->8----------------
[ARCLinux]$ ./perf record ls
bin etc perf sys
debug init perf.data tmp
[ perf record: Woken up 1 times to write data ]
[ perf record: Captured and wrote 0.001 MB perf.data (~24 samples) ][ARCLinux]$ ./perf report
incompatible file format (rerun with -v to learn more)
------------->8----------------The problem happens in the following call stack when zalloc is called
with size zeroglibc default / uClibc with MALLOC_GLIBC_COMPAT are OK, but not if that
config option is not enabled.cmd_report
perf_session__new
perf_session__open
perf_session__read_header
read_attr(fd, header, &f_attr)
nr_ids = f_attr.ids.size / sizeof(u64);
Suggested-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Alexey Brodkin
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1421156604-30603-5-git-send-email-vgupta@synopsys.com
Signed-off-by: Arnaldo Carvalho de Melo -
The new hw_breakpoint bits are now ready for v3.20, merge them
into the main branch, to avoid conflicts.Conflicts:
tools/perf/Documentation/perf-record.txtSigned-off-by: Ingo Molnar
26 Jan, 2015
1 commit
-
Add helpers for the following kernel formats:
%pi4 print an IPv4 address with leading zeros
%pI4 print an IPv4 address without leading zeros
%pi6 print an IPv6 address without colons
%pI6 print an IPv6 address with colons
%pI6c print an IPv6 address in compressed form with colons
%pISpc print an IP address from a sockaddrAllows these formats to be used in tracepoints.
Quite a bit of this is adapted from code in lib/vsprintf.c.
v4:
- fixed pI6c description in git commit message per Valdis' commentv3:
- use of 'c' and 'p' requires 'I'v2:
- pass ptr+1 to print_ip_arg per Namhyung's comments
- added field length checks to sockaddr functionSigned-off-by: David Ahern
Acked-by: Steven Rostedt
Cc: Jiri Olsa
Cc: Namhyung Kim
Link: http://lkml.kernel.org/r/1418955071-36241-1-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
23 Jan, 2015
4 commits
-
When perf exits with some error it shows the error message with
ui__error() or ui__warning() and then calls ui__exit() during
exit_browser().On TUI, it then shows a window titled "Fatal Error" to inform user a
last message which might be related with this condition. However it
sometimes contains no message and just annoyes users.The usual case for this is running perf top as normal user. (And
/proc/sys/kernel/perf_event_paranoid being 1).Signed-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1421736050-5283-1-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
It was testing the same buffer for differences:
memcmp(s1->user_stack.data, s1->user_stack.data, s1->user_stack.size)
I'm pretty sure this wasn't supposed to be dead code.
Signed-off-by: Rasmus Villemoes
Cc: Paul Mackerras
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1421946083-29863-1-git-send-email-linux@rasmusvillemoes.dk
Signed-off-by: Arnaldo Carvalho de Melo -
If debugfs was already mounted, then its a matter of not finding the
tracepoint, tell the user that perhaps a CONFIG_ setting is not enabled.Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-6chfytoflyx3jwfqm7ebltu0@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
There will be other cases where not just a tracepoint event is being
opened below the debugfs mountpoint, but it is rather common, so provide
one helper for that.Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-q6e6zct49ql6nbcw8kkg0lbj@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo
22 Jan, 2015
19 commits
-
In that case the only failure possible is not to have enough memory, as
we are just creating the evsels, not trying to access any system
facility such as debugfs files or syscalls.Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-7k6asvfhiwiu2zs6o2oknchk@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
It was hardcoded for one specific tracepoint, leftover from its initial
user: 'perf trace'.Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-j1jicvwljy5qx1nah4mkmyke@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
As this is not specific to an evlist and may be used with other tools.
Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-a9up9mivx1pzdf5tqrqsx62d@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melotools/perf/util/include/asm/hash.h
-
The prior change fixes default output ordering with each column but it
breaks -o/--order option. This patch prepends a new hpp fmt struct to
sort list but not to output field list so that it can affect ordering
without adding a new output column.The new hpp fmt uses its own compare functions which treats dummy
entries (which have no baseline) little differently - the delta field
can be computed without baseline but others (ratio and wdiff) are not.The new output will look like below:
$ perf diff -o 2 perf.data.{old,cur,new}
...
# Baseline/0 Delta/1 Delta/2 Shared Object Symbol
# .......... ....... ....... ................. ..........................................
22.98% +0.51% +0.52% libc-2.20.so [.] _int_malloc
5.70% +0.28% +0.30% libc-2.20.so [.] free
4.38% -0.21% +0.25% a.out [.] main
1.32% -0.15% +0.05% a.out [.] free@plt
+0.01% [kernel.kallsyms] [k] intel_pstate_timer_func
+0.01% [kernel.kallsyms] [k] _raw_spin_lock_irqsave
+0.01% [kernel.kallsyms] [k] timekeeping_update.constprop.8
+0.01% +0.01% [kernel.kallsyms] [k] apic_timer_interrupt
0.01% -0.00% [kernel.kallsyms] [k] native_read_msr_safe
0.01% -0.01% -0.01% [kernel.kallsyms] [k] native_write_msr_safe
1.31% +0.03% -0.06% a.out [.] malloc@plt
31.50% -0.74% -0.23% libc-2.20.so [.] _int_free
32.75% +0.28% -0.83% libc-2.20.so [.] malloc
0.01% [kernel.kallsyms] [k] scheduler_tick
+0.01% [kernel.kallsyms] [k] read_tsc
+0.01% [kernel.kallsyms] [k] perf_adjust_freq_unthr_context.part.82In above example, the output was sorted by 'Delta/2' column first, and
then 'Baseline/0' and finally 'Delta/1'.Signed-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Kan Liang
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1420677949-6719-8-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
When perf diff prints output, it sorts the entries using baseline field
by default, but entries which don't have baseline are not sorted
properly. This patch makes it sorted by values of next column.Before:
# Baseline/0 Delta/1 Delta/2 Shared Object Symbol
# .......... ....... ....... ................. ..........................................
#
32.75% +0.28% -0.83% libc-2.20.so [.] malloc
31.50% -0.74% -0.23% libc-2.20.so [.] _int_free
22.98% +0.51% +0.52% libc-2.20.so [.] _int_malloc
5.70% +0.28% +0.30% libc-2.20.so [.] free
4.38% -0.21% +0.25% a.out [.] main
1.32% -0.15% +0.05% a.out [.] free@plt
1.31% +0.03% -0.06% a.out [.] malloc@plt
0.01% -0.01% -0.01% [kernel.kallsyms] [k] native_write_msr_safe
0.01% [kernel.kallsyms] [k] scheduler_tick
0.01% -0.00% [kernel.kallsyms] [k] native_read_msr_safe
+0.01% [kernel.kallsyms] [k] _raw_spin_lock_irqsave
+0.01% +0.01% [kernel.kallsyms] [k] apic_timer_interrupt
+0.01% [kernel.kallsyms] [k] intel_pstate_timer_func
+0.01% [kernel.kallsyms] [k] perf_adjust_freq_unthr_context.part.82
+0.01% [kernel.kallsyms] [k] read_tsc
+0.01% [kernel.kallsyms] [k] timekeeping_update.constprop.8After:
# Baseline/0 Delta/1 Delta/2 Shared Object Symbol
# .......... ....... ....... ................. ..........................................
#
32.75% +0.28% -0.83% libc-2.20.so [.] malloc
31.50% -0.74% -0.23% libc-2.20.so [.] _int_free
22.98% +0.51% +0.52% libc-2.20.so [.] _int_malloc
5.70% +0.28% +0.30% libc-2.20.so [.] free
4.38% -0.21% +0.25% a.out [.] main
1.32% -0.15% +0.05% a.out [.] free@plt
1.31% +0.03% -0.06% a.out [.] malloc@plt
0.01% -0.01% -0.01% [kernel.kallsyms] [k] native_write_msr_safe
0.01% [kernel.kallsyms] [k] scheduler_tick
0.01% -0.00% [kernel.kallsyms] [k] native_read_msr_safe
+0.01% +0.01% [kernel.kallsyms] [k] apic_timer_interrupt
+0.01% [kernel.kallsyms] [k] read_tsc
+0.01% [kernel.kallsyms] [k] perf_adjust_freq_unthr_context.part.82
+0.01% [kernel.kallsyms] [k] intel_pstate_timer_func
+0.01% [kernel.kallsyms] [k] _raw_spin_lock_irqsave
+0.01% [kernel.kallsyms] [k] timekeeping_update.constprop.8Signed-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Kan Liang
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1420677949-6719-7-git-send-email-namhyung@kernel.org
[ Fixed up hist_entry__cmp_ method signatures, fallout from making previous cset buildable ]
Signed-off-by: Arnaldo Carvalho de Melo -
Currently ->cmp, ->collapse and ->sort callbacks doesn't pass
corresponding fmt. But it'll be needed by upcoming changes in
perf diff command.Suggested-by: Jiri Olsa
Signed-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Kan Liang
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1420677949-6719-6-git-send-email-namhyung@kernel.org
[ fix build by passing perf_hpp_fmt pointer to hist_entry__cmp_ methods ]
Signed-off-by: Arnaldo Carvalho de Melo -
The fmt_to_data_file() is to retrieve struct data__file from
perf_hpp_fmt which is embedded in diff_hpp_fmt. It'll be used by sort
callback functions later.Signed-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Kan Liang
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1420677949-6719-5-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
Current perf diff result is somewhat confusing since it sometimes hide
small result and sometimes there's no result. So do not hide small
result (less than 0.01%) and print "N/A" if baseline is not
recorded (for ratio and wdiff only). Blank means the baseline is
available but its pairs are not.Before:
# Baseline Delta Shared Object Symbol
# ........ ....... ................. .........................
#
...
0.01% -0.01% [kernel.kallsyms] [k] native_write_msr_safe
0.01% [kernel.kallsyms] [k] scheduler_tick
0.01% [kernel.kallsyms] [k] native_read_msr_safe
0.00% [kernel.kallsyms] [k] __rcu_read_unlock
[kernel.kallsyms] [k] _raw_spin_lock
+0.01% [kernel.kallsyms] [k] apic_timer_interrupt
[kernel.kallsyms] [k] read_tscAfter:
# Baseline Delta Shared Object Symbol
# ........ ....... ................. .........................
#
...
0.01% -0.01% [kernel.kallsyms] [k] native_write_msr_safe
0.01% [kernel.kallsyms] [k] scheduler_tick
0.01% [kernel.kallsyms] [k] native_read_msr_safe
0.00% [kernel.kallsyms] [k] __rcu_read_unlock
+0.01% [kernel.kallsyms] [k] _raw_spin_lock
+0.01% [kernel.kallsyms] [k] apic_timer_interrupt
+0.01% [kernel.kallsyms] [k] read_tscSigned-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1419656793-32756-3-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
The hists__compute_resort() is to sort output fields based on the
given field/criteria. This was done without the sort list but as we
added the field to the sort list, we can do it with normal
hists__output_resort() using the ->sort callback.Signed-off-by: Namhyung Kim
Acked-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1419656793-32756-2-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
The exclusive options are to prohibit use of conflicting options at the
same time. But it had a side effect that it also limits a such option
can be used at most once. Currently the only user of the flag is perf
probe and it allows to use such options more than once, but when one
tries to use it, perf will fail like below:$ sudo perf probe -x /lib/libc-2.20.so --add malloc --add free
Error: option `add' cannot be used with add
...Signed-off-by: Namhyung Kim
Reviewed-by: Masami Hiramatsu
Cc: David Ahern
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Masami Hiramatsu
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1420886028-15135-1-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
Signed-off-by: Cody P Schafer
Signed-off-by: Sukadev Bhattiprolu
Acked-by: Jiri Olsa
Cc: Cody P Schafer
Cc: Haren Myneni
Cc: Jiri Olsa
Cc: Michael Ellerman
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: linuxppc-dev@lists.ozlabs.org
Link: http://lkml.kernel.org/r/1420679633-28856-5-git-send-email-sukadev@linux.vnet.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo -
This causes `perf list pmu` to show parameters for parameterized events
like:pmu/event_name,param1=?,param2=?/ [Kernel PMU event]
An example:
hv_24x7/HPM_TLBIE__PHYS_CORE,core=?/ [Kernel PMU event]
Signed-off-by: Cody P Schafer
Signed-off-by: Sukadev Bhattiprolu
Acked-by: Jiri Olsa
Cc: Cody P Schafer
Cc: Haren Myneni
Cc: Jiri Olsa
Cc: Michael Ellerman
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: linuxppc-dev@lists.ozlabs.org
Link: http://lkml.kernel.org/r/1420679633-28856-3-git-send-email-sukadev@linux.vnet.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo -
Enable event specification like:
pmu/event_name,param1=0x1,param2=0x4/
Assuming that
/sys/bus/event_source/devices/pmu/events/event_name
Contains something like
param2=?,bar=1,param1=?
Signed-off-by: Cody P Schafer
Signed-off-by: Sukadev Bhattiprolu
Acked-by: Jiri Olsa
Cc: Cody P Schafer
Cc: Haren Myneni
Cc: Jiri Olsa
Cc: Michael Ellerman
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: linuxppc-dev@lists.ozlabs.org
Link: http://lkml.kernel.org/r/1420679633-28856-2-git-send-email-sukadev@linux.vnet.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo -
Removes some functions that are not used anywhere:
color_parse_mem()
color_parse()This was partially found by using a static code analysis program called cppcheck.
Signed-off-by: Rickard Strandqvist
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Ramkumar Ramachandra
Link: http://lkml.kernel.org/r/1419079865-354-1-git-send-email-rickard_strandqvist@spectrumdigital.se
[ Remove now unused parse_{attr,color} routines too ]
Signed-off-by: Arnaldo Carvalho de Melo -
The report__inc_stat() function collects the number of hist entries in
the session in order to calculate the max size of the progess bar.It'd be better if it does it during the addition of hist entries so that
it can be used by other places too.Signed-off-by: Namhyung Kim
Cc: Adrian Hunter
Cc: David Ahern
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1419223455-4362-2-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
The code being used when decaying and deleting entries from a hists
instance was the same, provide a function to avoid code dup.Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-j6ideab7lkakavfvfguw858z@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
No logic changes, just to be consistent.
Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-f7n5y0mvk6gew5185h6fg316@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
Janitorial stuff: boredom moment.
Cc: Adrian Hunter
Cc: Borislav Petkov
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-u70i7shys3kths4hzru72bha@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
Just like the other parameters, grouping it on the builtin-mem specific
config area: struct perf_mem.Acked-by: Stephane Eranian
Cc: Andi Kleen
Cc: David Ahern
Cc: Don Zickus
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Joe Mario
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Richard Fowles
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-ad8ns5l51ongemfsir3zy09x@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo