perf vendor events: Add Arm Neoverse V2 PMU events

Message ID 20221020134512.1345013-1-james.clark@arm.com
State New
Headers
Series perf vendor events: Add Arm Neoverse V2 PMU events |

Commit Message

James Clark Oct. 20, 2022, 1:45 p.m. UTC
  Rename the neoverse-n2 folder to make it clear that it includes V2, and
add V2 to mapfile.csv. V2 has the same events as N2, visible by running
the following command in the ARM-software/data github repo [1]:

  diff pmu/neoverse-v2.json pmu/neoverse-n2.json | grep code

Testing:

  $ perf test pmu

  10: PMU events                                           :
  10.1: PMU event table sanity                             : Ok
  10.2: PMU event map aliases                              : Ok
  10.3: Parsing of PMU event table metrics                 : Ok
  10.4: Parsing of PMU event table metrics with fake PMUs  : Ok

[1]: https://github.com/ARM-software/data

Signed-off-by: James Clark <james.clark@arm.com>
---
 .../arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/branch.json | 0
 .../arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/bus.json    | 0
 .../arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/cache.json  | 0
 .../arm64/arm/{neoverse-n2 => neoverse-n2-v2}/exception.json   | 0
 .../arm64/arm/{neoverse-n2 => neoverse-n2-v2}/instruction.json | 0
 .../arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/memory.json | 0
 .../arm64/arm/{neoverse-n2 => neoverse-n2-v2}/pipeline.json    | 0
 .../arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/spe.json    | 0
 .../arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/trace.json  | 0
 tools/perf/pmu-events/arch/arm64/mapfile.csv                   | 3 ++-
 10 files changed, 2 insertions(+), 1 deletion(-)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/branch.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/bus.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/cache.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/exception.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/instruction.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/memory.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/pipeline.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/spe.json (100%)
 rename tools/perf/pmu-events/arch/arm64/arm/{neoverse-n2 => neoverse-n2-v2}/trace.json (100%)
  

Comments

John Garry Oct. 21, 2022, 10:47 a.m. UTC | #1
On 20/10/2022 14:45, James Clark wrote:
> Rename the neoverse-n2 folder to make it clear that it includes V2, and
> add V2 to mapfile.csv. V2 has the same events as N2, visible by running
> the following command in the ARM-software/data github repo [1]:
> 
>    diff pmu/neoverse-v2.json pmu/neoverse-n2.json | grep code
> 
> Testing:
> 
>    $ perf test pmu
> 
>    10: PMU events                                           :
>    10.1: PMU event table sanity                             : Ok
>    10.2: PMU event map aliases                              : Ok
>    10.3: Parsing of PMU event table metrics                 : Ok
>    10.4: Parsing of PMU event table metrics with fake PMUs  : Ok
> 
> [1]:https://github.com/ARM-software/data
> 
> Signed-off-by: James Clark<james.clark@arm.com>
> ---

This looks ok. Out of curiosity, do you know how the naming works for 
these neoverse cores? Were "n" a predecessor to "v"?

thanks,
John
  
James Clark Oct. 21, 2022, 10:59 a.m. UTC | #2
On 21/10/2022 11:47, John Garry wrote:
> On 20/10/2022 14:45, James Clark wrote:
>> Rename the neoverse-n2 folder to make it clear that it includes V2, and
>> add V2 to mapfile.csv. V2 has the same events as N2, visible by running
>> the following command in the ARM-software/data github repo [1]:
>>
>>    diff pmu/neoverse-v2.json pmu/neoverse-n2.json | grep code
>>
>> Testing:
>>
>>    $ perf test pmu
>>
>>    10: PMU events                                           :
>>    10.1: PMU event table sanity                             : Ok
>>    10.2: PMU event map aliases                              : Ok
>>    10.3: Parsing of PMU event table metrics                 : Ok
>>    10.4: Parsing of PMU event table metrics with fake PMUs  : Ok
>>
>> [1]:https://github.com/ARM-software/data
>>
>> Signed-off-by: James Clark<james.clark@arm.com>
>> ---
> 
> This looks ok. Out of curiosity, do you know how the naming works for
> these neoverse cores? Were "n" a predecessor to "v"?

