Link Details

Many readers pointed out (correctly) that my exposition on efficient JavaScript string building was in need of benchmarking numbers to be of real value. This article provides those number for several browsers, along with a simple test suite you can try yourself.

Posted by jimbojw  |   Submitted: May 01 2009 / 12:39

Add your comment

Html tags not supported. Reply is editable for 5 minutes. Use [code lang="java|ruby|sql|css|xml"][/code] to post code snippets.


User 368023 avatar

yakkoh replied ago:

Let's be fair: the test "Internet Explorer 6 (via wine) is ... " does not count.

Reply 0 votes
User 207602 avatar

Jim Wilson replied ago:

Hi yakkoh,

Thanks for taking the time to comment. It depends on what you mean. If the purpose of the benchmark was to compare /browser implementations/ then yes, I completely agree that running any browser on a non-native platform is an unfair test.

However, the purpose of the benchmarks is to compare JavaScript function implementations against each other. From that standpoint, I feel that comparing how one JavaScript function runs in IE 6/wine vs another is at least somewhat relevant, since the same OS process is responsible for the results of both tests. That is, any performance implications of running in wine ought to affect all implementations, right?

Ok, well, maybe not. Maybe wine puts a higher penalty on memory allocation than native Windows, which would unduly penalize the string buffer implementation more than others. That might be worth investigating in its own right.

Reply 0 votes

Recommended Links

Upvoters (3)

Downvoters (0)

    Written by: Ryan Knight
    Featured Refcardz: Top Refcardz:
    1. Apache Hadoop
    2. Play
    3. Akka
    4. Debugging JavaScript
    5. Design Patterns
    1. Apache Hadoop
    2. REST
    3. Java
    4. Git
    5. Java Performance
    Connect with DZone