public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jiri Olsa <jolsa@redhat.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>, Jiri Olsa <jolsa@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: RFC: callchain showing same entry as hist_entry
Date: Tue, 16 Aug 2016 16:50:01 +0200	[thread overview]
Message-ID: <20160816145001.GA25879@krava> (raw)
In-Reply-To: <20160816143628.GG20972@kernel.org>

On Tue, Aug 16, 2016 at 11:36:28AM -0300, Arnaldo Carvalho de Melo wrote:
> Hi Namhyung, Jiri,
> 
> 	please take a look at the patch below, and Ack if possible, it
> is a problem introduced in:
> 
>   cfaa154b2335 ("perf tools: Get rid of obsolete hist_entry__sort_list")
> 
> That is not equivalent to the code that was there and results in having
> the same entry as the first entry for the callchain as in the
> hist_entry, which is annoying and doesn't match the original intent of
> that 'continue' branch, as described in the comment right above it.
> 
> Now looking at doing the same for the TUI...

yep, seems ok.. no sort_order -> no first entry

jirka

> 
> - Arnaldo
> 
> diff --git a/tools/perf/ui/stdio/hist.c b/tools/perf/ui/stdio/hist.c
> index 9b65f4a6b35a..46a083e59ce9 100644
> --- a/tools/perf/ui/stdio/hist.c
> +++ b/tools/perf/ui/stdio/hist.c
> @@ -207,7 +207,7 @@ static size_t callchain__fprintf_graph(FILE *fp, struct rb_root *root,
>  			 * displayed twice.
>  			 */
>  			if (!i++ && field_order == NULL &&
> -			    sort_order && !prefixcmp(sort_order, "sym"))
> +			    (sort_order == NULL || !prefixcmp(sort_order, "sym")))
>  				continue;
>  			if (!printed) {
>  				ret += callchain__fprintf_left_margin(fp, left_margin);

  reply	other threads:[~2016-08-16 14:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-16 14:36 RFC: callchain showing same entry as hist_entry Arnaldo Carvalho de Melo
2016-08-16 14:50 ` Jiri Olsa [this message]
2016-08-16 14:55 ` Namhyung Kim
2016-08-16 15:08   ` Arnaldo Carvalho de Melo
2016-08-16 15:23     ` Namhyung Kim
2016-08-16 15:31       ` Arnaldo Carvalho de Melo
2016-08-16 15:32         ` Arnaldo Carvalho de Melo
2016-08-16 15:41           ` Namhyung Kim
2016-08-16 15:46             ` Arnaldo Carvalho de Melo
2016-08-16 19:21               ` Arnaldo Carvalho de Melo
2016-08-19  2:20                 ` Namhyung Kim

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=20160816145001.GA25879@krava \
    --to=jolsa@redhat.com \
    --cc=acme@kernel.org \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=namhyung@kernel.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