String literal vs Object cast (v9)

Revision 9 of this benchmark created on


Test runner

Ready to run.

Testing in
TestOps/sec
Strring Literal
var x;
for (var i = 0; i < 1000; i++) {
  x = '' + i;
}
ready
String Object
var x;
for (var i = 0; i < 1000; i++) {
  x = String(i);
}
ready

Revisions

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