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
const ordered = [];
const unordered = [];
for (let i = 0; i < 6; i++) {
const x = Math.random();
const y = Math.random();
const z = Math.random();
ordered.push({x, y, z});
if (i === 0) {
unordered.push({x, y, z});
} else if (i === 1) {
unordered.push({x, z, y});
} else if (i === 2) {
unordered.push({y, x, z});
} else if (i === 3) {
unordered.push({y, z, x});
} else if (i === 4) {
unordered.push({z, x, y});
} else {
unordered.push({z, y, x});
}
}
Ready to run.
Test | Ops/sec | |
---|---|---|
Ordered properties |
| ready |
Unordered properties |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.