qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Re: MacOSX CVS build broken


From: Johannes Schindelin
Subject: Re: [Qemu-devel] Re: MacOSX CVS build broken
Date: Sat, 22 Jan 2005 00:09:24 +0100 (CET)

Hi,

On Fri, 21 Jan 2005, Ronald wrote:

> If I objdump -D op.o, the asm code for op_pmaddwd_mmx is like this
>
> 0000d984 <op_pmaddwd_mmx>:
>     d984:       3d 20 00 00     lis     r9,0
>     d988:       3d 60 00 00     lis     r11,0
>     d98c:       39 29 00 00     addi    r9,r9,0
>     d990:       39 6b 00 00     addi    r11,r11,0
>     d994:       7d 1b 4a 14     add     r8,r27,r9
>     d998:       7c 9b 5a 14     add     r4,r27,r11
>     d99c:       38 a0 00 00     li      r5,0
>     d9a0:       38 e0 00 04     li      r7,4
>     d9a4:       38 c0 00 06     li      r6,6
>     d9a8:       7d 26 22 ae     lhax    r9,r6,r4
>     d9ac:       38 a5 00 01     addi    r5,r5,1
>     d9b0:       7d 46 42 ae     lhax    r10,r6,r8
>     d9b4:       2c 05 00 01     cmpwi   r5,1
>     d9b8:       7c 07 22 ae     lhax    r0,r7,r4
>     d9bc:       38 c6 ff fc     addi    r6,r6,-4
>     d9c0:       7d 67 42 ae     lhax    r11,r7,r8
>     d9c4:       7d 29 51 d6     mullw   r9,r9,r10
>     d9c8:       7c 00 59 d6     mullw   r0,r0,r11
>     d9cc:       7d 29 02 14     add     r9,r9,r0
>     d9d0:       7d 27 41 2e     stwx    r9,r7,r8
>     d9d4:       38 e7 ff fc     addi    r7,r7,-4
>     d9d8:       4d 81 00 20     bgtlr
>     d9dc:       4b ff ff cc     b       d9a8 <op_pmaddwd_mmx+0x24>
>
> this really don't end with blr, but if I have understood correctly
> what I have found about bgtlr, it should do what blr do with some
> condition on r0.

The problem: if bgtlr doesn't return, then "b d9a8" is executed, i.e. a
jump to d9a8. However, dyngen wants to strip away the "blr" in order to
chain op_* functions together (and so avoid the overhead of calling them
the normal way). This is not possible, thus your fix ain't one, sorry.

If my explanation is not coherent, please read my qemu-porting.html. It
should become clearer then.

Ciao,
Dscho




reply via email to

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