On Tue, Apr 29, 2014 at 11:49:20AM +0200, Tomas Hajny wrote: > On Tue, April 29, 2014 10:30, Petr Kristan wrote: > . > . > > I use "inteligent" block increasing. I can optimize program, but why is > > fpc heap manager to slow? > > > > Here is the sample stress program compilable with fpc, delphi and kylix: > . > . > > And here are results: > . > . > > Is possible to speedup heap manager? > > Well, results of your test program on my machine (physical machine, MS Win > 7 32-bit) show something different: > > Grow 0-9000000 31ms > Grow 10000000-19000000 109ms > Grow 20000000-29000000 172ms > Grow 30000000-39000000 250ms > Grow 40000000-49000000 327ms > Grow 50000000-59000000 406ms > Grow 60000000-69000000 483ms > Grow 70000000-79000000 546ms > Grow 80000000-89000000 625ms > Grow 90000000-99000000 702ms > Grow 100000000-109000000 764ms > Sum 4431ms > > (compiled without cmem / without valgrind) > > Grow 0-9000000 31ms > Grow 10000000-19000000 125ms > Grow 20000000-29000000 203ms > Grow 30000000-39000000 265ms > Grow 40000000-49000000 375ms > Grow 50000000-59000000 436ms > Grow 60000000-69000000 531ms > Grow 70000000-79000000 624ms > Grow 80000000-89000000 733ms > Grow 90000000-99000000 796ms > Grow 100000000-109000000 873ms > Sum 5008ms > > (compiled with -gv; as expected, adding CMem to the uses clause and > compiling without -gv gives basically the same result). Are you sure that -gv in windows has any effect? I think, that valgrind can be used only in unix systems. Isn't -gv option silently ignored in windows?
> Tests performed with trunk compiler based on SVN from about 10 days ago. > Results for 2.6.4 are more or less the same. Approve, I tested in 2.6. too. > 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. 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 - fpc-devel@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel