Tests:

Historical Performance Data aggregated from 53 community runs

Desktop Results:
Chrome 45 runs
Loop push
50.3M/s
Loop
15.2M/s
Map
12.8M/s
Array.from
2.1M/s

Fastest: Loop push (23.5x faster)

View exact numbers
  • Loop push: 50,280,936 ops/sec
  • Loop: 15,199,333 ops/sec
  • Map: 12,824,591 ops/sec
  • Array.from: 2,140,355 ops/sec
Firefox 8 runs
Loop
30.2M/s
Map
25.5M/s
Loop push
24.3M/s
Array.from
11.6M/s

Fastest: Loop (2.6x faster)

View exact numbers
  • Loop: 30,174,714 ops/sec
  • Map: 25,484,694 ops/sec
  • Loop push: 24,267,148 ops/sec
  • Array.from: 11,649,374 ops/sec

Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    Array.from
    Map
    Loop
    Loop push

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one year ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36
Chrome 138 on Windows
View result in a separate tab
Loop
91.5M/s
Loop push
56.6M/s
Map
56.5M/s
Array.from
2.5M/s
View exact numbers
Test name Executions per second
Loop 91,533,640 Ops/sec
Loop push 56,585,280 Ops/sec
Map 56,453,076 Ops/sec
Array.from 2,523,831 Ops/sec