Array clear methods (v2)

Revision 2 of this benchmark created on


Test runner

Ready to run.

Testing in
TestOps/sec
redefine
var a = [];
for (i = 1; i < 100000; i++) {
  a.push(i);
}
a = [];
ready
length=0
var a = [];
for (i = 1; i < 100000; i++) {
  a.push(i);
}
a.length = 0;
ready

Revisions

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