From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Richard Henderson <richard.henderson@linaro.org>, qemu-devel@nongnu.org
Cc: qemu-riscv <qemu-riscv@nongnu.org>
Subject: Re: [PATCH v2 29/33] target/riscv: Use translator_ld* for everything
Date: Mon, 29 Apr 2024 12:55:08 +0200 [thread overview]
Message-ID: <b6b4cc3a-45e9-4516-9faa-942795ad9c36@linaro.org> (raw)
In-Reply-To: <20240424233131.988727-30-richard.henderson@linaro.org>
Cc'ing qemu-riscv@
On 25/4/24 01:31, Richard Henderson wrote:
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
> target/riscv/translate.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/target/riscv/translate.c b/target/riscv/translate.c
> index c999e942e1..2c27fd4ce1 100644
> --- a/target/riscv/translate.c
> +++ b/target/riscv/translate.c
> @@ -20,7 +20,6 @@
> #include "qemu/log.h"
> #include "cpu.h"
> #include "tcg/tcg-op.h"
> -#include "exec/cpu_ldst.h"
> #include "exec/exec-all.h"
> #include "exec/helper-proto.h"
> #include "exec/helper-gen.h"
> @@ -1082,7 +1081,7 @@ static uint32_t opcode_at(DisasContextBase *dcbase, target_ulong pc)
> CPUState *cpu = ctx->cs;
> CPURISCVState *env = cpu_env(cpu);
>
> - return cpu_ldl_code(env, pc);
> + return translator_ldl(env, &ctx->base, pc);
> }
>
> /* Include insn module translation function */
> @@ -1243,7 +1242,8 @@ static void riscv_tr_translate_insn(DisasContextBase *dcbase, CPUState *cpu)
> unsigned page_ofs = ctx->base.pc_next & ~TARGET_PAGE_MASK;
>
> if (page_ofs > TARGET_PAGE_SIZE - MAX_INSN_LEN) {
> - uint16_t next_insn = cpu_lduw_code(env, ctx->base.pc_next);
> + uint16_t next_insn =
> + translator_lduw(env, &ctx->base, ctx->base.pc_next);
> int len = insn_len(next_insn);
>
> if (!is_same_page(&ctx->base, ctx->base.pc_next + len - 1)) {
parent reply other threads:[~2024-04-29 10:56 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20240424233131.988727-30-richard.henderson@linaro.org>]
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=b6b4cc3a-45e9-4516-9faa-942795ad9c36@linaro.org \
--to=philmd@linaro.org \
--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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).