qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] exec: About DISAS_JUMP and DISAS_UPDATE


From: Peter Maydell
Subject: Re: [Qemu-devel] exec: About DISAS_JUMP and DISAS_UPDATE
Date: Thu, 22 Oct 2015 22:28:21 +0100

On 22 October 2015 at 19:28, Sergey Fedorov <address@hidden> wrote:
> Hi all,
>
> I am trying to understand what the difference should be between
> DISAS_JUMP and DISAS_UPDATE. Actually, these macros have comments in
> include/exec/exec-all.h which say that DISAS_JUMP should be used when
> only PC was modified dynamically whereas DISAS_UPDATE should be used
> when some other CPU state was (in addition to PC?) modified dynamically.
> In fact, every target except ARM AArch64 does not distinguish between
> them. As I can see ARM AArch64 seems to suppose that: (1) PC was not
> modified when DISAS_UPDATE is used and should be updated with dc->pc
> when finishing translation; (2) DISAS_JUMP can be used to indicate that
> a new PC value was set and it should be preserved when finishing
> translation.

As Richard says, (a) the semantics for these values are really
private to each translator (b) the general idea is how AArch64
uses them. I think the 32-bit ARM code does something a bit odd
because it has to handle conditional execution (some things we
might have otherwise done immediately in the decode function
get postponed to the end of the loop). Mostly I haven't messed
around too much with that bit of the code because it works
and it's kind of complicated to understand. But the AArch64
stuff we wrote from scratch so it does things in the straightforward
way.

-- PMM



reply via email to

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