Script Preparation code:
AخA
 
var array = [1,2,3,4,5,6];
Tests:
  • arrayUnshift

     
    array.unshift(0);
  • concat

     
    array = [0].concat(array)
  • spread

     
    array = [0, ...array]
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    arrayUnshift
    concat
    spread

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 years ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.0.0.0 Safari/537.36
Chrome 102 on Windows
View result in a separate tab
Test name Executions per second
arrayUnshift 26942.9 Ops/sec
concat 397.2 Ops/sec
spread 108.2 Ops/sec