jsPerf.app is an online JavaScript performance benchmark test runner & jsperf.com mirror. It is a complete rewrite in homage to the once excellent jsperf.com now with hopefully a more modern & maintainable codebase.
jsperf.com URLs are mirrored at the same path, e.g:
https://jsperf.com/negative-modulo/2
Can be accessed at:
https://jsperf.app/negative-modulo/2
this.array = [];
for (var i = 1e3-1; i >= 0; --i) {
this.array[i] = i;
}
Array.prototype.append = function (array) {
Array.prototype.push.apply(this, array);
return this;
};
Array.prototype.append2 = function (array) {
var size = array.length;
for (var i = 0; i < size; i++) this.push(array[i]);
return this;
};
Ready to run.
Test | Ops/sec | |
---|---|---|
concat |
| ready |
push.apply |
| ready |
for loop |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.