Reading Performance of ES6 Map vs Object properties

JavaScript performance comparison

Revision 58 of this test case created by

Preparation code


      
      <script>
Benchmark.prototype.setup = function() {
  var map = new Map();
  var obj = {};
  var hashSize = 1000000;
  var testKeyNum = 20;
  var testkeys = [];
  
  for (var i = 0; i < hashSize; i++) {
      var key = randomString();
      var val = randomString();
      map.set(key, val);
      obj[key] = val;
  }
  
  var keys = Array.from(map.keys());
  for (var i = 0; i < testKeyNum; i++) {
      var testkey = keys[Math.random()*hashSize >>> 0];
      testkeys.push(testkey);
  }
  
  function randomString() {
      var text = "";
      var possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
  
      for( var i=0; i < 5; i++ )
          text += possible.charAt(Math.floor(Math.random() * possible.length));
  
      return text;
  }
  

};
</script>

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in CCBot 2.0.0 / Other 0.0.0
Test Ops/sec
map.get(key)
for (var i = testkeys.length - 1; i >= 0; i--) {
  map.get(testkeys[i]);
}
pending…
obj[key]
for (var i = testkeys.length - 1; i >= 0; i--) {
  obj[testkeys[i]];
}
pending…

Compare results of other browsers

Revisions

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

1 Comment

cai123 commented :

cai123 08.03

michael kors outlet online

coach factory outlet online

canada goose

ugg outlet store

dr martens

orioles jerseys

canada goose parka

adidas nmd runner

cheap jordan shoes

fitflop sandals

nike cortez classic

coach factory outlet online

ugg boots outlet

michael kors outlet store

cheap nike shoes

hermens

fred perry polo shirts

ecco outlet

mulberry handbags

pandora jewelry outlet

coach outlet store

birkenstock shoes outlet

adidas yeezy boost

mariners jerseys

mlb jerseys cheap

coach factory outlet online

coach factory outlet

coach factory outlet online

dansko shoes

ralph lauren uk

kate spade outlet online

devil rays jerseys

nike outlet

swarovski crystal

adidas outlet online

ugg boots

nike air max 2018

coach outlet online

abercrombie kids

air max

ray ban sunglasses outlet

burberry outlet store

nike dunks

adidas ultra boost

michael kors bags

canada goose jackets

toms shoes

coach factorty outlet online

christian louboutin shoes

air max outlet

oakley sunglasses outlet

nike air presto

coach outlet online

oakley sunglasses wholesale

longchamp outlet

coach factorty outlet store

blue jays jerseys

ugg boots

adidas outlet

moncler coats

converse all star

fred perry outlet

kate spade outlet

kobe shoes

supreme clothing

michael kors outlet clearance

ugg outlet store

mulberry

coach outlet

michael kors canada

coach factory outlet online

fitflops uk

nike outlet

coach factory outlet

kate spade handbag

coach factory outlet

nike cortez classic

harden vol 1

cheap oakley sunglasses

air max

dodgers jerseys

michael kors outlet store

pandora charms

cheap jordan shoes

cheap jordan shoes

uggs outlet

yeezy shoes

ralph lauren

pandora charms sale clearance

indians jerseys

mont blanc pens

nike air max 2019

birkenstock outlet

canada goose jackets

kate spade outlet

red bottom

air more uptempo

nike huarache shoes

pandora jewelry

louboutin outlet

adidas originals

pandora jewelry

athletics jerseys

air max 95

coach factory outlet online

pandora charms outlet

pandora charms sale clearance

pandora charms outlet

rolex replica watches for sale

angels jerseys

cheap ray ban sunglasses

discount oakley sunglasses

ugg sale

yeezy boost 350

ronaldo jerseys

adidas nmd r1

christian louboutin sale

coach factorty outlet online

ferragamo outlet

tory burch outlet online

salvatore ferragamo

cheap oakley sunglasses

ralph lauren uk

supreme shirts

