From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Dapeng Mi <dapeng1.mi@linux.intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Namhyung Kim <namhyung@kernel.org>,
Ian Rogers <irogers@google.com>,
Adrian Hunter <adrian.hunter@intel.com>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
John Garry <john.g.garry@oracle.com>,
Will Deacon <will@kernel.org>,
James Clark <james.clark@linaro.org>,
Mike Leach <mike.leach@linaro.org>, Guo Ren <guoren@kernel.org>,
Paul Walmsley <pjw@kernel.org>,
Palmer Dabbelt <palmer@dabbelt.com>,
Albert Ou <aou@eecs.berkeley.edu>,
Alexandre Ghiti <alex@ghiti.fr>,
linux-perf-users@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, linux-csky@vger.kernel.org,
linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org,
Zide Chen <zide.chen@intel.com>,
Falcon Thomas <thomas.falcon@intel.com>,
Dapeng Mi <dapeng1.mi@intel.com>,
Xudong Hao <xudong.hao@intel.com>
Subject: Re: [Patch v3 0/4] Perf tools: perf-regs bug fix and optimization
Date: Fri, 6 Feb 2026 12:17:23 -0300 [thread overview]
Message-ID: <aYYGA_Mo1ppwdTH0@x1> (raw)
In-Reply-To: <20260203024356.444942-1-dapeng1.mi@linux.intel.com>
On Tue, Feb 03, 2026 at 10:43:52AM +0800, Dapeng Mi wrote:
> Changes:
> v2 -> v3:
> * Fix the abort issue for "-I" or "--user-regs" options. (Patch 1/4)
> * Address Ian's comments.
Fixed up somme fuzz with powerpc, x86, riscv and s390 Build files wrt
removing perf_regs.o
Thanks, applied to perf-tools-next,
- Arnaldo
> v1 -> v2:
> * Fixing "PERF_REG_EXTENDED_MASK" redefinition building error by
> changing the "asm/perf_regs.h" header path to relative UAPI path.
> (Patch 1/3)
> * Spliting xxx_reg_mask() and xxx_sdt_arg_parse_op() conversion into 2
> patches.
>
> This patch-set remove the below three architecture specific __weak
> functions and converted them into the general architecture specific
> functions which are dispatched base on "em_machine".
>
> uint64_t arch__intr_reg_mask(void);
> uint64_t arch__user_reg_mask(void);
> int arch_sdt_arg_parse_op(char *old_op, char **new_op);
>
> The advantage of this conversion is that these architectural functions
> can be called even for a different architecture with host instead of
> only called on the host architecture.
>
> Although the converted functions shown below can be called on any
> architecture, currently they are still only called for the host
> architecture (EM_HOST).
>
> int perf_sdt_arg_parse_op(uint16_t e_machine, char *old_op, char **new_op);
> uint64_t perf_intr_reg_mask(uint16_t e_machine);
> uint64_t perf_user_reg_mask(uint16_t e_machine);
>
> Tests:
> * This patch-set is only tested on x86 platforms. No issues are found
> for both intr-regs and user-regs options.
> * Tests on other architectures are welcomed and appreciated.
>
> History:
> v1: https://lore.kernel.org/all/20260123090938.2222960-1-dapeng1.mi@linux.intel.com/
> v2: https://lore.kernel.org/all/20260127070259.2720468-1-dapeng1.mi@linux.intel.com/
>
> Dapeng Mi (4):
> perf regs: Fix abort for "-I" or "--user-regs" options
> perf arch: Update arch headers to use relative UAPI paths
> perf regs: Remove __weak attributive arch__xxx_reg_mask() functions
> perf regs: Remove __weak attributive arch_sdt_arg_parse_op() function
>
> tools/perf/arch/arm/include/perf_regs.h | 2 +-
> tools/perf/arch/arm/util/Build | 2 -
> tools/perf/arch/arm/util/perf_regs.c | 13 -
> tools/perf/arch/arm64/include/perf_regs.h | 2 +-
> tools/perf/arch/arm64/util/Build | 1 -
> tools/perf/arch/arm64/util/perf_regs.c | 141 ---------
> tools/perf/arch/csky/Build | 1 -
> tools/perf/arch/csky/include/perf_regs.h | 2 +-
> tools/perf/arch/csky/util/Build | 1 -
> tools/perf/arch/csky/util/perf_regs.c | 13 -
> tools/perf/arch/loongarch/include/perf_regs.h | 2 +-
> tools/perf/arch/loongarch/util/Build | 1 -
> tools/perf/arch/loongarch/util/perf_regs.c | 13 -
> tools/perf/arch/mips/include/perf_regs.h | 2 +-
> tools/perf/arch/mips/util/Build | 1 -
> tools/perf/arch/mips/util/perf_regs.c | 13 -
> tools/perf/arch/powerpc/include/perf_regs.h | 2 +-
> tools/perf/arch/powerpc/util/Build | 1 -
> tools/perf/arch/powerpc/util/perf_regs.c | 172 -----------
> tools/perf/arch/riscv/include/perf_regs.h | 9 +-
> tools/perf/arch/riscv/util/Build | 1 -
> tools/perf/arch/riscv/util/perf_regs.c | 13 -
> tools/perf/arch/s390/include/perf_regs.h | 2 +-
> tools/perf/arch/s390/util/Build | 1 -
> tools/perf/arch/s390/util/perf_regs.c | 13 -
> tools/perf/arch/x86/include/perf_regs.h | 2 +-
> tools/perf/arch/x86/util/Build | 1 -
> tools/perf/arch/x86/util/perf_regs.c | 283 ------------------
> tools/perf/util/evsel.c | 4 +-
> tools/perf/util/parse-regs-options.c | 13 +-
> .../util/perf-regs-arch/perf_regs_aarch64.c | 139 ++++++++-
> .../perf/util/perf-regs-arch/perf_regs_arm.c | 7 +-
> .../perf/util/perf-regs-arch/perf_regs_csky.c | 7 +-
> .../util/perf-regs-arch/perf_regs_loongarch.c | 7 +-
> .../perf/util/perf-regs-arch/perf_regs_mips.c | 7 +-
> .../util/perf-regs-arch/perf_regs_powerpc.c | 183 ++++++++++-
> .../util/perf-regs-arch/perf_regs_riscv.c | 7 +-
> .../perf/util/perf-regs-arch/perf_regs_s390.c | 7 +-
> .../perf/util/perf-regs-arch/perf_regs_x86.c | 281 ++++++++++++++++-
> tools/perf/util/perf_regs.c | 109 ++++++-
> tools/perf/util/perf_regs.h | 27 +-
> tools/perf/util/probe-file.c | 3 +-
> 42 files changed, 787 insertions(+), 724 deletions(-)
> delete mode 100644 tools/perf/arch/arm/util/perf_regs.c
> delete mode 100644 tools/perf/arch/arm64/util/perf_regs.c
> delete mode 100644 tools/perf/arch/csky/Build
> delete mode 100644 tools/perf/arch/csky/util/Build
> delete mode 100644 tools/perf/arch/csky/util/perf_regs.c
> delete mode 100644 tools/perf/arch/loongarch/util/perf_regs.c
> delete mode 100644 tools/perf/arch/mips/util/perf_regs.c
> delete mode 100644 tools/perf/arch/powerpc/util/perf_regs.c
> delete mode 100644 tools/perf/arch/riscv/util/perf_regs.c
> delete mode 100644 tools/perf/arch/s390/util/perf_regs.c
> delete mode 100644 tools/perf/arch/x86/util/perf_regs.c
>
> --
> 2.34.1
>
next prev parent reply other threads:[~2026-02-06 15:17 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-03 2:43 [Patch v3 0/4] Perf tools: perf-regs bug fix and optimization Dapeng Mi
2026-02-03 2:43 ` [Patch v3 1/4] perf regs: Fix abort for "-I" or "--user-regs" options Dapeng Mi
2026-02-03 23:06 ` Ian Rogers
2026-02-03 2:43 ` [Patch v3 2/4] perf arch: Update arch headers to use relative UAPI paths Dapeng Mi
2026-02-03 2:43 ` [Patch v3 3/4] perf regs: Remove __weak attributive arch__xxx_reg_mask() functions Dapeng Mi
2026-02-03 23:08 ` Ian Rogers
2026-02-03 2:43 ` [Patch v3 4/4] perf regs: Remove __weak attributive arch_sdt_arg_parse_op() function Dapeng Mi
2026-02-03 23:11 ` Ian Rogers
2026-02-06 15:17 ` Arnaldo Carvalho de Melo [this message]
2026-02-09 0:46 ` [Patch v3 0/4] Perf tools: perf-regs bug fix and optimization Mi, Dapeng
2026-03-24 6:07 ` patchwork-bot+linux-riscv
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=aYYGA_Mo1ppwdTH0@x1 \
--to=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alex@ghiti.fr \
--cc=alexander.shishkin@linux.intel.com \
--cc=aou@eecs.berkeley.edu \
--cc=dapeng1.mi@intel.com \
--cc=dapeng1.mi@linux.intel.com \
--cc=guoren@kernel.org \
--cc=irogers@google.com \
--cc=james.clark@linaro.org \
--cc=john.g.garry@oracle.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-csky@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=mike.leach@linaro.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=palmer@dabbelt.com \
--cc=peterz@infradead.org \
--cc=pjw@kernel.org \
--cc=thomas.falcon@intel.com \
--cc=will@kernel.org \
--cc=xudong.hao@intel.com \
--cc=zide.chen@intel.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