[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [update][PATCH 00/12] target-i386: remove some macros
From: |
Andreas Färber |
Subject: |
Re: [Qemu-devel] [update][PATCH 00/12] target-i386: remove some macros |
Date: |
Sun, 26 May 2013 17:55:33 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 |
Am 24.05.2013 13:37, schrieb Andreas Färber:
> Am 23.04.2013 10:16, schrieb liguang:
>> remove macros EAX, EBX, ECX, EDX, EBP, ESP, ESI, EDI, EIP, DF
>> as suggested by Richard Henderson <address@hidden>
>>
>> Li Guang (12)
>> target-i386/helper: remove EAX macro
>> target-i386/helper: remove EBX macro
>> target-i386/helper: remove ECX macro
>> target-i386/helper: remove EDX macro
>> target-i386/helper: remove EBP macro
>> target-i386/helper: remove ESP macro
>> target-i386/helper: remove ESI macro
>> target-i386/helper: remove EDI macro
>> target-i386/helper: remove EIP macro
>> target-i386/helper: remove DF macro
>> target-i386/helper: remove redundant env->eip assignment
>> target-i386: fix over 80 chars warnings
>
> Hard Freeze is over, so more time to look into refactorings:
>
> There's one thing to be aware of here, macros would make it easier to
> transition from CPUX86State to X86CPU fields. However I am guessing that
> all these registers are accessed by TCG code via offsets from cpu_env -
> please verify that.
Confirmed, I just stumbled over it myself in translate.c:
* all but EIP and DF are assigned to cpu_regs[]
* EIP is manually stored with offsetof() twice
* DF is manually loaded/stored with offsetof() thrice
Andreas
> If so,
>
> Reviewed-by: Andreas Färber <address@hidden>
>
> However, it would be nice if you could fix the \ alignment in patch
> 06/12 or in the cleanup patch 12/12.
>
> Regards,
> Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg