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
function current(from, to) {
var result = [];
var n = from;
while (n < to) {
result.push(n);
n += 1;
}
return result;
}
function next(from, to) {
var result = Array(from < to ? to - from : 0);
var finish = from < 0 ? to + Math.abs(from) : to - from;
var idx = 0;
while (idx < finish) {
result[idx] = idx + from;
idx += 1;
}
return result;
}
Ready to run.
Test | Ops/sec | |
---|---|---|
Current |
| ready |
Next |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.