qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Richard Henderson <richard.henderson@linaro.org>, qemu-devel@nongnu.org
Cc: peter.maydell@linaro.org, Jorgen.Hansen@wdc.com,
	Jonathan.Cameron@huawei.com, linux-cxl@vger.kernel.org
Subject: Re: [PATCH 5/9] target/i386: Preserve DisasContextBase.insn_start across rewind
Date: Tue, 9 Apr 2024 17:28:16 +0200	[thread overview]
Message-ID: <99e4fb4a-6248-46fa-8e6e-ed767c3f771e@linaro.org> (raw)
In-Reply-To: <c1cc9fac-f227-434e-a0b5-d4826f26c9a5@linaro.org>

On 9/4/24 17:23, Philippe Mathieu-Daudé wrote:
> On 7/4/24 00:32, Richard Henderson wrote:
>> When aborting translation of the current insn, restore the
>> previous value of insn_start.
>>
>> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
>> ---
>>   target/i386/tcg/translate.c | 3 +++
>>   1 file changed, 3 insertions(+)
> 
> 
>> @@ -3123,6 +3124,7 @@ static bool disas_insn(DisasContext *s, CPUState 
>> *cpu)
>>           /* END TODO */
>>           s->base.num_insns--;
>>           tcg_remove_ops_after(s->prev_insn_end);
>> +        s->base.insn_start = s->prev_insn_start;
>>           s->base.is_jmp = DISAS_TOO_MANY;
>>           return false;
>>       default:
>> @@ -6995,6 +6997,7 @@ static void i386_tr_insn_start(DisasContextBase 
>> *dcbase, CPUState *cpu)
>>       DisasContext *dc = container_of(dcbase, DisasContext, base);
>>       target_ulong pc_arg = dc->base.pc_next;
>> +    dc->prev_insn_start = dc->base.insn_start;
>>       dc->prev_insn_end = tcg_last_op();
>>       if (tb_cflags(dcbase->tb) & CF_PCREL) {
>>           pc_arg &= ~TARGET_PAGE_MASK;
> 
> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>

And:
Tested-by: Jørgen Hansen <Jorgen.Hansen@wdc.com>
(also to patches 1 & 2)

:)


  reply	other threads:[~2024-04-09 15:29 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-06 22:32 [PATCH for-9.0? 0/9] accel/tcg: Fix can_do_io vs 2nd page mmio Richard Henderson
2024-04-06 22:32 ` [PATCH 1/9] tcg: Add TCGContext.emit_before_op Richard Henderson
2024-04-08  6:13   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 2/9] accel/tcg: Add insn_start to DisasContextBase Richard Henderson
2024-04-08  6:18   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 3/9] target/arm: Use insn_start from DisasContextBase Richard Henderson
2024-04-08  6:16   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 4/9] target/hppa: " Richard Henderson
2024-04-08  6:17   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 5/9] target/i386: Preserve DisasContextBase.insn_start across rewind Richard Henderson
2024-04-09 15:23   ` Philippe Mathieu-Daudé
2024-04-09 15:28     ` Philippe Mathieu-Daudé [this message]
2024-04-06 22:32 ` [PATCH 6/9] target/microblaze: Use insn_start from DisasContextBase Richard Henderson
2024-04-08  6:17   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 7/9] target/riscv: " Richard Henderson
2024-04-08  6:17   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 8/9] target/s390x: " Richard Henderson
2024-04-08  6:18   ` Philippe Mathieu-Daudé
2024-04-06 22:32 ` [PATCH 9/9] accel/tcg: Improve can_do_io management Richard Henderson
2024-04-08  6:25   ` Philippe Mathieu-Daudé
2024-04-08 13:13   ` Jørgen Hansen
2024-04-09 23:03   ` Gregory Price

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=99e4fb4a-6248-46fa-8e6e-ed767c3f771e@linaro.org \
    --to=philmd@linaro.org \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=Jorgen.Hansen@wdc.com \
    --cc=linux-cxl@vger.kernel.org \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@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 NNTP newsgroup(s).