All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Garry <john.garry@huawei.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: <jolsa@kernel.org>, <peterz@infradead.org>, <mingo@redhat.com>,
	<alexander.shishkin@linux.intel.com>,
	<Linux-kernel@vger.kernel.org>,
	<linux-perf-users@vger.kernel.org>, <ak@linux.intel.com>,
	<kan.liang@intel.com>, "irogers@google.com" <irogers@google.com>
Subject: Re: [PATCH v2] perf list: Display hybrid pmu events with cpu type
Date: Wed, 15 Dec 2021 17:34:32 +0000	[thread overview]
Message-ID: <2bf7048d-2c20-8d3f-1b37-18a4056490a3@huawei.com> (raw)
In-Reply-To: <be6e0b56-ba29-a2ee-c153-d5aec102b587@huawei.com>

On 15/12/2021 16:18, John Garry wrote:

- yao.jin@linux.intel.com, yao.jin@intel.com

Both these author addresses bounce for me :(

And it's not just my arm64 platform which is damaged, but also my x86 
broadwell machine - uncore aliasing for perf list is broken

Before snippet:
unc_cbo_cache_lookup.any_es
[Unit: uncore_cbox L3 Lookup any request that access cache and found 
line in E or S-state]
unc_cbo_cache_lookup.any_i
[Unit: uncore_cbox L3 Lookup any request that access cache and found 
line in I-state]

After snippet:
unc_cbo_cache_lookup.any_es
[Unit: uncore_cbox L3 Lookup any request that access cache and found 
line in E or S-state]
unc_cbo_cache_lookup.any_es
[Unit: uncore_cbox L3 Lookup any request that access cache and found 
line in E or S-state]
unc_cbo_cache_lookup.any_i
[Unit: uncore_cbox L3 Lookup any request that access cache and found 
line in I-state]
unc_cbo_cache_lookup.any_i
[Unit: uncore_cbox L3 Lookup any request that access cache and found 
line in I-state]

Notice how the events are repeated (twice, for each cbox PMU) after, 
when they should not be.

This seems to be the broken code added in print_pmu_events():

 > qsort(aliases, len, sizeof(struct sevent), cmp_sevent);
 > for (j = 0; j < len; j++) {
 > /* Skip duplicates */
 > - if (j > 0 && !strcmp(aliases[j].name, aliases[j - 1].name))
 > - continue;
 > + if (j > 0 && !strcmp(aliases[j].name, aliases[j - 1].name)) {
 > + if (!aliases[j].pmu || !aliases[j - 1].pmu ||
 > + !strcmp(aliases[j].pmu, aliases[j - 1].pmu)) {
 > + continue;
 > + }
 > + }

Anyone an idea on the !strcmp(aliases[j].pmu, aliases[j - 1].pmu) check 
or how to fix it?

Thanks,
John

      reply	other threads:[~2021-12-15 17:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-03  2:52 [PATCH v2] perf list: Display hybrid pmu events with cpu type Jin Yao
2021-09-09 22:37 ` Ian Rogers
2021-09-09 22:56   ` Andi Kleen
2021-09-10  0:39     ` Jin, Yao
2021-10-19 21:14 ` Arnaldo Carvalho de Melo
2021-12-15 16:18   ` John Garry
2021-12-15 17:34     ` John Garry [this message]

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=2bf7048d-2c20-8d3f-1b37-18a4056490a3@huawei.com \
    --to=john.garry@huawei.com \
    --cc=Linux-kernel@vger.kernel.org \
    --cc=acme@kernel.org \
    --cc=ak@linux.intel.com \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=irogers@google.com \
    --cc=jolsa@kernel.org \
    --cc=kan.liang@intel.com \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mingo@redhat.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.