Tests:
  • Map to Array for 100 Items

    AخA
     
    var fooSet = new Map();
    for(var i=0;i<100;i++) {
      fooSet.set(i, i);
    }
    var other = Array.from(fooSet);
  • Map to Array for 10,000 Items

     
    var fooSet = new Map();
    for(var i=0;i<10000;i++) {
      fooSet.set(i, i);
    }
    var other = Array.from(fooSet);
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    Map to Array for 100 Items
    Map to Array for 10,000 Items

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 10 days ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/135.0.0.0 Safari/537.36
Chrome 135 on Windows
View result in a separate tab
Test name Executions per second
Map to Array for 100 Items 447339.8 Ops/sec
Map to Array for 10,000 Items 2804.2 Ops/sec