Script Preparation code:
Tests:
  • .forEach

  • for..of

  • for..of (destructuring)

  • .map

  • .map (destructuring)

  • .for (init array)

  • .reduce

  • .reduce (destructuring)

  • for..of (reduce)

  • for..of (reduce) (destructuring)

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    .forEach
    for..of
    for..of (destructuring)
    .map
    .map (destructuring)
    .for (init array)
    .reduce
    .reduce (destructuring)
    for..of (reduce)
    for..of (reduce) (destructuring)

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/133.0.0.0 Safari/537.36
Chrome 133 on Windows
View result in a separate tab
Test name Executions per second
.forEach 41316172.0 Ops/sec
for..of 62540452.0 Ops/sec
for..of (destructuring) 63171200.0 Ops/sec
.map 36072416.0 Ops/sec
.map (destructuring) 35287688.0 Ops/sec
.for (init array) 56116088.0 Ops/sec
.reduce 49730352.0 Ops/sec
.reduce (destructuring) 54160524.0 Ops/sec
for..of (reduce) 63571516.0 Ops/sec
for..of (reduce) (destructuring) 63874252.0 Ops/sec