Array Access Back to the Win32 Shootout
Back to dada's perl lab

[The Original Shootout]   [NEWS]   [FAQ]   [Methodology]   [Platform Details]   [Acknowledgements]   [Scorecard]  

Measurements while N varies

N is the number of array elements we access.


Measurement of CPU as N varies
  N
Test Source 1000 3000 5000 7000
mingw32 0.01 0.02 0.04 0.05
vc++ 0.01 0.03 0.04 0.06
vc 0.01 0.02 0.04 0.06
lcc 0.01 0.03 0.04 0.06
gnat 0.02 0.03 0.05 0.06
modula2 0.01 0.04 0.05 0.07
bcc 0.01 0.03 0.05 0.07
ocaml 0.01 0.03 0.05 0.07
gcc 0.03 0.05 0.06 0.07
mercury 0.04 0.05 0.07 0.09
se 0.03 0.08 0.13 0.17
csharp 0.12 0.14 0.17 0.21
bigforth 0.04 0.12 0.19 0.26
smlnj 0.09 0.18 0.27 0.37
java 0.47 0.52 0.57 0.62
nice 0.54 0.59 0.65 0.69
pliant 0.19 0.38 0.56 0.75
vpascal 0.11 0.34 0.56 0.78
gforth 0.32 0.89 1.45 2.03
ocamlb 0.78 2.32 3.86 5.38
pike 0.86 2.45 4.04 5.65
oz 1.04 2.82 4.62 6.38
slang 1.09 3.17 5.28 7.47
parrot 0.69 3.47 6.79 9.70
python 1.57 4.40 7.90 11.17
lua 1.20 5.10 8.47 11.85
erlang 1.44 4.36 7.94 12.00
poplisp 1.94 5.81 9.71 13.68
icon 2.24 6.71 11.19 15.78
awka 1.45 6.76 13.91 16.64
perl 2.09 7.22 12.53 17.83
cygperl 2.03 7.25 12.57 18.07
guile 3.41 10.10 16.94 23.83
ici 2.50 10.00 17.85 24.79
php 4.72 14.34 23.95 33.39
mawk 2.03 21.57 31.63 34.91
ruby 5.96 17.76 29.51 41.34
tcl 6.75 22.01 35.44 49.72
gawk 8.17 26.71 42.61 60.62
vbscript 9.67 28.87 48.53 67.95
jscript 8.45 31.30 48.25 68.91
rexx 6.00 30.61 73.79 135.92
ghc F F F F
fpascal F F F F
lua5 F F F F
Measurement of Memory as N varies
  N
Test Source 1000 3000 5000 7000
mingw32 512 528 544 560
vc++ 524 540 560 572
vc 472 488 508 520
lcc 512 528 544 560
gnat 740 756 772 788
modula2 644 660 676 696
bcc 572 584 600 616
ocaml 656 672 688 704
gcc 1516 1532 1544 1560
mercury 1740 1756 1772 1788
se 564 576 596 612
csharp 3288 3300 3316 3336
bigforth 920 936 952 968
smlnj 940 940 940 940
java 4584 4600 4616 4632
nice 4924 4940 4952 4968
pliant 3220 3248 3344 3376
vpascal 592 608 624 640
gforth 1492 1508 1524 1536
ocamlb 380 380 380 380
pike 3420 3432 3488 3516
oz 648 648 648 648
slang 1828 1860 1892 1924
parrot 1148 1444 1772 2352
python 2404 2468 2532 2596
lua 716 988 1392 1392
erlang 5188 5292 5444 5572
poplisp 4472 4476 4492 4504
icon 608 640 672 704
awka 1740 2056 2372 2700
perl 1496 1632 1772 1908
cygperl 2364 2528 2692 2836
guile 2476 2492 2508 2524
ici 1240 1748 1764 2448
php 3036 3464 3908 4312
mawk 1664 1824 1984 2156
ruby 1872 1888 1904 1920
tcl 1684 2092 2528 2936
gawk 2208 2528 2896 3212
vbscript 2324 2384 2456 2520
jscript 2412 2784 3252 3604
rexx 1192 1600 2012 2440
ghc F F F F
fpascal F F F F
lua5 F F F F

The following graph is similar to the graph on the index page, but here, N is much smaller, and startup costs may be more prominent.





[Note: Values have been normalized to fall in the range of 0-10 for aesthetic reasons. Original value ranges are included on the X-axis.
Source Code CPU (sec) Mem (KB) Lines Code Log
lcc 0.01 512 21 log
modula2 0.01 644 0 log
mingw32 0.01 512 21 log
vc 0.01 472 21 log
bcc 0.01 572 21 log
vc++ 0.01 524 18 log
ocaml 0.01 656 16 log
gnat 0.02 740 0 log
gcc 0.03 1516 21 log
se 0.03 564 49 log
bigforth 0.04 920 21 log
mercury 0.04 1740 38 log
smlnj 0.09 940 36 log
vpascal 0.11 592 29 log
csharp 0.12 3288 19 log
pliant 0.19 3220 20 log
gforth 0.32 1492 21 log
java 0.47 4584 15 log
nice 0.54 4924 0 log
parrot 0.69 1148 35 log
ocamlb 0.78 380 16 log
pike 0.86 3420 16 log
oz 1.04 648 25 log
slang 1.09 1828 18 log
lua 1.20 716 13 log
erlang 1.44 5188 26 log
awka 1.45 1740 10 log
python 1.57 2404 12 log
poplisp 1.94 4472 15 log
cygperl 2.03 2364 13 log
mawk 2.03 1664 10 log
perl 2.09 1496 13 log
icon 2.24 608 14 log
ici 2.50 1240 11 log
guile 3.41 2476 15 log
php 4.72 3036 13 log
ruby 5.96 1872 15 log
rexx 6.00 1192 16 log
tcl 6.75 1684 16 log
gawk 8.17 2208 10 log
jscript 8.45 2412 20 log
vbscript 9.67 2324 13 log
ghc F F 20 log
lua5 F F 12 log
fpascal F F 29 log


Back to the Win32 Shootout
Back to dada's perl lab
Send comments or suggestions to dada@perl.it