Tests:

Historical Performance Data aggregated from 104 community runs

Desktop Results:
Chrome 75 runs
Map
174.5M/s
Switch
174.4M/s
View exact numbers
  • Map: 174,545,424 ops/sec
  • Switch: 174,407,824 ops/sec
Firefox 8 runs
Switch
1598.6M/s
Map
18.9M/s

Fastest: Switch (84.8x faster)

View exact numbers
  • Switch: 1,598,632,448 ops/sec
  • Map: 18,851,052 ops/sec
Mobile Results:
Chrome 15 runs
Switch
84.9M/s
Map
68.3M/s

Fastest: Switch (1.2x faster)

View exact numbers
  • Switch: 84,902,096 ops/sec
  • Map: 68,322,912 ops/sec
Safari 6 runs
Switch
450.2M/s
Map
16.5M/s

Fastest: Switch (27.2x faster)

View exact numbers
  • Switch: 450,176,640 ops/sec
  • Map: 16,545,826 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
    Switch
    Map

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 8 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36 Edg/142.0.0.0
Chrome 142 on Windows
View result in a separate tab
Switch
149.8M/s
Map
142.6M/s
View exact numbers
Test name Executions per second
Switch 149,806,400 Ops/sec
Map 142,592,016 Ops/sec