[fpc-devel] improvement SSE and string+char
DarekM
darekm at emadar.com
Sun Dec 9 20:56:01 CET 2007
Florian Klaempfl pisze:
> DarekM schrieb:
>
>> Hi
>> I've notice two improvement
>> 1. equation in SSE
>>
>> # Var Zr located in register mreg0md
>> # Var Zi located in register mreg1md
>> # Var Ti located in register mreg3md
>> # Var Tr located in register mreg2md
>> # [39] Tr := Zr * Zr;
>> movsd %xmm0,%xmm4
>> mulsd %xmm0,%xmm4
>> movsd %xmm4,%xmm2
>>
>> it can be changed to:
>> # [39] Tr := Zr * Zr;
>> movsd %xmm0,%xmm2
>> mulsd %xmm0,%xmm2
>>
>
> Yes, but it's not easy to implement ;)
>
I think so, but its worth of effort. That are very popular equation
(the same with A=B+C) . And second: can cpu then make own
optimalizations (next line use different registers).
my stupid suggest:
after translate of equation test of last line:
movsd %xmmA,%xmmB
if %xmmB is not use before change every %xmmA to %xmmB and remove last line.
but sorry it I don't understand some of it.
Darek
More information about the fpc-devel
mailing list