qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v6 3/6] target: [tcg] Add generic translation fr


From: Emilio G. Cota
Subject: Re: [Qemu-devel] [PATCH v6 3/6] target: [tcg] Add generic translation framework
Date: Thu, 15 Jun 2017 19:25:07 -0400
User-agent: Mutt/1.5.24 (2015-08-30)

On Thu, Jun 15, 2017 at 18:19:11 -0400, Emilio G. Cota wrote:
> (snip)
> > +/**
> > + * DisasContextBase:
> > + * @tb: Translation block for this disassembly.
> > + * @pc_first: Address of first guest instruction in this TB.
> > + * @pc_next: Address of next guest instruction in this TB (current during
> > + *           disassembly).
> > + * @num_insns: Number of translated instructions (including current).
> > + * @singlestep_enabled: "Hardware" single stepping enabled.
> > + *
> > + * Architecture-agnostic disassembly context.
> > + */
> > +typedef struct DisasContextBase {
> > +    TranslationBlock *tb;
> > +    target_ulong pc_first;
> > +    target_ulong pc_next;
> > +    DisasJumpType jmp_type;
> > +    unsigned int num_insns;
> > +    bool singlestep_enabled;
> > +} DisasContextBase;
> 
> - @pc_next: I'd stick with @pc, it's shorter, it's everywhere already, and
>   with the documentation it's very clear what it is for.
> - @jmp_type: missing doc :-)

Also, consider keeping the @is_jmp name instead of renaming it to
@jmp_type. (@jmp would be shorter but it would be confusing though,
e.g. cris has both dc->jmp and dc->is_jmp.)

                E.



reply via email to

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