mulberry uk

timberland boots

coach factory outlet online

kate spade outlet online

michael kors

ray ban sunglasses discount

ralph lauren outlet online

adidas yeezy

tiffany and co jewelry

michael kors outlet clearance

air jordan shoes

birkenstock sale

michael kors outlet clearance

air jordans

vans outlet

air max shoes

yeezy boost 350

ugg outlet online

louis vuitton outlet online

nike running shoes

marlins jerseys

red bottom heels

pandora charms

pandora outlet store

pandora outlet

canada goose jacket

pandora charms sale

moncler jacket

nike shoes

michael kors outlet store

pandora charms sale

salomon outlet

hermes bags

louboutin shoes

pandora charms outlet

moncler

coach outlet online

jimmy choo

pandora charms

fitflop shoes

kate spade bags

valentino outlet

asics outlet

yeezy shoes

ugg outlet store

ugg canada

coach outlet online

adidas nmd r1

ugg shoes

red bottoms

kate spade purses

adidas yeezy boost 350

louboutin outlet

michael kors outlet online

coach factory outlet

brewers jerseys

ecco outlet

dr martens boots

nike free 5.0

lebron james shoes

swarovski outlet

ray ban glasses

mlb jerseys

timberland boots outlet

polo ralph lauren outlet

cheap jordans

cheap jordan shoes

kate spade handbags

nike outlet store

coach factory outlet online

coach outlet online

coach factory outlet online

birkenstock outlet store

cheap air max

hermes bags

oakley sunglasses outlet

ralph lauren sale

nike react shoes

jordans

nba jerseys cheap

air jordan retro

pandora charms outlet

kate spade outlet online

coach outlet store online

twins jerseys

philipp plein

coach factory outlet online

kate spade handbags

coach factory outlet online

coach factorty outlet store

adidas superstar shoes

pandora charms outlet

christian louboutin shoes

coach outlet store online

louis vuitton factory outlet

nmd adidas

nike sneakers

new balance outlet

lacoste polo shirts

fitflop uk

yeezy boost

coach outlet online

ysl outlet

coach outlet online

pandora charms sale clearance

columbia outlet

cheap jordan shoes

nike air max 97

coach factory outlet

air max 1

nfl jerseys

moncler sale

louis vuitton handbags

canada goose jackets

padres jerseys

ralph lauren sale

diamondbacks jerseys

michael kors outlet store

nfl jerseys

fake rolex

pandora jewelry outlet

ray bans

dr martens boots

louboutin shoes

rolex replica watches

coach factory outlet online

ugg boots

nike air max 2018

birkenstock outlet online

canada goose outlet

cheap oakley sunglasses

coach factory outlet

cartier watches

adidas sneakers

christian louboutin sale

nike outlet online

mlb jerseys wholesale

salvatore ferragamo outlet

air more money

jimmy choo outlet

christian louboutin shoes

timberland shoes

kate spade outlet online

moncler outlet online

basketball shoes

birkenstock outlet store

adidas shoes

vans outlet store

astros jerseys

longchamp

louis vuitton outlet

nike shoes

nike tessen

polo ralph lauren outlet

coach factory outlet

canada goose jackets

jordan shoes

birkin handbags

ugg boots sale

toms outlet online

air max shoes

coach outlet store

fitflops sale clearance

kate spade outlet

kate spade handbags

michael kors outlet online

nike shox shoes

michael kors outlet online

cheap jordans

ralph lauren sale clearance uk

coach outlet store online

rangers jersey

canada goose sale

adidas store

cheap ray ban sunglasses

kate spade handbags

michael kors outlet store

nike zoom

ysl handbags

durant shoes

braves jerseys

kate spade outlet store

cheap air jordans

nike shoes outlet

white sox jerseys

jimmy choo shoes

christian louboutin shoes

moncler outlet online

moncler jackets

cheap air jordans

jordan shoes for sale

adidas yeezy shoes

skechers outlet

