mbox series

[v4,0/5] perf arm-spe: Introduce metadata version 2

Message ID 20241003184302.190806-1-leo.yan@arm.com (mailing list archive)
Headers show
Series perf arm-spe: Introduce metadata version 2 | expand

Message

Leo Yan Oct. 3, 2024, 6:42 p.m. UTC
This patch series enhances Arm SPE metadata in the Perf file to a
version 2 format and maintains backward compatibility for metadata v1.

The version 2 metadata contains a global structure with fields for
metadata header version number, header size, CPU numbers. It also
expands to store per-CPU metadata, which includes the CPU logical
number in the kernel, MIDR, and capacity values associated with Arm SPE.

This patch set has been tested the perf to decode the Arm SPE metadata
v1 and v2.

Changes from v3:
- Fixed a compilation error (James)
- Added James' review tags.

Changes from v2:
- Added comment for arm_spe_find_cpus (Namhyung)
- Corrected resource releasing in arm_spe_save_cpu_header() and
  arm_spe_info_fill() (Namhyung)
- Changed to use calloc() for allocating metadata pointer array
  (Namhyung)

Changes from v1:
- Dropped LDS bit exposing from Arm SPE driver (Will Deacon).
- To simplify the change, this series did not include multiple AUX event
  support.

Leo Yan (5):
  perf arm-spe: Define metadata header version 2
  perf arm-spe: Calculate meta data size
  perf arm-spe: Save per CPU information in metadata
  perf arm-spe: Support metadata version 2
  perf arm-spe: Dump metadata with version 2

 tools/perf/arch/arm64/util/arm-spe.c | 122 ++++++++++++++++++++-
 tools/perf/util/arm-spe.c            | 155 +++++++++++++++++++++++++--
 tools/perf/util/arm-spe.h            |  38 ++++++-
 3 files changed, 299 insertions(+), 16 deletions(-)

Comments

Namhyung Kim Oct. 4, 2024, 7:29 p.m. UTC | #1
On Thu, 03 Oct 2024 19:42:57 +0100, Leo Yan wrote:

> This patch series enhances Arm SPE metadata in the Perf file to a
> version 2 format and maintains backward compatibility for metadata v1.
> 
> The version 2 metadata contains a global structure with fields for
> metadata header version number, header size, CPU numbers. It also
> expands to store per-CPU metadata, which includes the CPU logical
> number in the kernel, MIDR, and capacity values associated with Arm SPE.
> 
> [...]

Applied to perf-tools-next, thanks!

Best regards,
Namhyung