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
<script src="https://raw.github.com/imaya/base64.js/master/bin/base64.min.js"></script>
<script>
function native(str) {
var decoded = atob(str);
var i, il = decoded.length;
var array = new Uint8Array(il);
for (i = 0; i < il; ++i) {
array[i] = decoded.charCodeAt(i);
}
return array;
}
</script>
var size = 10000;
var tmp = [];
var str;
var i;
for (i = 0; i < size; ++i) {
tmp[i] = String.fromCharCode(i & 0xff);
}
str = window.btoa(tmp.join(''));
Ready to run.
Test | Ops/sec | |
---|---|---|
js impl |
| ready |
native |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.