[fpc-devel] Benchmark for FreePascal - test
darekM
darekm at emadar.com
Thu Dec 15 00:23:21 CET 2005
I've done some test
there are 5 version of revcom test
1. original
2. done bigger buffer
3 use tTextSrteam
4+ 5 in place of readln i've pass const string
6 only one set string variable
7 no move- I've rem MOVE procedure
I've repeat test in program, because time of test are vary (I don't know
why)
on FPC I use -OG3ru -XX - Xs parameters
Source attached
My conclusion:
1. on Linux MOVE implementation is very slow (or I make mistake in tests)
2. on win read via text file is two times slower than via handle, on
Linux is not so slowly (depends on pt. 1)
on win consume 50%, on Linux 80%
Results:
On Delphi+win+athlon2.8
readln 144696
readln +big buffer 146475
ttextStream 52767 <2 times faster
no read file 31106
no read file +big buffer 30935
no read file 30994
no set string 32243
no move 18353 <2 times faster
ttextStream 52306
readln +big buffer 146588
readln 144410
on FPC+win+athlon2.8 (the same machine)
readln 88309
readln +big buffer 88159
ttextStream 45789 <2 times faster
no read file 32341
no read file +big buffer 24045
no read file 23886
no set string 25246
no move 15031 <2 times faster
ttextStream 45425
readln +big buffer 88460
readln 87379
on FPC +linux gentoo+athlon 2.6
readln 76621
readln +big buffer 79921
ttextStream 73222 <no times faster
no read file 65700
no read file +big buffer 70429
no read file 75157
no set string 80239
no move 27527 <3 times faster
ttextStream 76936
readln +big buffer 77679
readln 78108
Darek
PS. Sorry for my English.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: revcom.pas
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20051215/7995e552/attachment.ksh>
More information about the fpc-devel
mailing list