On Tue, Apr 29, 2014 at 03:02:44PM +0400, Sergei Gorelkin wrote:
> On 29.04.2014 14:37, Tomas Hajny wrote:
> 
> >>>I don't know the reason of your difference, but no time necessary at all
> >>>(0 ms) for the valgrind variant looks very suspicious to me.
> >>But compiling by kylix compiler, i get the same results as by fpc with
> >>-gv option in linux.
> >>This is the reason why I start to hunt where is my program to slow if
> >>compiled by fpc against kylix.
> >
> >Can't it be somehow related to the method used for measuring the time
> >under Linux? Is the result shown inside consistent to the overall time
> >necessary for the program run?
> >
> Time measurement appears to be correct. Strace shows that
> reallocation happens using mremap syscalls, which apparently
> rearranges pages within address space without actual moving the
> data. This indeed can be done with almost zero overhead, but is
> hardly portable.

Thanks for the fast and perfect explanation.
Resolution for me is that heap manager cannot be multiplatformly improved.
I do some optimatization in my code.

Petr

-- 
Petr Kristan
.
EPOS PRO s.r.o., Smilova 333, 530 02 Pardubice
tel: +420 461101401    Czech Republic (Eastern Europe)
fax: +420 461101481
_______________________________________________
fpc-devel maillist  -  [email protected]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply via email to