stringComp

JavaScript performance comparison

Test case created by stringComp

Preparation code

 
<script>
Benchmark.prototype.setup = function() {
    var tmp = "test";
    var tmp2 = 321;
    var tmpDate1 = new Date();
    var tmpDate2 = new Date();
};
</script>

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in unknown unknown
Test Ops/sec
str
if ("hello" === tmp) {
  tmp = tmp;
}
pending…
num
if (123 === tmp2) {
  tmp2 = tmp2;
}
pending…
date
if (tmpDate1 === tmpDate2) {
  tmp2 = tmp2;
}
pending…

You can edit these tests or add even more tests to this page by appending /edit to the URL.

Compare results of other browsers

0 comments

Add a comment