Script Preparation code:
Tests:
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    Array.concat
    Array.slice
    For loop
    For loop with declared length
    While loop
    Spread operator
    Slice with begin argument
    Slice with begin and end argument
    Array.from

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one year ago)
Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Mobile Safari/537.36
Chrome Mobile 130 on Android
View result in a separate tab
Array.slice
4.7M/s
Slice with begin argument
4.7M/s
Array.concat
4.6M/s
Spread operator
4.4M/s
Array.from
3.5M/s
Slice with begin and end argument
2.8M/s
While loop
227K/s
For loop with declared length
217K/s
For loop
142K/s
View exact numbers
Test name Executions per second
Array.slice 4,734,883 Ops/sec
Slice with begin argument 4,698,656 Ops/sec
Array.concat 4,649,054 Ops/sec
Spread operator 4,433,834 Ops/sec
Array.from 3,519,932 Ops/sec
Slice with begin and end argument 2,841,522 Ops/sec
While loop 227,307 Ops/sec
For loop with declared length 216,816 Ops/sec
For loop 141,942 Ops/sec