From: Anton Blanchard Date: Thu, 16 Jul 2009 13:44:29 +0000 (+0200) Subject: perf_counter: Synthesize VDSO mmap event X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=11b5f81e1b0ea0bc84fe32f0a27054e052b2bf84;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git perf_counter: Synthesize VDSO mmap event perf record synthesizes mmap events for the running process. Right now it just catches file mappings, but we can check for the vdso symbol and add that too. Signed-off-by: Anton Blanchard Signed-off-by: Peter Zijlstra LKML-Reference: <20090716104817.517264409@samba.org> Signed-off-by: Ingo Molnar --- diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c index 4ef78a5e6f32..072aaf0369f8 100644 --- a/tools/perf/builtin-record.c +++ b/tools/perf/builtin-record.c @@ -313,6 +313,10 @@ static void pid_synthesize_mmap_samples(pid_t pid) if (*pbf == 'x') { /* vm_exec */ char *execname = strchr(bf, '/'); + /* Catch VDSO */ + if (execname == NULL) + execname = strstr(bf, "[vdso]"); + if (execname == NULL) continue;