Bug 39337 - Move Attr pointer from Attribute to an out of band HashMap
Summary: Move Attr pointer from Attribute to an out of band HashMap
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2010-05-18 18:28 PDT by Sam Weinig
Modified: 2010-05-19 17:25 PDT (History)
2 users (show)

See Also:


Attachments
patch (5.18 KB, patch)
2010-05-18 18:31 PDT, Sam Weinig
no flags Details | Formatted Diff | Diff
patch 2 (5.29 KB, patch)
2010-05-18 18:47 PDT, Sam Weinig
mjs: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Weinig 2010-05-18 18:28:22 PDT
Attrs are rare enough that it does not make sense to keep them in the Attribute itself. We should move them to a global rare data HashMap.
Comment 1 Sam Weinig 2010-05-18 18:29:50 PDT
<rdar://problem/8001168>
Comment 2 Sam Weinig 2010-05-18 18:31:40 PDT
Created attachment 56437 [details]
patch
Comment 3 Early Warning System Bot 2010-05-18 18:43:52 PDT
Attachment 56437 [details] did not build on qt:
Build output: http://webkit-commit-queue.appspot.com/results/2321307
Comment 4 Sam Weinig 2010-05-18 18:46:28 PDT
This patch doesn't build it seems due to a stupid merging issue.  The fix is removing initialization of m_impl(0).  Will make  a new patch.
Comment 5 Sam Weinig 2010-05-18 18:47:05 PDT
Created attachment 56438 [details]
patch 2
Comment 6 Maciej Stachowiak 2010-05-18 18:52:54 PDT
Comment on attachment 56438 [details]
patch 2

r=me
Comment 7 Sam Weinig 2010-05-18 18:57:08 PDT
Landed in r59731.
Comment 8 Alexey Proskuryakov 2010-05-19 11:00:21 PDT
What effect does it have on XPath performance? One test to try would be <http://ejohn.org/apps/classname/xpath.html>.
Comment 9 Sam Weinig 2010-05-19 17:25:44 PDT
(In reply to comment #8)
> What effect does it have on XPath performance? One test to try would be <http://ejohn.org/apps/classname/xpath.html>.

It is around 0.2-0.3% loss, which should be acceptable given the big win on memory.