[fpc-devel]Bad heap manager?

Pavel V. Ozerski pavel at insect.mail.iephb.ru
Wed Feb 27 19:59:45 CET 2002


Hello All,

Today I tried to use FPC 1.1 (Win32 target) to compile my program which
creates very many dynamic objects and also I compiled the same program with
Delphi 6. Delphi-compiled program was much faster and, IMHO, that was because
Delphi uses another heap manager (while running FPC-compiled version, an intensive
swapping occurs, unlike Delphi-compiled version). Also I modified cmem.pp from Packages
to test my program using C heap functions under Win32.

Benchs on K62-500 (W'NT 4):
FPC-compiled, native heap: from <1 ms to >2 min;
FPC-compiled, using slightly modified cmem.pp from Packages (heap manager
              from msvcrt40.dll): 2.5-9 s;
FPC-compiled, using slightly modified cmem.pp from Packages (heap manager
              from crtdll.dll): 1.5-9 s;
Delphi6: <1-10 ms(!)

I'm shocked after these results! IMHO, multi-platform FPC heap manager
is not effective for win32 target. I can only hope that this my
program is not correctly written.

I could send my unfortunate program (the day after tomorrow) but it is relatively big.


-- 
Best regards,
 Pavel                            mailto:pavel at insect.mail.iephb.ru







More information about the fpc-devel mailing list