bracket_vs_dot

JavaScript performance comparison

Test case created

Test runner

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

Java applet disabled.

Testing in unknown unknown
Test Ops/sec
bracket example
var a = { pathname : "", name : "", prop1 : "", prop2 : "", prop3 : "" };
a["pathname"] = 2;
a["name"] = "hi";
a["prop1"] = 1;
a["prop2"] = 2;
a["prop3"] = 3;
a["pathname"] = 2;
a["name"] = "hi";
a["prop1"] = 1;
a["prop2"] = 2;
a["prop3"] = 3;
a["pathname"] = 2;
a["name"] = "hi";
a["prop1"] = 1;
a["prop2"] = 2;
a["prop3"] = 3;
pending…
dot example
var a = { pathname : "", name : "", prop1 : "", prop2 : "", prop3 : "" };
a.pathname = 2;
a.name = "hi";
a.prop1 = 1;
a.prop2 = 2;
a.prop3 = 3;
a.pathname = 2;
a.name = "hi";
a.prop1 = 1;
a.prop2 = 2;
a.prop3 = 3;
a.pathname = 2;
a.name = "hi";
a.prop1 = 1;
a.prop2 = 2;
a.prop3 = 3;
pending…

Compare results of other browsers

Revisions

You can edit these tests or add even more tests to this page by appending /edit to the URL. Here’s a list of current revisions for this page:

0 comments

Add a comment