public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Thomas Richter <tmricht@linux.ibm.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>,
	Andreas Krebbel <krebbel@linux.ibm.com>
Cc: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org,
	svens@linux.ibm.com, gor@linux.ibm.com, sumanthk@linux.ibm.com,
	hca@linux.ibm.com, Ingo Molnar <mingo@kernel.org>
Subject: Re: [PATCH v2] perf list: Add PMU pai_ext event description for IBM z16
Date: Tue, 15 Nov 2022 09:58:22 +0100	[thread overview]
Message-ID: <c1f8de28-1948-85b1-cd85-5bbd301e22bc@linux.ibm.com> (raw)
In-Reply-To: <Y3JnjmxPX+m7G9HL@kernel.org>

On 11/14/22 17:06, Arnaldo Carvalho de Melo wrote:
> Em Fri, Nov 11, 2022 at 02:54:02PM +0100, Thomas Richter escreveu:
>> Add the event description for the IBM z16 pai_ext PMU released with
>> commit c432fefe8e62 ("s390/pai: Add support for PAI Extension 1 NNPA counters")
>>
>> The document SA22-7832-13 "z/Architecture Principles of Operation",
>> published May, 2022, contains the description of the
>> Processor Activity Instrumentation Facility and the NNPA counter
>> set., See Pages 5-113 to 5-116.
>>
>> Signed-off-by: Thomas Richter <tmricht@linux.ibm.com>
>> ---
>>  .../pmu-events/arch/s390/cf_z16/pai_ext.json  | 198 ++++++++++++++++++
>>  tools/perf/pmu-events/jevents.py              |   1 +
>>  2 files changed, 199 insertions(+)
>>  create mode 100644 tools/perf/pmu-events/arch/s390/cf_z16/pai_ext.json
>>
>> diff --git a/tools/perf/pmu-events/arch/s390/cf_z16/pai_ext.json b/tools/perf/pmu-events/arch/s390/cf_z16/pai_ext.json
>> new file mode 100644
>> index 000000000000..8bee481f05d5
>> --- /dev/null
>> +++ b/tools/perf/pmu-events/arch/s390/cf_z16/pai_ext.json
>> @@ -0,0 +1,198 @@
>> +[
>> +	{
>> +		"Unit": "PAI-EXT",
>> +		"EventCode": "6144",
>> +		"EventName": "NNPA_ALL",
>> +		"BriefDescription": "NNPA ALL",
>> +		"PublicDescription": "Sum of all non zero NNPA counters"
>> +	},
> 
> Since the Brief description mentions NNPA, shouldn't the Public
> Description expand on this "NNPA" acronym?, something like:
> 
> Oops, can't expand on that since there isn't a link to that SA22-7832-13
> document.
> 
> Googling for it...
> 
> https://www-40.ibm.com/servers/resourcelink/svc03100.nsf/pages/zResourceLinkUrl?OpenDocument&url=http://www.ibm.com/servers/resourcelink/lib03010.nsf/0/B9DE5F05A9D57819852571C500428F9A/$file/SA22-7832-13.pdf
> 
> Ok, requires registration.
> 
> I wonder what is the value of these descriptions then :-\
> 
> I miss Ingo jumping into these discussions :-)
> 
> - Arnaldo

I added Andreas Krebbel to the discussion, he knows more than I on this counters.

NNPA stands for Neural Networks Processing Assist. This is a new feature in 
the IBM z16. Here is a quote from Document SG2489-51 IBM z16 (3931) Technical Guide:

<START-OF-QUOTE>
  "The new IBM z16 microprocessor chip, also called the IBM Telum processor, integrates a
   new AI accelerator. This innovation brings incredible value to applications and workloads that
   are running on IBM Z platform.
   Customers can benefit from the integrated AI accelerator by adding AI operations that are
   used to perform fraud prevention and fraud detection, customer behavior predictions, and
   supply chain operations. All of these operations are done in real time and fully integrated in
   transactional workloads. As a result, valuable insights are gained from their data instantly.

   ...
   The AI accelerator is driven by the new Neural Networks Processing Assist (NNPA)
   instruction.
   NNPA is a new nonprivileged Complex Instruction Set Computer (CISC) memory-to-memory
   instruction that operates on tensor objects that are in user program’s memory. AI functions
   and macros are abstracted by NNPA."
<END-OF-QUOTE>

This intension of this patch is to give a small hint on what these NNPA counters are
supposed to count and operate on. A full explanation is given in the document
SA22-7832-13 "z/Architecture Principles of Operation", Chapter 26, pp 26-1 to 26-115.

If you think this small description is not worth it, then we can drop the patch.

Thanks for you help and directions.

-- 
Thomas Richter, Dept 3303, IBM s390 Linux Development, Boeblingen, Germany
--
Vorsitzender des Aufsichtsrats: Gregor Pillen
Geschäftsführung: David Faller
Sitz der Gesellschaft: Böblingen / Registergericht: Amtsgericht Stuttgart, HRB 243294


  reply	other threads:[~2022-11-15  8:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-11 13:54 [PATCH v2] perf list: Add PMU pai_ext event description for IBM z16 Thomas Richter
2022-11-14 16:06 ` Arnaldo Carvalho de Melo
2022-11-15  8:58   ` Thomas Richter [this message]
2022-11-15 13:10     ` Arnaldo Carvalho de Melo
2022-11-15 16:34       ` Thomas Richter

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=c1f8de28-1948-85b1-cd85-5bbd301e22bc@linux.ibm.com \
    --to=tmricht@linux.ibm.com \
    --cc=acme@kernel.org \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=krebbel@linux.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=sumanthk@linux.ibm.com \
    --cc=svens@linux.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox