qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 9/x] ppc: Convert op_add, op_addi to TCG


From: Aurelien Jarno
Subject: Re: [Qemu-devel] [PATCH 9/x] ppc: Convert op_add, op_addi to TCG
Date: Fri, 5 Sep 2008 19:49:08 +0200
User-agent: Mutt/1.5.18 (2008-05-17)

On Fri, Sep 05, 2008 at 07:17:10PM +0200, Andreas Färber wrote:
>
> Am 05.09.2008 um 16:18 schrieb Aurélien Jarno:
>
>>> --- a/target-ppc/translate.c
>>> +++ b/target-ppc/translate.c
>>> @@ -827,10 +827,14 @@ __GEN_INT_ARITH1_O_64(name##o, opc1, opc2,  
>>> opc3 |
>>> 0x10, type)
>>> #endif
>>>
>>> /* add    add.    addo    addo.    */
>>> +static always_inline void gen_op_add (void)
>>> +{
>>> +    tcg_gen_add_tl(cpu_T[0], cpu_T[0], cpu_T[1]);
>>> +}
>>
>> At some point, we will have to change this kind of function, otherwise
>> it will be really difficult to get rid of T0, T1 and T2.
>
> Right, same for subf. But for now, a function of this name is still  
> required here for the add instruction due to the GEN_INT_ARITH2 (or  
> similar) macro slightly below, which appears to set up these functions  
> as handlers for the family of instruction opcodes iiuc. To change those 
> macros, the whole family (or even more instructions) will need to be 
> converted first.
>
> For me, the use of global TCG variables should permit it to run on Mac  
> OS X Leopard with GCC 4.0.1 at some point, so even if it doesn't allow  
> optimizations right away, it has some mid-term benefits. For the other  
> occurrences of gen_op_add I already inlined it for future optimizations 
> but didn't spot opportunities to do that yet.
>
> I will be mostly offline starting this weekend but would likely continue 
> working on ppc. If anyone else plans to work on it, it would be nice to 
> coordinate that in advance to avoid conflicting patches.

I plan to work on memory loads/stores during the week-end. Note that I'll be
offline on Sunday.

-- 
  .''`.  Aurelien Jarno             | GPG: 1024D/F1BCDB73
 : :' :  Debian developer           | Electrical Engineer
 `. `'   address@hidden         | address@hidden
   `-    people.debian.org/~aurel32 | www.aurel32.net




reply via email to

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