Commit 580d607c authored by Peter Zijlstra's avatar Peter Zijlstra Committed by Ingo Molnar
Browse files

perf: Optimize perf_tp_event_match()

Since we know tracepoints come from kernel context,
avoid conditionals that try and establish that very
Signed-off-by: default avatarPeter Zijlstra <>
Cc: Arnaldo Carvalho de Melo <>
Cc: Frederic Weisbecker <>
Cc: Paul Mackerras <>
Cc: Mike Galbraith <>
Cc: Steven Rostedt <>
LKML-Reference: <>
Signed-off-by: default avatarIngo Molnar <>
parent a94ffaaf
......@@ -4496,7 +4496,10 @@ static int perf_tp_event_match(struct perf_event *event,
struct perf_sample_data *data,
struct pt_regs *regs)
if (perf_exclude_event(event, regs))
* All tracepoints are from kernel-space.
if (event->attr.exclude_kernel)
return 0;
if (!perf_tp_filter_match(event, data))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment