Here at work, we built (mostly David Pennell) a JavaScript system called Smee (an old version of it is available in the Cincom public repository). It is a faithful implementation of the ECMAscript standard in VisualWorks. It is compiled to VW bytecode, but message sends don't (yet) leverage VM message lookup. Looks like it's quite a bit faster in ops/sec than both Firefox and IE (this was running on a Pentium M laptop under WinXP). Amazingly, even without help from the VM for message lookup, it's still faster in that category than IE (but lags behind Firefox).
<br><br>- Stephen<br><br>Firefox:<br>n1 = 2; time = 60 milliseconds; 16666667 operations/sec.<br>n1 = 4; time = 130 milliseconds; 15384615 operations/sec.<br>n1 = 8; time = 261 milliseconds; 15325670 operations/sec.<br>n1 = 16; time = 600 milliseconds; 13333333 operations/sec.
<br>n2 = 24; time = 151 milliseconds; 496854 sends/sec.<br>n2 = 25; time = 200 milliseconds; 606965 sends/sec.<br>n2 = 26; time = 300 milliseconds; 654727 sends/sec.<br>n2 = 27; time = 481 milliseconds; 660730 sends/sec.<br>
n2 = 28; time = 791 milliseconds; 650100 sends/sec.<br><br>IE:<br>n1 = 2; time = 230 milliseconds; 4347826 operations/sec.<br>n1 = 4; time = 161 milliseconds; 12422360 operations/sec.<br>n1 = 8; time = 230 milliseconds; 17391304 operations/sec.
<br>n1 = 16; time = 471 milliseconds; 16985138 operations/sec.<br>n2 = 24; time = 481 milliseconds; 155977 sends/sec.<br>n2 = 25; time = 570 milliseconds; 212970 sends/sec.<br><br>Smee:<br>0: 'n1 = 2; time = 40 milliseconds; 25000000 operations/sec.'
<br>1: 'n1 = 4; time = 88 milliseconds; 22727273 operations/sec.'<br>2: 'n1 = 8; time = 176 milliseconds; 22727273 operations/sec.'<br>3: 'n1 = 16; time = 333 milliseconds; 24024024 operations/sec.'<br>4: 'n1 = 32; time = 694 milliseconds; 23054755 operations/sec.'
<br>5: 'n2 = 24; time = 194 milliseconds; 386727 sends/sec.'<br>6: 'n2 = 25; time = 319 milliseconds; 380542 sends/sec.'<br>7: 'n2 = 26; time = 506 milliseconds; 388178 sends/sec.'<br><br><div><span class="gmail_quote">
On 4/18/06, <b class="gmail_sendername">Bert Freudenberg</b> <<a href="mailto:bert@impara.de">bert@impara.de</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
iMac G5, 1.6 GHz, software as yours. I re-ran it today, looks a bit<br>better:<br><br>Safari:<br>n1 = 2; time = 418 milliseconds; 2392344 operations/sec.<br>n1 = 4; time = 558 milliseconds; 3584229 operations/sec.<br><br>
n2 = 24; time = 1362 milliseconds; 55084 sends/sec.<br><br><br>Firefox:<br><br>n1 = 2; time = 102 milliseconds; 9803922 operations/sec.<br>n1 = 4; time = 207 milliseconds; 9661836 operations/sec.<br>n1 = 8; time = 413 milliseconds; 9685230 operations/sec.
<br>n1 = 16; time = 892 milliseconds; 8968610 operations/sec.<br><br>n2 = 24; time = 137 milliseconds; 547628 sends/sec.<br>n2 = 25; time = 221 milliseconds; 549290 sends/sec.<br>n2 = 26; time = 358 milliseconds; 548654 sends/sec.
<br>n2 = 27; time = 600 milliseconds; 529685 sends/sec.<br><br>... which is still 10x more sends.<br><br>- Bert -<br><br>Am 13.04.2006 um 23:04 schrieb <a href="mailto:Dean_Swan@Mitel.COM">Dean_Swan@Mitel.COM</a>:<br><br>
><br>> Hi Bert,<br>><br>> What kind of Mac were you running on? I get these results:<br>><br>> iBook G4 1.2 GHz, OS X 10.4.6, Safari 2.0.3 (417.9.2)<br>> n1 = 2; time = 259 milliseconds; 3861004 operations/sec.
<br>> n1 = 4; time = 532 milliseconds; 3759398 operations/sec.<br>><br>> n2 = 24; time = 731 milliseconds; 102633 sends/sec.<br>><br>><br>> iBook G4 1.2 GHz, OS X 10.4.6, Firefox
<a href="http://1.5.0.1">1.5.0.1</a><br>> n1 = 2; time = 128 milliseconds; 7812500 operations/sec.<br>> n1 = 4; time = 331 milliseconds; 6042296 operations/sec.<br>> n1 = 8; time = 506 milliseconds; 7905138 operations/sec.
<br>><br>> n2 = 24; time = 190 milliseconds; 394868 sends/sec.<br>> n2 = 25; time = 329 milliseconds; 368976 sends/sec.<br>> n2 = 26; time = 508 milliseconds; 386650 sends/sec.<br>><br>
> So,I'd say Firefox is about 2x faster for operations and 4x for<br>> sends, but not 20x.<br>><br>><br>> And just for fun:<br>><br>> Dell PWS370 P4 3.0 GHz, Win XP Sp2, IE<br>> 6.0.2900.2180.xpsp_sp2_gdr.050301-1519
<br>> n1 = 2; time = 62 milliseconds; 16129032 operations/sec.<br>> n1 = 4; time = 110 milliseconds; 18181818 operations/sec.<br>> n1 = 8; time = 219 milliseconds; 18264840 operations/sec.<br>
> n1 = 16; time = 453 milliseconds; 17660044 operations/sec.<br>> n1 = 32; time = 906 milliseconds; 17660044 operations/sec.<br>><br>> n2 = 24; time = 437 milliseconds; 171682 sends/sec.<br>
> n2 = 25; time = 719 milliseconds; 168836 sends/sec.<br>><br>> Dell PWS370 P4 3.0 GHz, Win XP Sp2, IE<br>> 6.0.2900.2180.xpsp_sp2_gdr.050301-1519<br>> n1 = 2; time = 47 milliseconds; 21276596 operations/sec.
<br>> n1 = 4; time = 109 milliseconds; 18348624 operations/sec.<br>> n1 = 8; time = 203 milliseconds; 19704433 operations/sec.<br>> n1 = 16; time = 422 milliseconds; 18957346 operations/sec.<br>
> n1 = 32; time = 860 milliseconds; 18604651 operations/sec.<br>><br>> n2 = 24; time = 93 milliseconds; 806720 sends/sec.<br>> n2 = 25; time = 157 milliseconds; 773204 sends/sec.<br>> n2 = 26; time = 250 milliseconds; 785672 sends/sec.
<br>> n2 = 27; time = 390 milliseconds; 814900 sends/sec.<br>> n2 = 28; time = 656 milliseconds; 783886 sends/sec.<br>><br>> Here, Firefox is about the same for operations and 4x to 5x for sends.
<br>><br>> -Dean<br>><br>><br>><br>><br>> Bert Freudenberg <<a href="mailto:bert@impara.de">bert@impara.de</a>><br>> Sent by: <a href="mailto:squeak-dev-bounces@lists.squeakfoundation.org">
squeak-dev-bounces@lists.squeakfoundation.org</a><br>> 04/13/2006 05:22 AM<br>> Please respond to The general-purpose Squeak developers list<br>><br>><br>> To: Dan Ingalls <<a href="mailto:Dan@SqueakLand.org">
Dan@SqueakLand.org</a>><br>> cc: The general-purpose Squeak developers list<br>> <<a href="mailto:squeak-dev@lists.squeakfoundation.org">squeak-dev@lists.squeakfoundation.org</a>><br>> Subject: Re: JavaScript Performance Benchmark
<br>><br>><br>><br>><br>> Am 12.04.2006 um 21:59 schrieb Dan Ingalls:<br>><br>> > I've been having fun with JavaScript, and thought folks would enjoy<br>> > this little tribute to tinyBenchmarks...
<br>> ><br>> > <a href="http://www.weather-dimensions.com/Dan/">http://www.weather-dimensions.com/Dan/</a><br>> JavaScriptBenchmark.html<br>><br>> Fun indeed. Anyone else noticed the abysmal send performance in
<br>> Apple's Safari?<br>><br>> n1 = 4; time = 646 milliseconds; 3095975 operations/<br>> sec.<br>> n2 = 24; time = 3443 milliseconds; 21791 sends/sec.<br>><br>> Firefox is 20x faster:
<br>><br>> n1 = 8; time = 566 milliseconds; 7067138 operations/<br>> sec.<br>> n2 = 27; time = 743 milliseconds; 427740 sends/sec.<br>><br>> - Bert -<br>><br>><br>>
<br>><br>><br><br><br><br></blockquote></div><br>