linux/tools
Andi Kleen 62ec9b3f02 perf annotate: Inform the user about objdump failures in --stdio
When the browser fails to annotate it is difficult for users to find out
what went wrong.

Add some errors for objdump failures that are displayed in the UI.

Note it would be even better to handle these errors smarter, like
falling back to the binary when the debug info is somehow corrupted. But
for now just giving a better error is an improvement.

Committer note:

This works for --stdio, where errors just scroll by the screen:

  # perf annotate --stdio intel_idle
  Failure running objdump  --start-address=0xffffffff81418290 --stop-address=0xffffffff814183ae -l -d --no-show-raw -S -C /root/.debug/.build-id/28/2777c262e6b3c0451375163c9a81c893218ab1 2>/dev/null|grep -v /root/.debug/.build-id/28/2777c262e6b3c0451375163c9a81c893218ab1|expand
   Percent |      Source code & Disassembly of vmlinux for cycles:pp
  ------------------------------------------------------------------

And with that one can use that command line to try to find out more about what
happened instead of getting a blank screen, an improvement.

We need tho to improve this further to get it to work with other UIs, like
--tui and --gtk, where it continues showing a blank screen, no messages, as
the pr_err() used is enough just for --stdio.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: http://lkml.kernel.org/r/1446779167-18949-1-git-send-email-andi@firstfloor.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2015-11-06 10:20:48 -03:00
..
arch tools include: Add basic atomic.h implementation from the kernel sources 2015-05-08 16:11:05 -03:00
build tools build: Fix libiberty feature detection 2015-10-29 17:46:35 -03:00
cgroup
firewire
hv tools: hv: add a python script lsvmbus to list VMBus devices 2015-08-05 11:44:29 -07:00
iio iio: lsiio: fix error code handling error 2015-08-12 19:26:22 +01:00
include tools include: Fix strict-aliasing rules breakage 2015-10-13 11:43:16 -03:00
laptop/freefall Move freefall program from Documentation/ to tools/ 2015-06-08 16:42:07 -06:00
lguest tools/lguest: Clean up include dir 2015-08-26 06:12:35 +02:00
lib tools lib bpf: Change FEATURE-DUMP to FEATURE-DUMP.libbpf 2015-11-05 12:47:51 -03:00
net bpf_jit_disasm: also support reading jit dump from file 2015-07-31 15:13:14 -07:00
nfsd
perf perf annotate: Inform the user about objdump failures in --stdio 2015-11-06 10:20:48 -03:00
power tools/power turbosat: update version number 2015-09-26 09:49:55 -04:00
scripts
testing membarrier: clean up selftest 2015-09-22 15:09:53 -07:00
thermal/tmon tools/thermal: tmon: fixed the 'make install' command 2015-05-09 13:36:58 +08:00
time tools: add script to test udelay 2014-07-23 10:16:38 -07:00
usb tools: ffs-aio-example: use endpoint addresses from descriptors 2015-01-15 09:41:49 -06:00
virtio tools/virtio: propagate V=X to kernel build 2015-09-16 12:48:07 +03:00
vm tools vm: Fix build due to removal of tools/lib/api/fs/debugfs.h 2015-09-22 22:42:39 -03:00
Makefile Staging driver patches for 4.2-rc1 2015-06-26 15:46:08 -07:00