From dfb0c40490f5a2e28f0d1e9bbb29a57ee91a9f52 Mon Sep 17 00:00:00 2001 From: Anton Blanchard Date: Tue, 30 Aug 2011 09:15:06 +1000 Subject: [PATCH] --- yaml --- r: 264096 b: refs/heads/master c: 6a0e55d85babfccfd976703852ec8bab388b3a10 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/tools/perf/util/event.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index ccacbcef0cd9..635afa481fff 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 764e16a30a77a9c8346fbae6615e7c818ce9d00f +refs/heads/master: 6a0e55d85babfccfd976703852ec8bab388b3a10 diff --git a/trunk/tools/perf/util/event.c b/trunk/tools/perf/util/event.c index 3c1b8a632101..437f8ca679a0 100644 --- a/trunk/tools/perf/util/event.c +++ b/trunk/tools/perf/util/event.c @@ -169,12 +169,17 @@ static int perf_event__synthesize_mmap_events(union perf_event *event, continue; pbf += n + 3; if (*pbf == 'x') { /* vm_exec */ + char anonstr[] = "//anon\n"; char *execname = strchr(bf, '/'); /* Catch VDSO */ if (execname == NULL) execname = strstr(bf, "[vdso]"); + /* Catch anonymous mmaps */ + if ((execname == NULL) && !strstr(bf, "[")) + execname = anonstr; + if (execname == NULL) continue;