Script Preparation code:
AخA
 
var arr = [100,324,234,234,2,4,4,23,423,42,5,34,63,45,354,23,525,235,23,52,35,235,2,352,35,2,35,235,23,52,53,25,2,35,23,52,35,25235,235,23,52,52,35,235,23,525]
Tests:
  • Array.push

     
    arr.push(2)
  • Array spread

     
    arr = [...arr, 2]
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    Array.push
    Array spread

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 3 years ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.131 Safari/537.36
Chrome 92 on Windows
View result in a separate tab
Test name Executions per second
Array.push 6232642.0 Ops/sec
Array spread 3.2 Ops/sec