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
Checking to see the performance of getImageData for various widths and heights.
<script>
var canvas = document.createElement('canvas');
canvas.width = 2880;
canvas.height = 2880;
var context = canvas.getContext('2d');
context.fillStyle = '#abc';
context.fillRect(0, 0, canvas.width, canvas.height);
var getData = function(chunkSize){
for(var y = 0; y < canvas.height; y += chunkSize)
for(var x = 0; x < canvas.width; x += chunkSize)
var data = context.getImageData(x, y, chunkSize, chunkSize);
}
</script>
Ready to run.
Test | Ops/sec | |
---|---|---|
1x1 |
| ready |
32x32 |
| ready |
64x64 |
| ready |
256x256 |
| ready |
whole image |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.