pandora outlet

adidas outlet online

timberland outlet

nike outlet store

salvatore ferragamo shoes

michael kors outlet

salvatore ferragamo shoes

coach factory outlet online

coach outlet store online

tiffany and co outlet

tory burch outlet store

michael kors outlet store

adidas campus shoes

kobe shoes

jordan shoes

coach outlet online

ralph lauren outlet online

birkenstock shoes

moncler sale

michael kors outlet online

cheap ray ban sunglasses

cheap air jordans

nike outlet online

fendi handbags

longchamp outlet online

polo ralph lauren outlet

reds jerseys

cheap jordan shoes

polo outlet online

canada goose sale

michael kors outlet

cheap jordan shoes

ugg outlet

pandora charms

discount oakley sunglasses

gucci outlet online

cheap jordans free shipping

kate spade outlet online

nike zoom shoes

michael kors outlet clearance

ferragamo shoes

timberland shoes

ecco outlet

polo ralph lauren outlet online

nike air max 90

polo ralph lauren outlet

canada goose coats

tiffany outlet

kate spade outlet online

air max 90

adidas stan smith

kate spade handbags

discount oakley sunglasses

columbia shoes

uggs outlet

ralph lauren outlet

canada goose jackets

polo ralph lauren outlet online

mlb jerseys cheap

adidas superstars

michael kors handbags

pandora jewelry

yeezy shoes

ray ban sunglasses outlet

michael kors handbags

nike outlet store online

mulberry outlet uk

pandora jewelry

michael kors outlet online

pandora jewelry store

toms outlet store

pandora canada

ralph lauren outlet online

longchamp outlet

rockies jerseys

coach outlet online

nike huarache shoes

retro 11

hermes outlet

hermes bag

polo ralph lauren

ralph lauren uk

coach outlet online

ralph lauren uk

adidas yeezy boost

rolex replica watches

underarmour outlet

canada goose outlet store

cheap oakley sunglasses

adidas outlet store

coach outlet online

tory burch outlet online

polo ralph lauren outlet online

coach outlet store online

birkenstock uk

adidas nmd r1

hermes handbags

cheap oakley sunglasses

coach outlet online

nike air max 97

moncler coats

timberland outlet

kate spade purses

louis vuitton outlet

converse outlet

coach outlet online

ralph lauren outlet online

fitflop sandals

kate spade bags

prada outlet online

canada goose coats

pg 2 shoes

ralph lauren

ralph lauren outlet online

coach outlet online

mont blanc pen

salvatore ferragamo outlet

timberland shoes

pandora charms sale

air max 87

supreme shirts

timberland outlet

reebok outlet

coach outlet

adidas shoes

coach outlet store online

asics outlet store

pirates jerseys

michael kors

nba jerseys wholesale

pandora rings

coach outlet online

mbt

adidas yeezy

nike free 3.0

louis vuitton outlet store

supreme uk

birkenstock outlet

kyrie 4

canada goose jackets

ecco shoes

adidas outlet store

uggs outlet

tory burch handbags

fitflops sale clearance

pandora charms outlet

nike outlet store

adidas outlet online

coach outlet store online clearance

fitflops sale

coach outlet online

prada shoes

new balance outlet store

yeezy boost 350

cheap ray ban sunglasses

canada goose

city royals jerseys

yeezy shoes

ecco shoes for women

polo ralph lauren outlet

ugg outlet online

pandora jewelry outlet

supra for sale

fitflops sale

nike sneakers

canada goose

mets jerseys

nike air max zero

fitflops sale

louis vuitton factory outlet

christian louboutin shoes

louis vuitton outlet online

pandora jewelry

birkenstock sandals

cheap nfl jerseys wholesale

supra for sale

philipp plein outlet

ralph lauren sale clearance uk

converse shoes

michael kors outlet clearance

cheap jordans for sale

pandora sale clearance

kate spade outlet online

coach outlet canada

cai123 08.03