Micro-optimize the way we hand NodeLists to JSC.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 21 Apr 2014 10:15:40 +0000 (10:15 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 21 Apr 2014 10:15:40 +0000 (10:15 +0000)
commitffc3ba9e86ca30b47ba3acbe3c8961eba70181db
tree272c477deb5fca10bf98f3100e481fac54b5f0fc
parent55dcc7ca9cb09bd5798255a8d0d397ccc902140a
Micro-optimize the way we hand NodeLists to JSC.
<https://webkit.org/b/131932>

Use HashMap::fastAdd() when returning cached node lists and collections.
10.9% progression on Bindings/get-elements-by-tag-name.html

Reviewed by Antti Koivisto.

* dom/NodeRareData.h:
(WebCore::NodeListsNodeData::addCacheWithAtomicName):
(WebCore::NodeListsNodeData::addCacheWithName):
(WebCore::NodeListsNodeData::addCacheWithQualifiedName):
(WebCore::NodeListsNodeData::addCachedCollection):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@167589 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/dom/NodeRareData.h