qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Question regarding self-modifying code.


From: farmdve
Subject: Re: [Qemu-devel] Question regarding self-modifying code.
Date: Thu, 14 Jan 2016 16:29:42 +0200

Again, sorry for the personal message, Peter, Google really is failing here, more so than me.

>> But in my case, an instruction did forward modify some code, but this if statement did not execute and QEMU executed the old code.

On 14 January 2016 at 16:28, farmdve <address@hidden> wrote:
But in my case, an instruction did forward modify some code, but this if statement did not execute and QEMU executed the old code.

On 14 January 2016 at 12:27, Peter Maydell <address@hidden> wrote:
On 14 January 2016 at 10:15, farmdve <address@hidden> wrote:
> Sorry about that. Somehow Google decided it should reply to you, rather than
> the mailing list. It was an honest mistake.
>
> Original question is below
>
>
> I am unable to get this part here if (!(tb_end <= start || tb_start >= end))
> in tb_invalidate_phys_page_range
>
> What would happen if code forward modifies itself, but that condition
> evaluates to true?

If that condition is true, then the TB we're looking at (as we
iterate through every TB we know about) is not in fact overlapping
with the page that the guest just modified, and so is not affected
by the write...

> Then this piece here won't get executed

...and so it is correct that we don't need to do anything for this TB.

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]