linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: tglx@linutronix.de, a.p.zijlstra@chello.nl, namhyung@kernel.org,
	linux-kernel@vger.kernel.org, hpa@zytor.com, mingo@kernel.org,
	acme@redhat.com
Cc: linux-tip-commits@vger.kernel.org
Subject: Re: [tip:perf/urgent] perf hists: Fix determination of a callchain node's childlessness
Date: Sat, 16 Apr 2016 12:46:14 -0700	[thread overview]
Message-ID: <20160416194614.l6liupm35rmhg3ht@alap3.anarazel.de> (raw)
In-Reply-To: <tip-909890355507e92bdaf648e73870f6b5df606da8@git.kernel.org>

Hi,

Perhaps this should also go into stable? It'd be nice to fix that
regression for 4.4 and 4.5.

Regards,

Andres

On 2016-03-30 23:33:37 -0700, tip-bot for Andres Freund wrote:
> Commit-ID:  909890355507e92bdaf648e73870f6b5df606da8
> Gitweb:     http://git.kernel.org/tip/909890355507e92bdaf648e73870f6b5df606da8
> Author:     Andres Freund <andres@anarazel.de>
> AuthorDate: Wed, 30 Mar 2016 21:02:45 +0200
> Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
> CommitDate: Wed, 30 Mar 2016 18:08:39 -0300
> 
> perf hists: Fix determination of a callchain node's childlessness
> 
> The 4b3a3212233a ("perf hists browser: Support flat callchains") commit
> over-aggressively tried to optimize callchain_node__init_have_children().
> 
> That lead to --tui mode not allowing to expand call chain elements if a
> call chain element had only one parent. That's why --inverted callgraphs
> looked halfway sane, but plain ones didn't.
> 
> Revert that individual optimization, it wasn't really related to the
> rest of the commit.
> 
> Signed-off-by: Andres Freund <andres@anarazel.de>
> Acked-by: Namhyung Kim <namhyung@kernel.org>
> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
> Fixes: 4b3a3212233a ("perf hists browser: Support flat callchains")
> Link: http://lkml.kernel.org/r/20160330190245.GB13305@awork2.anarazel.de
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> ---
>  tools/perf/ui/browsers/hists.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
> index 4b98165..2a83414 100644
> --- a/tools/perf/ui/browsers/hists.c
> +++ b/tools/perf/ui/browsers/hists.c
> @@ -337,7 +337,7 @@ static void callchain_node__init_have_children(struct callchain_node *node,
>  	chain = list_entry(node->val.next, struct callchain_list, list);
>  	chain->has_children = has_sibling;
>  
> -	if (node->val.next != node->val.prev) {
> +	if (!list_empty(&node->val)) {
>  		chain = list_entry(node->val.prev, struct callchain_list, list);
>  		chain->has_children = !RB_EMPTY_ROOT(&node->rb_root);
>  	}

  reply	other threads:[~2016-04-16 19:46 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-30 12:34 "perf hists browser: Support flat callchains" appears to have broken parent reporting Andres Freund
2016-03-30 13:46 ` Arnaldo Carvalho de Melo
2016-03-30 14:19   ` Andres Freund
2016-03-30 16:00     ` Namhyung Kim
2016-03-30 19:02       ` Andres Freund
2016-03-31  6:33         ` [tip:perf/urgent] perf hists: Fix determination of a callchain node's childlessness tip-bot for Andres Freund
2016-04-16 19:46           ` Andres Freund [this message]
2016-04-18 14:07             ` Arnaldo Carvalho de Melo
2016-04-18 14:25           ` Andres Freund
2016-05-02 22:17             ` Greg KH
2016-05-02 22:25               ` Andres Freund
2016-05-02 23:24                 ` Greg KH
2016-05-02 23:34                   ` Andres Freund
2016-03-30 21:07       ` "perf hists browser: Support flat callchains" appears to have broken parent reporting Arnaldo Carvalho de Melo

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=20160416194614.l6liupm35rmhg3ht@alap3.anarazel.de \
    --to=andres@anarazel.de \
    --cc=a.p.zijlstra@chello.nl \
    --cc=acme@redhat.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=namhyung@kernel.org \
    --cc=tglx@linutronix.de \
    /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;
as well as URLs for NNTP newsgroup(s).