All of lore.kernel.org
 help / color / mirror / Atom feed
From: Leo Yan <leo.yan@arm.com>
To: James Clark <james.clark@linaro.org>
Cc: Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@redhat.com>,
	Arnaldo Carvalho de Melo <acme@kernel.org>,
	Namhyung Kim <namhyung@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Alexander Shishkin <alexander.shishkin@linux.intel.com>,
	Jiri Olsa <jolsa@kernel.org>, Ian Rogers <irogers@google.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Robin Murphy <robin.murphy@arm.com>,
	linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/3] perf list: Collapse similar events across PMUs
Date: Wed, 5 Mar 2025 09:35:45 +0000	[thread overview]
Message-ID: <20250305093545.GD13418@e132581.arm.com> (raw)
In-Reply-To: <20250304-james-perf-hybrid-list-v1-2-a363ffac283c@linaro.org>

On Tue, Mar 04, 2025 at 01:49:14PM +0000, James Clark wrote:
> Instead of showing multiple line items with the same event name and
> description, show a single line and concatenate all PMUs that this
> event can belong to.
> 
> Don't do it for json output. Machine readable output doesn't need to be
> minimized, and changing the "Unit" field to a list type would break
> backwards compatibility.
> 
> Before:
>  $ perf list -v
>  ...
>  br_indirect_spec
>        [Branch speculatively executed,indirect branch. Unit: armv8_cortex_a53]
>  br_indirect_spec
>        [Branch speculatively executed,indirect branch. Unit: armv8_cortex_a57]
> 
> After:
> 
>  $ perf list -v
>  ...
>  br_indirect_spec
>        [Branch speculatively executed,indirect branch. Unit: armv8_cortex_a53,armv8_cortex_a57]

From my testing, based on the latest tmp.perf-tools-next branch, I
need to remove the option '-v'.  Otherwise, the '-v' option will
enable long event descriptions, in this case, it does _not_ print Unit
strings at all (see default_print_event() in builtin-list.c).

  default_print_event()
  {
    ...
    if (long_desc && print_state->long_desc) {
            fprintf(fp, "%*s", 8, "[");
            wordwrap(fp, long_desc, 8, pager_get_columns(), 0);
            fprintf(fp, "]\n");
    } else if (desc && print_state->desc) {
    ...
  }

The command `perf list` would be sufficent.

Thanks,
Leo

  reply	other threads:[~2025-03-05  9:35 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-04 13:49 [PATCH 0/3] perf list: Collapse similar events across PMUs James Clark
2025-03-04 13:49 ` [PATCH 1/3] perf list: Order events by event name before PMU name James Clark
2025-03-05 20:59   ` Ian Rogers
2025-03-04 13:49 ` [PATCH 2/3] perf list: Collapse similar events across PMUs James Clark
2025-03-05  9:35   ` Leo Yan [this message]
2025-03-05  9:49     ` Leo Yan
2025-03-05 21:40   ` Ian Rogers
2025-03-07 14:08     ` James Clark
2025-03-07 17:35       ` Ian Rogers
2025-03-10 10:04         ` James Clark
2025-03-11 14:13         ` James Clark
2025-03-11 15:14           ` Ian Rogers
2025-03-11 16:41             ` James Clark
2025-03-04 13:49 ` [PATCH 3/3] perf list: Don't deduplicate core PMUs when listing events James Clark
2025-03-05 21:51   ` Ian Rogers
2025-03-07 14:08     ` James Clark
2025-03-05  9:26 ` [PATCH 0/3] perf list: Collapse similar events across PMUs Leo Yan
2025-03-05 20:38 ` Ian Rogers
2025-03-07 14:47   ` James Clark

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=20250305093545.GD13418@e132581.arm.com \
    --to=leo.yan@arm.com \
    --cc=acme@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=irogers@google.com \
    --cc=james.clark@linaro.org \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mingo@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=peterz@infradead.org \
    --cc=robin.murphy@arm.com \
    /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.