kernel-ark/kernel/trace
Jiri Olsa 5500fa5119 ftrace, perf: Add filter support for function trace event
Adding support to filter function trace event via perf
interface. It is now possible to use filter interface
in the perf tool like:

  perf record -e ftrace:function --filter="(ip == mm_*)" ls

The filter syntax is restricted to the the 'ip' field only,
and following operators are accepted '==' '!=' '||', ending
up with the filter strings like:

  ip == f1[, ]f2 ... || ip != f3[, ]f4 ...

with comma ',' or space ' ' as a function separator. If the
space ' ' is used as a separator, the right side of the
assignment needs to be enclosed in double quotes '"', e.g.:

  perf record -e ftrace:function --filter '(ip == do_execve,sys_*,ext*)' ls
  perf record -e ftrace:function --filter '(ip == "do_execve,sys_*,ext*")' ls
  perf record -e ftrace:function --filter '(ip == "do_execve sys_* ext*")' ls

The '==' operator adds trace filter with same effect as would
be added via set_ftrace_filter file.

The '!=' operator adds trace filter with same effect as would
be added via set_ftrace_notrace file.

The right side of the '!=', '==' operators is list of functions
or regexp. to be added to filter separated by space.

The '||' operator is used for connecting multiple filter definitions
together. It is possible to have more than one '==' and '!='
operators within one filter string.

Link: http://lkml.kernel.org/r/1329317514-8131-8-git-send-email-jolsa@redhat.com

Signed-off-by: Jiri Olsa <jolsa@redhat.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2012-02-21 11:08:30 -05:00
..
blktrace.c switch debugfs to umode_t 2012-01-03 22:54:56 -05:00
ftrace.c ftrace, perf: Add filter support for function trace event 2012-02-21 11:08:30 -05:00
Kconfig
Makefile Merge branch 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2011-10-26 17:03:38 +02:00
power-traces.c
ring_buffer_benchmark.c
ring_buffer.c Merge branch 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2011-10-26 17:03:38 +02:00
rpm-traces.c PM / Runtime: Introduce trace points for tracing rpm_* functions 2011-09-27 22:53:27 +02:00
trace_branch.c
trace_clock.c tracing: Add a counter clock for those that do not trust clocks 2011-09-19 11:35:58 -04:00
trace_entries.h ftrace: Allow to specify filter field type for ftrace events 2012-02-21 11:08:29 -05:00
trace_event_perf.c ftrace, perf: Add filter support for function trace event 2012-02-21 11:08:30 -05:00
trace_events_filter_test.h tracing/filter: Add startup tests for events filter 2011-08-19 14:35:59 -04:00
trace_events_filter.c ftrace, perf: Add filter support for function trace event 2012-02-21 11:08:30 -05:00
trace_events.c ftrace, perf: Add add/del tracepoint perf registration actions 2012-02-21 11:08:25 -05:00
trace_export.c ftrace: Allow to specify filter field type for ftrace events 2012-02-21 11:08:29 -05:00
trace_functions_graph.c
trace_functions.c
trace_irqsoff.c Merge branch 'tip/perf/core' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace into perf/core 2011-11-11 08:19:37 +01:00
trace_kdb.c
trace_kprobe.c ftrace, perf: Add add/del tracepoint perf registration actions 2012-02-21 11:08:25 -05:00
trace_mmiotrace.c
trace_nop.c
trace_output.c tracing: Don't use p->len field to determine output in __print_*() functions 2012-02-21 11:08:13 -05:00
trace_output.h
trace_printk.c
trace_sched_switch.c
trace_sched_wakeup.c tracing/latency: Fix header output for latency tracers 2011-11-07 13:48:35 -05:00
trace_selftest_dynamic.c
trace_selftest.c
trace_stack.c tracing: Have stack tracing set filtered functions at boot 2011-12-21 07:26:49 -05:00
trace_stat.c
trace_stat.h
trace_syscalls.c ftrace, perf: Add add/del tracepoint perf registration actions 2012-02-21 11:08:25 -05:00
trace_workqueue.c
trace.c ftrace: sched_switch plugin is deprecated 2012-02-13 09:14:47 -05:00
trace.h ftrace, perf: Add filter support for function trace event 2012-02-21 11:08:30 -05:00