From: Arnaldo Carvalho de Melo <acme@redhat.com>
To: Stephane Eranian <eranian@google.com>
Cc: LKML <linux-kernel@vger.kernel.org>,
Namhyung Kim <namhyung@kernel.org>, Jiri Olsa <jolsa@redhat.com>,
"mingo@elte.hu" <mingo@elte.hu>,
Peter Zijlstra <peterz@infradead.org>,
David Ahern <dsahern@gmail.com>,
acme@ghostprotocols.net
Subject: Re: [BUG] perf annotate: not reporting all events profiles
Date: Tue, 11 Mar 2014 00:33:45 -0300 [thread overview]
Message-ID: <20140311033345.GA2631@infradead.org> (raw)
In-Reply-To: <CABPqkBS1A5d-=OBUL6wJA-MAAKK2UTS+_kbYyBN=d-hohSc89Q@mail.gmail.com>
Em Mon, Mar 10, 2014 at 10:57:48PM +0100, Stephane Eranian escreveu:
> Arnaldo,
>
> I am using tip.git perf and I do the following:
>
> $ perf record -e cycles,instructions foo
> $ perf annotate --stdio
>
> (no explicit grouping).
>
> I only see the asm profile for the first event (cycles).
> I don't see a way to display the profile for the second
> event in the cmdline options.
>
> Yet the code in __cmd_annotate() seems to try and
> display all profiles.
>
> If I use the TUI, it prompts me for the event at the first
> screen and I get different asm profiles.
>
> So what is wrong?
That code went from supporting just one type of sample to suporting
groups, GTK+, TUI, etc, needs some work to untangle things up and make
it clearer...
But TUI works as expected, right?
That being said, try this patch, that is not optimal yet but allows you
to see the events.
I'll continue work on fixing up --stdio tomorrow.
- Arnaldo
diff --git a/tools/perf/builtin-annotate.c b/tools/perf/builtin-annotate.c
index 0da603b79b61..9bf9055da29c 100644
--- a/tools/perf/builtin-annotate.c
+++ b/tools/perf/builtin-annotate.c
@@ -180,7 +180,7 @@ find_next:
* symbol, free he->ms.sym->src to signal we already
* processed this symbol.
*/
- zfree(¬es->src);
+ //zfree(¬es->src);
}
}
}
diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c
index 3aa555ff9d89..7fb2cd70f91a 100644
--- a/tools/perf/util/annotate.c
+++ b/tools/perf/util/annotate.c
@@ -1260,8 +1260,8 @@ int symbol__annotate_printf(struct symbol *sym, struct map *map,
if (perf_evsel__is_group_event(evsel))
width *= evsel->nr_members;
- printf(" %-*.*s| Source code & Disassembly of %s\n",
- width, width, "Percent", d_filename);
+ printf(" %-*.*s| Source code & Disassembly of %s for %s samples\n",
+ width, width, "Percent", d_filename, perf_evsel__name(evsel));
printf("-%-*.*s-------------------------------------\n",
width+namelen, width+namelen, graph_dotted_line);
next prev parent reply other threads:[~2014-03-11 3:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-10 21:57 Stephane Eranian
2014-03-11 3:33 ` Arnaldo Carvalho de Melo [this message]
2014-03-12 14:05 ` Stephane Eranian
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140311033345.GA2631@infradead.org \
--to=acme@redhat.com \
--cc=acme@ghostprotocols.net \
--cc=dsahern@gmail.com \
--cc=eranian@google.com \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®