From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Eric Lin <eric.lin@sifive.com>
Cc: peterz@infradead.org, mingo@redhat.com, mark.rutland@arm.com,
alexander.shishkin@linux.intel.com, jolsa@kernel.org,
namhyung@kernel.org, palmer@dabbelt.com, aou@eecs.berkeley.edu,
iii@linux.ibm.com, linux-perf-users@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org,
paul.walmsley@sifive.com, greentime.hu@sifive.com
Subject: Re: [PATCH 1/1] perf jitdump: Add riscv64 support.
Date: Sat, 9 Apr 2022 12:05:18 -0300 [thread overview]
Message-ID: <YlGgro3TupbOEnJC@kernel.org> (raw)
In-Reply-To: <20220406142606.18464-2-eric.lin@sifive.com>
Em Wed, Apr 06, 2022 at 10:26:06PM +0800, Eric Lin escreveu:
> Signed-off-by: Eric Lin <eric.lin@sifive.com>
Can you plese provide some series of commands demonstrating the usage of
this functionality on riscv?
A dump, for instance.
- Arnaldo
> ---
> tools/perf/arch/riscv/Makefile | 1 +
> tools/perf/util/genelf.h | 3 +++
> 2 files changed, 4 insertions(+)
>
> diff --git a/tools/perf/arch/riscv/Makefile b/tools/perf/arch/riscv/Makefile
> index 1aa9dd772489..a8d25d005207 100644
> --- a/tools/perf/arch/riscv/Makefile
> +++ b/tools/perf/arch/riscv/Makefile
> @@ -2,3 +2,4 @@ ifndef NO_DWARF
> PERF_HAVE_DWARF_REGS := 1
> endif
> PERF_HAVE_ARCH_REGS_QUERY_REGISTER_OFFSET := 1
> +PERF_HAVE_JITDUMP := 1
> diff --git a/tools/perf/util/genelf.h b/tools/perf/util/genelf.h
> index 3db3293213a9..ae138afe6c56 100644
> --- a/tools/perf/util/genelf.h
> +++ b/tools/perf/util/genelf.h
> @@ -38,6 +38,9 @@ int jit_add_debug_info(Elf *e, uint64_t code_addr, void *debug, int nr_debug_ent
> #elif defined(__s390x__)
> #define GEN_ELF_ARCH EM_S390
> #define GEN_ELF_CLASS ELFCLASS64
> +#elif defined(__riscv) && __riscv_xlen == 64
> +#define GEN_ELF_ARCH EM_RISCV
> +#define GEN_ELF_CLASS ELFCLASS64
> #else
> #error "unsupported architecture"
> #endif
> --
> 2.35.1
--
- Arnaldo
next prev parent reply other threads:[~2022-04-09 15:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-06 14:26 [PATCH 0/1] perf jitdump: Add riscv64 support Eric Lin
2022-04-06 14:26 ` [PATCH 1/1] " Eric Lin
2022-04-09 15:05 ` Arnaldo Carvalho de Melo [this message]
2022-04-10 15:15 ` Eric Lin
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=YlGgro3TupbOEnJC@kernel.org \
--to=acme@kernel.org \
--cc=alexander.shishkin@linux.intel.com \
--cc=aou@eecs.berkeley.edu \
--cc=eric.lin@sifive.com \
--cc=greentime.hu@sifive.com \
--cc=iii@linux.ibm.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=peterz@infradead.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;
as well as URLs for NNTP newsgroup(s).