Thanks for the review. No, they're more like different product lines
than predecessors. From the image on this article [1], N are focused on
performance per watt and V are high performance.

[1]:
https://www.arm.com/company/news/2022/09/redefining-the-global-computing-infrastructure-with-next-generation-arm-neoverse-platforms

> 
> thanks,
> John
  
Nick Forrington Nov. 10, 2022, 10:52 a.m. UTC | #3
On 20/10/2022 14:45, James Clark wrote:
> Rename the neoverse-n2 folder to make it clear that it includes V2, and
> add V2 to mapfile.csv. V2 has the same events as N2, visible by running
> the following command in the ARM-software/data github repo [1]:
>
>    diff pmu/neoverse-v2.json pmu/neoverse-n2.json | grep code
>
> Testing:
>
>    $ perf test pmu
>
>    10: PMU events                                           :
>    10.1: PMU event table sanity                             : Ok
>    10.2: PMU event map aliases                              : Ok
>    10.3: Parsing of PMU event table metrics                 : Ok
>    10.4: Parsing of PMU event table metrics with fake PMUs  : Ok
>
> [1]: https://github.com/ARM-software/data
>
> Signed-off-by: James Clark <james.clark@arm.com>
Reviewed-by: Nick Forrington <nick.forrington@arm.com>
  
Arnaldo Carvalho de Melo Nov. 10, 2022, 6:41 p.m. UTC | #4
Em Thu, Nov 10, 2022 at 10:52:44AM +0000, Nick Forrington escreveu:
> On 20/10/2022 14:45, James Clark wrote:
> > Rename the neoverse-n2 folder to make it clear that it includes V2, and
> > add V2 to mapfile.csv. V2 has the same events as N2, visible by running
> > the following command in the ARM-software/data github repo [1]:
> > 
> >    diff pmu/neoverse-v2.json pmu/neoverse-n2.json | grep code
> > 
> > Testing:
> > 
> >    $ perf test pmu
> > 
> >    10: PMU events                                           :
> >    10.1: PMU event table sanity                             : Ok
> >    10.2: PMU event map aliases                              : Ok
> >    10.3: Parsing of PMU event table metrics                 : Ok
> >    10.4: Parsing of PMU event table metrics with fake PMUs  : Ok
> > 
> > [1]: https://github.com/ARM-software/data
> > 
> > Signed-off-by: James Clark <james.clark@arm.com>
> Reviewed-by: Nick Forrington <nick.forrington@arm.com>

Thanks, applied.

- Arnaldo
  

Patch

diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/branch.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/branch.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/branch.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/branch.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/bus.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/bus.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/bus.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/bus.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/cache.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/cache.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/cache.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/cache.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/exception.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/exception.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/exception.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/exception.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/instruction.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/instruction.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/instruction.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/instruction.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/memory.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/memory.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/memory.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/memory.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/pipeline.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/pipeline.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/pipeline.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/pipeline.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/spe.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/spe.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/spe.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/spe.json
diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/trace.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/trace.json
similarity index 100%
rename from tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/trace.json
rename to tools/perf/pmu-events/arch/arm64/arm/neoverse-n2-v2/trace.json
diff --git a/tools/perf/pmu-events/arch/arm64/mapfile.csv b/tools/perf/pmu-events/arch/arm64/mapfile.csv
index ad502d00f460..f134e833c069 100644
--- a/tools/perf/pmu-events/arch/arm64/mapfile.csv
+++ b/tools/perf/pmu-events/arch/arm64/mapfile.csv
@@ -34,7 +34,8 @@ 
 0x00000000410fd460,v1,arm/cortex-a510,core
 0x00000000410fd470,v1,arm/cortex-a710,core
 0x00000000410fd480,v1,arm/cortex-x2,core
-0x00000000410fd490,v1,arm/neoverse-n2,core
+0x00000000410fd490,v1,arm/neoverse-n2-v2,core
+0x00000000410fd4f0,v1,arm/neoverse-n2-v2,core
 0x00000000420f5160,v1,cavium/thunderx2,core
 0x00000000430f0af0,v1,cavium/thunderx2,core
 0x00000000460f0010,v1,fujitsu/a64fx,core