RESOLVED FIXED Bug 77879
Move style related functions from NamedNodeMap to ElementAttributeData
https://bugs.webkit.org/show_bug.cgi?id=77879
Summary Move style related functions from NamedNodeMap to ElementAttributeData
Caio Marcelo de Oliveira Filho
Reported 2012-02-06 09:02:29 PST
Move style related functions from NamedNodeMap to ElementAttributeData
Attachments
Patch (8.61 KB, patch)
2012-02-06 09:07 PST, Caio Marcelo de Oliveira Filho
rniwa: review+
Caio Marcelo de Oliveira Filho
Comment 1 2012-02-06 09:07:23 PST
Ryosuke Niwa
Comment 2 2012-02-06 10:10:37 PST
Comment on attachment 125661 [details] Patch Excellent!
Caio Marcelo de Oliveira Filho
Comment 3 2012-02-06 10:37:48 PST
Tim Horton
Comment 4 2012-02-06 13:32:31 PST
This change seems to significantly (~28% or so) regress performance of the ManInBlue HTML (http://themaninblue.com/experiment/AnimationBenchmark/html/) benchmark, among others. Looking at the change, though, I'm not sure how that's possible. Could you potentially take a look at this?
Ryosuke Niwa
Comment 5 2012-02-06 14:22:20 PST
(In reply to comment #4) > This change seems to significantly (~28% or so) regress performance of the ManInBlue HTML (http://themaninblue.com/experiment/AnimationBenchmark/html/) benchmark, among others. Looking at the change, though, I'm not sure how that's possible. Could you potentially take a look at this? That's surprising. The only reason I can think of this is happening if some functions in NamedNodeMap were benefiting from ensureInlineStyleDecl, destroyInlineStyleDecl, and ensureAttributeStyle being inlined. Could you try that and see what happens?
Ryosuke Niwa
Comment 6 2012-02-06 21:32:18 PST
The regression is probably caused by additional tertiary operators in inlineStyleDecl() and friends. We should probably do this refactoring when we move m_attributeData from NamedNodeMap to Element.
Ryosuke Niwa
Comment 7 2012-02-06 23:12:22 PST
king is right. This is caused by ensureInlineStyleDecl now calling ensureAttributeData, which updates attributes, instead of ensureInlineStyleDecl, which doesn't update attributes: As a result, we're spending 2+% of time in StyledElement::style().
Tony Gentilcore
Comment 9 2012-02-07 04:03:56 PST
This appears to have regressed several of chromium's page cyclers and is a blocker for us. Would you be opposed to rolling out this patch and working on the fix off of the tree?
Tony Gentilcore
Comment 10 2012-02-07 04:04:51 PST
Tony Gentilcore
Comment 11 2012-02-07 04:09:25 PST
Actually, looks like rniwa has a proposed fix here: https://bugs.webkit.org/show_bug.cgi?id=77952
Note You need to log in before you can comment on or make changes to this bug.