Script Preparation code:
x
 
var size = 450000;
var buf = new ArrayBuffer(size);
var normalArray = new Array(size);
var arrayFromBuffer = new Uint8Array(buf);
var arrayWithoutBuffer = new Uint8Array(size);
Tests:
  • Array

     
    for (i =0; i< size; i++){
     normalArray[i] = 0; 
    }
  • typed array from Buffer

     
    for (i =0; i< size; i++){
     arrayFromBuffer[i] = 0; 
    }
  • typed Array no buffer

     
    for (i =0; i< size; i++){
     arrayWithoutBuffer[i] = 0; 
    }
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    Array
    typed array from Buffer
    typed Array no buffer

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 5 months ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36
Chrome 130 on Mac OS X 10.15.7
View result in a separate tab
Test name Executions per second
Array 18.7 Ops/sec
typed array from Buffer 19.7 Ops/sec
typed Array no buffer 19.7 Ops/sec