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
Associated blog article http://blog.vjeux.com/2011/javascript/improve-cache-performance-reduce-lookup.html
<script>
var keyHit = 'in'
var keyMiss = 'out'
</script>
var cache = {}
for (var i = 0; i < 10000; ++i) {
cache[Math.random()] = 1
}
cache['in'] = 1
Ready to run.
Test | Ops/sec | |
---|---|---|
Standard way - Cache hit |
| ready |
Standard way - Cache miss |
| ready |
Clever Way - Cache hit |
| ready |
Clever Way - Cache miss |
| ready |
Short Version - Cache hit |
| ready |
Short Version - Cache miss |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.