Bug 15340

Summary: Avoid uselessly serializing CSS property values on replacement for 10% CK DOM speedup
Product: WebKit Reporter: Maciej Stachowiak <mjs>
Component: CSSAssignee: Maciej Stachowiak <mjs>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 523.x (Safari 3)   
Hardware: Mac   
OS: OS X 10.4   
URL: http://celtickane.com/projects/jsspeed2007.php
Attachments:
Description Flags
do it
mitz: review+
for reference, without the extraneous bits none

Description Maciej Stachowiak 2007-10-02 01:23:58 PDT
When a CSS property value is replaced in any way, the old property is first removed. removeProperty returns the old property value because that is what the CSSOM calls for. But we can just use an internal version in this case that does not bother to generate the return value, since serializing the property value can be expensive.
Comment 1 Maciej Stachowiak 2007-10-02 01:26:12 PDT
Created attachment 16499 [details]
do it
Comment 2 mitz 2007-10-02 01:31:40 PDT
Comment on attachment 16499 [details]
do it

The patch includes extra changes unrelated to this bug. r=me on the CSSMutableStyleDeclaration change.
Comment 3 Maciej Stachowiak 2007-10-02 02:23:00 PDT
Oops. the markup.cpp changes are from another bug.
Comment 4 Maciej Stachowiak 2007-10-02 20:56:46 PDT
Created attachment 16511 [details]
for reference, without the extraneous bits