From: Max Chou <max.chou@sifive.com>
To: "Philippe Mathieu-Daudé" <philmd@oss.qualcomm.com>
Cc: qemu-devel@nongnu.org, qemu-riscv@nongnu.org,
Palmer Dabbelt <palmer@dabbelt.com>,
Alistair Francis <Alistair.Francis@wdc.com>,
Daniel Henrique Barboza <daniel.barboza@oss.qualcomm.com>,
Richard Henderson <richard.henderson@linaro.org>
Subject: Re: [PATCH 1/2] tcg/riscv64: Validate AUIPC relocation range
Date: Fri, 4 Sep 2026 15:56:32 +0800 [thread overview]
Message-ID: <app5b9gztbby1e0s@sifive.com> (raw)
In-Reply-To: <8e3baf27-9e44-4481-b60a-06e33678d473@oss.qualcomm.com>
On 2026-09-03 19:31, Philippe Mathieu-Daudé wrote:
> > +static bool reloc_call(tcg_insn_unit *src_rw, const tcg_insn_unit *target)
> > +{
> > + intptr_t hi, lo;
> > - if (offset == hi + lo) {
> > + if (split_auipc_offset(src_rw, target, &hi, &lo)) {
> > src_rw[0] |= encode_uimm20(hi);
> > src_rw[1] |= encode_imm12(lo);
>
> I'm a bit confused by these encode_*imm() taking uint32_t arguments,
> otherwise your change LGTM:
> Reviewed-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
>
Hi Philippe,
Thanks for the feedback.
I’ll address that data type mismatch and send out a v2.
rnax
next prev parent reply other threads:[~2026-09-04 7:57 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-03 17:04 [PATCH 0/2] tcg/riscv64: Fix AUIPC pair range validation Max Chou
2026-09-03 17:04 ` [PATCH 1/2] tcg/riscv64: Validate AUIPC relocation range Max Chou
2026-09-03 17:31 ` Philippe Mathieu-Daudé
2026-09-04 7:56 ` Max Chou [this message]
2026-09-03 17:04 ` [PATCH 2/2] tcg/riscv64: Fall back when AUIPC pairs are out of range Max Chou
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=app5b9gztbby1e0s@sifive.com \
--to=max.chou@sifive.com \
--cc=Alistair.Francis@wdc.com \
--cc=daniel.barboza@oss.qualcomm.com \
--cc=palmer@dabbelt.com \
--cc=philmd@oss.qualcomm.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-riscv@nongnu.org \
--cc=richard.henderson@linaro.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