ES6 Map vs Object properties (v247)

Revision 247 of this benchmark created by Paweł Lesiecki on


Setup

var map = new Map();
  var obj = Object.create(null);

Test runner

Ready to run.

Testing in
TestOps/sec
map.set(key,val)
for (var i=0; i < 10000; i++) {
   map.set(i,i);
}
ready
obj[key] = val;
for (var i=0; i < 10000; i++) {
   obj[i] = i;
}
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.