Bug 94990

Summary: Share immutable ElementAttributeData between elements with identical attributes.
Product: WebKit Reporter: Andreas Kling <kling>
Component: DOMAssignee: Andreas Kling <kling>
Status: RESOLVED FIXED    
Severity: Normal CC: cmarcelo, koivisto, webkit.review.bot
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Love letter to EWS
buildbot: commit-queue-
Love letter to EWS + cheesy GCC buildfix
none
Patch!!11 koivisto: review+

Andreas Kling
Reported 2012-08-24 17:53:48 PDT
Attachments
Love letter to EWS (9.52 KB, patch)
2012-08-24 18:54 PDT, Andreas Kling
buildbot: commit-queue-
Love letter to EWS + cheesy GCC buildfix (9.49 KB, patch)
2012-08-24 19:46 PDT, Andreas Kling
no flags
Patch!!11 (11.93 KB, patch)
2012-09-03 09:42 PDT, Andreas Kling
koivisto: review+
Andreas Kling
Comment 1 2012-08-24 18:54:51 PDT
Created attachment 160542 [details] Love letter to EWS
Build Bot
Comment 2 2012-08-24 19:18:41 PDT
Comment on attachment 160542 [details] Love letter to EWS Attachment 160542 [details] did not pass mac-ews (mac): Output: http://queues.webkit.org/results/13574935
Early Warning System Bot
Comment 3 2012-08-24 19:21:22 PDT
Comment on attachment 160542 [details] Love letter to EWS Attachment 160542 [details] did not pass qt-wk2-ews (qt): Output: http://queues.webkit.org/results/13591469
Andreas Kling
Comment 4 2012-08-24 19:46:38 PDT
Created attachment 160545 [details] Love letter to EWS + cheesy GCC buildfix
Andreas Kling
Comment 5 2012-09-03 09:42:55 PDT
Created attachment 161939 [details] Patch!!11
Andreas Kling
Comment 6 2012-09-03 11:21:11 PDT
I should note that there are a number of follow-up optimizations enabled by this, such as avoiding parsing the same style/class attributes more than once.
Antti Koivisto
Comment 7 2012-09-03 13:54:18 PDT
Comment on attachment 161939 [details] Patch!!11 View in context: https://bugs.webkit.org/attachment.cgi?id=161939&action=review Nice. r=me > Source/WebCore/dom/Document.cpp:6178 > +class ImmutableAttributeDataCacheKey { Document is super bloaty. Would be nice to factor this a separate file/class. > Source/WebCore/dom/Document.cpp:6192 > + bool operator!=(ImmutableAttributeDataCacheKey& other) const const > Source/WebCore/dom/Document.cpp:6235 > + if (!cacheHash || cacheIterator->second) The logic here is bit strange. I suspect it could be written in a nicer way.
Andreas Kling
Comment 8 2012-09-03 19:19:19 PDT
Andreas Kling
Comment 9 2012-09-04 05:34:10 PDT
Perf-o-matic results are in, looks like a 3.6% improvement on Parser/html5-full-render:malloc http://webkit-perf.appspot.com/graph.html#tests=[[6268923,2001,963028]]&sel=none&displayrange=7&datatype=running Booyakasha! @Antti: I agree that it can be factored better, I'll improve upon this in coming patches.
Note You need to log in before you can comment on or make changes to this bug.