[fpc-devel] improvement SSE and string+char

DarekM darekm at emadar.com
Sun Dec 9 20:17:59 CET 2007

 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

2. concatenation  shortstring and char should not translate char to 
string, but only test length of string and if can add 1 char at then end.

I've use  FPC 2.2


More information about the fpc-devel mailing list