[PATCH v2 2/5] perf jevents: Match on highest version of Arm json file available

John Garry john.g.garry at oracle.com
Wed Jul 12 02:22:03 PDT 2023


On 11/07/2023 11:18, James Clark wrote:
>>> The highest valid version of json files should be used,
>> What exactly does that mean?
>>
>> So it seems that you have CPUs with matching MIDR except variant and
>> revision, but have different events, right?
> Yes. In this case we changed how a metric is calculated in N2-r0p3
> because the workaround that was needed for r0p0 is no longer needed
> (CPU_CYCLES should not subtracted from stalls for topdown metrics
> anymore).

If there are only very subtle differences, then could we solve with 
metric expression function? We already do something else like this for 
literal #slots for arm64

> But it would also support the case where the event list was
> slightly different between versions.

I am diff'ing folders ../arm64/arm/neoverse-n2r0p3-v2 and 
../arm64/arm/neoverse-n2r0p0, and all the events are the same - am I 
correct? It only seems like metric json is different.

> 
>> Then to solve that are you saying that the highest version of the JSONs
>> should used, upto and including the same CPU version (???) - correct?
> Yeah pretty much. It's highest version of JSONs starting from
> (including) the same CPU version, up to and not including the next
> version of JSON files provided. If only r0p0 is provided then all CPU
> versions match.
> 
> So if these JSONs were provided:
> 
>   r0p0  -  r0p4  -  r1p1
> 
> Would match these CPUs:
> 
>   CPU   |  JSON matched
>   ------|---------------
>   r0p0  |  r0p0
>   r0p3  |  r0p0
>   r0p4  |  r0p4
>   r1p0  |  r0p4
>   r1p1+ |  r1p1
> 
>> The cover letter doesn't mention anything relevant 🙁
>>
> Hopefully I expanded more in the v3 cover letter.

Thanks,
John




More information about the linux-arm-kernel mailing list