WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
76591
Cache and reuse the NodeList returned by Node::childNodes().
https://bugs.webkit.org/show_bug.cgi?id=76591
Summary
Cache and reuse the NodeList returned by Node::childNodes().
Andreas Kling
Reported
2012-01-18 17:44:31 PST
We already cache the DynamicNodeList::Caches on NodeRareData, we should cache the entire ChildNodeList instead of recreating it every time to reduce memory consumption and match the behavior of other browsers.
Attachments
Patch
(13.52 KB, patch)
2012-01-18 18:18 PST
,
Andreas Kling
rniwa
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Andreas Kling
Comment 1
2012-01-18 18:18:11 PST
Created
attachment 123048
[details]
Patch
Ryosuke Niwa
Comment 2
2012-01-18 18:30:03 PST
Comment on
attachment 123048
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=123048&action=review
Could you clarify that new behavior matches FF/Opera as discussed on IRC?
> Source/WebCore/dom/ChildNodeList.h:44 > + void reset() { m_caches->reset(); }
We should move m_caches to DynamicNodList. Once we do that, we can just call DyanmicNodeList::invalidateCache instead.
Ryosuke Niwa
Comment 3
2012-01-18 18:34:34 PST
Comment on
attachment 123048
[details]
Patch kling says he'll do the m_caches move in a follow up. r=me provided the change log entry is updated to mention the improved compatibility with other browsers.
Andreas Kling
Comment 4
2012-01-18 18:55:14 PST
Committed
r105372
: <
http://trac.webkit.org/changeset/105372
>
Adam Barth
Comment 5
2012-02-17 15:16:41 PST
***
Bug 17184
has been marked as a duplicate of this bug. ***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug