linux/tools/perf/util
Tom Zanussi 63e0c7715a perf: record TRACE_INFO only if using tracepoints and SAMPLE_RAW
The current perf code implicitly assumes SAMPLE_RAW means tracepoints
are being used, but doesn't check for that.  It happily records the
TRACE_INFO even if SAMPLE_RAW is used without tracepoints, but when the
perf data is read it won't go any further when it finds TRACE_INFO but
no tracepoints, and displays misleading errors.

This adds a check for both in perf-record, and won't record TRACE_INFO
unless both are true.  This at least allows perf report -D to dump raw
events, and avoids triggering a misleading error condition in perf
trace.  It doesn't actually enable the non-tracepoint raw events to be
displayed in perf trace, since perf trace currently only deals with
tracepoint events.

Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <1272865861.7932.16.camel@tropicana>
Signed-off-by: Tom Zanussi <tzanussi@gmail.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2010-05-03 10:31:48 -03:00
..
include perf tools: Don't use code surrounded by __KERNEL__ 2010-05-02 12:00:44 -03:00
scripting-engines perf/scripts: Tuple was set from long in both branches in python_process_event() 2010-04-02 21:32:16 +02:00
abspath.c
alias.c
bitmap.c perf tools: Don't use code surrounded by __KERNEL__ 2010-05-02 12:00:44 -03:00
build-id.c perf: 'perf kvm' tool for monitoring guest performance from host 2010-04-19 12:37:24 +03:00
build-id.h perf build-id: Move the routine to find DSOs with hits to the lib 2010-02-04 09:33:26 +01:00
cache.h perf newt: Properly restore the screen when error exiting 2010-03-22 18:47:34 +01:00
callchain.c perf callchains: Store the map together with the symbol 2010-03-26 08:52:57 +01:00
callchain.h perf callchains: Store the map together with the symbol 2010-03-26 08:52:57 +01:00
color.c perf hist: Replace ->print() routines by ->snprintf() equivalents 2010-04-02 16:28:15 -03:00
color.h perf hist: Replace ->print() routines by ->snprintf() equivalents 2010-04-02 16:28:15 -03:00
config.c
cpumap.c perf tools: Fix sparse CPU numbering related bugs 2010-03-11 13:36:53 +01:00
cpumap.h perf tools: Fix sparse CPU numbering related bugs 2010-03-11 13:36:53 +01:00
ctype.c
debug.c perf: Fix endianness argument compatibility with OPT_BOOLEAN() and introduce OPT_INCR() 2010-04-14 11:26:44 +02:00
debug.h perf: Fix endianness argument compatibility with OPT_BOOLEAN() and introduce OPT_INCR() 2010-04-14 11:26:44 +02:00
debugfs.c perf trace: Clean up find_debugfs() 2009-12-28 10:36:36 +01:00
debugfs.h perf tools: Mount debugfs automatically 2009-12-28 10:36:36 +01:00
environment.c
event.c perf machine: Adopt some map_groups functions 2010-04-27 21:21:18 -03:00
event.h perf tools: Rename "kernel_info" to "machine" 2010-04-27 21:17:50 -03:00
exec_cmd.c
exec_cmd.h
generate-cmdlist.sh
header.c perf: record TRACE_INFO only if using tracepoints and SAMPLE_RAW 2010-05-03 10:31:48 -03:00
header.h perf/live: don't synthesize build ids at the end of a live mode trace 2010-05-02 12:04:05 -03:00
help.c
help.h
hist.c perf: 'perf kvm' tool for monitoring guest performance from host 2010-04-19 12:37:24 +03:00
hist.h perf: 'perf kvm' tool for monitoring guest performance from host 2010-04-19 12:37:24 +03:00
hweight.c perf tools: Don't use code surrounded by __KERNEL__ 2010-05-02 12:00:44 -03:00
levenshtein.c
levenshtein.h
map.c perf machine: Adopt some map_groups functions 2010-04-27 21:21:18 -03:00
map.h perf symbols: Add machine helper routines 2010-04-29 15:25:23 -03:00
newt.c perf TUI: Move "Yes" button to before "No" 2010-04-08 11:34:25 -03:00
pager.c
parse-events.c perf: Fix initialization bug in parse_single_tracepoint_event() 2010-04-24 03:24:09 +02:00
parse-events.h perf: record TRACE_INFO only if using tracepoints and SAMPLE_RAW 2010-05-03 10:31:48 -03:00
parse-options.c perf: Fix endianness argument compatibility with OPT_BOOLEAN() and introduce OPT_INCR() 2010-04-14 11:26:44 +02:00
parse-options.h perf: Fix endianness argument compatibility with OPT_BOOLEAN() and introduce OPT_INCR() 2010-04-14 11:26:44 +02:00
path.c
PERF-VERSION-GEN perf tools: Allow specifying O= to build files in a separate directory 2010-04-02 16:28:03 -03:00
probe-event.c perf machine: Adopt some map_groups functions 2010-04-27 21:21:18 -03:00
probe-event.h perf probe: Add --max-probes option 2010-04-26 15:35:20 -03:00
probe-finder.c perf probe: Add --max-probes option 2010-04-26 15:35:20 -03:00
probe-finder.h perf probe: Add --max-probes option 2010-04-26 15:35:20 -03:00
quote.c
quote.h
run-command.c
run-command.h
session.c perf: add perf-inject builtin 2010-05-02 13:36:56 -03:00
session.h perf: add perf-inject builtin 2010-05-02 13:36:56 -03:00
sigchain.c
sigchain.h
sort.c perf tools: Fix accidentally preprocessed snprintf callback 2010-04-14 16:59:21 -03:00
sort.h perf: 'perf kvm' tool for monitoring guest performance from host 2010-04-19 12:37:24 +03:00
strbuf.c
strbuf.h
string.c perf: Swap inclusion order of util.h and string.h in util/string.c 2010-04-04 16:40:42 +02:00
strlist.c
strlist.h perf tools: Add for_each macros for strlist 2009-12-15 20:22:02 +01:00
svghelper.c
svghelper.h
symbol.c perf symbols: Add machine helper routines 2010-04-29 15:25:23 -03:00
symbol.h perf symbols: Add machine helper routines 2010-04-29 15:25:23 -03:00
thread.c perf symbols: Move more map_groups methods to map.c 2010-04-02 16:27:39 -03:00
thread.h perf: 'perf kvm' tool for monitoring guest performance from host 2010-04-19 12:37:24 +03:00
trace-event-info.c perf: record TRACE_INFO only if using tracepoints and SAMPLE_RAW 2010-05-03 10:31:48 -03:00
trace-event-parse.c perf: Fix dynamic field detection 2010-04-15 01:34:46 +02:00
trace-event-read.c perf: add perf-inject builtin 2010-05-02 13:36:56 -03:00
trace-event-scripting.c perf/scripts: Add Python scripting engine 2010-02-25 04:07:29 +01:00
trace-event.h perf: add perf-inject builtin 2010-05-02 13:36:56 -03:00
types.h
usage.c
util.c perf: Fix implicit declaration of getline in util.c 2010-01-17 07:53:09 +01:00
util.h perf tools: Move the prototypes in util/string.h to util.h 2010-04-03 10:19:26 -03:00
values.c perf: Fix memory leak: counterwidth 2010-01-13 10:09:15 +01:00
values.h
wrapper.c