From: TAKANO Mitsuhiro <takano32@gmail.com>
To: James Clark <james.clark@linaro.org>
Cc: linux-perf-users@vger.kernel.org,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Namhyung Kim <namhyung@kernel.org>,
Ian Rogers <irogers@google.com>,
John Garry <john.garry@linux.dev>,
Ilkka Koskinen <ilkka@os.amperecomputing.com>,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] perf vendor events arm64 AmpereOneX: Fix misspelled PublicDescription keys
Date: Fri, 13 Nov 2026 06:40:27 +0000 [thread overview]
Message-ID: <179455202729.738309.5850348519213838978@gmail.com> (raw)
In-Reply-To: <1e5907fc-40c6-4025-8d27-a92b3cb2845a@linaro.org>
On 2026-11-11 14:03, James Clark wrote:
> The linked patches seem like a bigger change than what I'd expect. I'm
> not sure that's necessary for something conceptually as simple as
> "validate the json files".
Agreed, and that version is gone. What is posted now is one patch: the
list of keys a table may carry, and a walk that reports the ones it does
not. No schema, no similarity, no metric-name check, nothing wired into
the build.
https://lore.kernel.org/linux-perf-users/20261113032927.634183-1-takano32@gmail.com/
> I'm also a bit lost about the relationship between "[PATCH 0/3] perf
> jevents: Report the JSON keys that jevents.py never reads" and "[PATCH]
> perf jevents: Check the JSON keys that jevents.py never reads".
The 0/3 was the first posting, and it had collected two unrelated changes
on the way - a report for a metric expression with no event behind it, and
making the arch argument optional. Both are dropped. Since v7 it is a
single patch, and the only thing it does is the key check.
> Even without jsonschema I can't see why a validator can't be written in
> less than 10 lines.
It can, and that is what v10 is. The check itself is
for path in sorted(Path(root).rglob('*.json')):
if path.name.endswith('metricgroups.json'):
continue
for obj in json.loads(path.read_text(encoding='utf-8')):
if extra := set(obj) - _TABLE_KEYS:
print(f'{path}: {sorted(extra)}')
bad += 1
plus a directory check, the 51-word list, and a shell test that feeds it a
known key and a bad one. On today's tree it reports 19 keys in four
tables.
My earlier answer to this went into the other thread by mistake (wrong
In-Reply-To), which is why this one looked unanswered.
This thread is the data half: the 16 keys in ampereonex/mmu.json and the 3
in the AMD tables are still in the tree, so the check reports them today.
I can post the corrected table as a v2 whenever you want it - the check is
not a prerequisite for it.
Written with Hermes Agent, an LLM assistant; the author reviewed it and ran
the checks it describes.
next prev parent reply other threads:[~2026-11-13 6:40 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-08 18:38 [PATCH] perf vendor events arm64 AmpereOneX: Fix misspelled PublicDescription keys TAKANO Mitsuhiro
2026-11-09 10:24 ` James Clark
2026-11-10 19:42 ` TAKANO Mitsuhiro
2026-11-11 10:16 ` James Clark
2026-11-11 13:35 ` TAKANO Mitsuhiro
2026-11-11 14:03 ` James Clark
2026-11-13 6:40 ` TAKANO Mitsuhiro [this message]
2026-11-13 6:52 ` [PATCH v2] " TAKANO Mitsuhiro
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=179455202729.738309.5850348519213838978@gmail.com \
--to=takano32@gmail.com \
--cc=acme@kernel.org \
--cc=ilkka@os.amperecomputing.com \
--cc=irogers@google.com \
--cc=james.clark@linaro.org \
--cc=john.garry@linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=namhyung@kernel.org \
/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