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
var a1 = [];
var o1 = {};
for (var i = 0; i < 1000; i++) {
var id = Math.floor(Math.random() * 100000) + 1;
if(i===500){
a1.push("TEST");
o1.TEST = "TEST";
}
a1.push(id);
o1.id = id;
}
Ready to run.
Test | Ops/sec | |
---|---|---|
Manual Array Lookup |
| ready |
indexOf |
| ready |
Object by Key |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.