Bug 61038 - Web Inspector: Serious performance regression during continuous focused element style updates
Summary: Web Inspector: Serious performance regression during continuous focused eleme...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Alexander Pavlov (apavlov)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-18 04:24 PDT by Alexander Pavlov (apavlov)
Modified: 2011-06-15 13:35 PDT (History)
14 users (show)

See Also:


Attachments
[PATCH] Suggested solution (3.87 KB, patch)
2011-05-18 07:41 PDT, Alexander Pavlov (apavlov)
webkit.review.bot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ec2-cr-linux-02 (1.15 MB, application/zip)
2011-05-18 11:29 PDT, WebKit Review Bot
no flags Details
[PATCH] A different approach applied (20.60 KB, patch)
2011-05-19 09:48 PDT, Alexander Pavlov (apavlov)
webkit.review.bot: commit-queue-
Details | Formatted Diff | Diff
[PATCH] Offline comments addressed (22.18 KB, patch)
2011-05-20 06:56 PDT, Alexander Pavlov (apavlov)
no flags Details | Formatted Diff | Diff
[PATCH] Rebase (20.03 KB, patch)
2011-06-09 03:26 PDT, Alexander Pavlov (apavlov)
pfeldman: review-
Details | Formatted Diff | Diff
[PATCH] Comments addressed (21.06 KB, patch)
2011-06-15 08:56 PDT, Alexander Pavlov (apavlov)
pfeldman: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Pavlov (apavlov) 2011-05-18 04:24:38 PDT
Upstreaming http://code.google.com/p/chromium/issues/detail?id=82449
Comment 1 Alexander Pavlov (apavlov) 2011-05-18 07:41:30 PDT
Created attachment 93912 [details]
[PATCH] Suggested solution
Comment 2 WebKit Review Bot 2011-05-18 11:29:27 PDT
Comment on attachment 93912 [details]
[PATCH] Suggested solution

Attachment 93912 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/8708641

New failing tests:
inspector/styles/styles-disable-then-change.html
inspector/elements/elements-delete-inline-style.html
inspector/styles/styles-update-from-js.html
Comment 3 WebKit Review Bot 2011-05-18 11:29:32 PDT
Created attachment 93950 [details]
Archive of layout-test-results from ec2-cr-linux-02

The attached test failures were seen while running run-webkit-tests on the chromium-ews.
Bot: ec2-cr-linux-02  Port: Chromium  Platform: Linux-2.6.35-28-virtual-x86_64-with-Ubuntu-10.10-maverick
Comment 4 Alexander Pavlov (apavlov) 2011-05-19 09:48:01 PDT
Created attachment 94080 [details]
[PATCH] A different approach applied
Comment 5 WebKit Review Bot 2011-05-19 09:53:12 PDT
Comment on attachment 94080 [details]
[PATCH] A different approach applied

Attachment 94080 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/8716355
Comment 6 WebKit Review Bot 2011-05-19 09:56:46 PDT
Comment on attachment 94080 [details]
[PATCH] A different approach applied

Attachment 94080 [details] did not pass mac-ews (mac):
Output: http://queues.webkit.org/results/8718226
Comment 7 Early Warning System Bot 2011-05-19 09:57:06 PDT
Comment on attachment 94080 [details]
[PATCH] A different approach applied

Attachment 94080 [details] did not pass qt-ews (qt):
Output: http://queues.webkit.org/results/8716358
Comment 8 WebKit Review Bot 2011-05-19 10:45:53 PDT
Comment on attachment 94080 [details]
[PATCH] A different approach applied

Attachment 94080 [details] did not pass cr-mac-ews (chromium):
Output: http://queues.webkit.org/results/8719129
Comment 9 Alexander Pavlov (apavlov) 2011-05-20 06:56:49 PDT
Created attachment 94214 [details]
[PATCH] Offline comments addressed
Comment 10 Alexander Pavlov (apavlov) 2011-06-09 03:26:05 PDT
Created attachment 96567 [details]
[PATCH] Rebase

@reviewers: ping
Comment 11 Pavel Feldman 2011-06-15 04:49:32 PDT
Comment on attachment 96567 [details]
[PATCH] Rebase

View in context: https://bugs.webkit.org/attachment.cgi?id=96567&action=review

A number of small nits and a test request.

> Source/WebCore/inspector/Inspector.json:787
> +                "id": "DOMNodeAttributes",

Attributes. We can also rename DOMNode and DOMEventListener since type names have domain scope.

> Source/WebCore/inspector/Inspector.json:790
> +                    { "name": "id", "type": "integer", "description": "Node id." },

Element id to get attributes for.

> Source/WebCore/inspector/Inspector.json:987
> +                "name": "getNodeAttributes",

getAttributes

> Source/WebCore/inspector/Inspector.json:1013
> +                    { "name": "nodeId", "type": "integer", "description": "Id of the node that has changed." }

You might want to leave this as is for performance considerations.

> Source/WebCore/inspector/Inspector.json:1018
> +                "name": "inlineStyleInvalidated",

Please add a test for this new event.

> Source/WebCore/inspector/InspectorDOMAgent.cpp:255
> +    m_domAgent->notifyStyleAttrInvalidated(elements);

StyleAttributeInvalidated (no abbreaviations in WebCore)
Comment 12 Alexander Pavlov (apavlov) 2011-06-15 07:06:52 PDT
Comment on attachment 96567 [details]
[PATCH] Rebase

View in context: https://bugs.webkit.org/attachment.cgi?id=96567&action=review

A fixed patch to be attached shortly

>> Source/WebCore/inspector/Inspector.json:787
>> +                "id": "DOMNodeAttributes",
> 
> Attributes. We can also rename DOMNode and DOMEventListener since type names have domain scope.

Done. I believe it's better to address the other renames in a separate change (in case we have to merge/roll back this or related changes).

>> Source/WebCore/inspector/Inspector.json:790
>> +                    { "name": "id", "type": "integer", "description": "Node id." },
> 
> Element id to get attributes for.

Done

>> Source/WebCore/inspector/Inspector.json:987
>> +                "name": "getNodeAttributes",
> 
> getAttributes

Done

>> Source/WebCore/inspector/Inspector.json:1013
>> +                    { "name": "nodeId", "type": "integer", "description": "Id of the node that has changed." }
> 
> You might want to leave this as is for performance considerations.

This is one of the main points of this change. With the Flickr demo, you get a constant high-volume traffic of updated attributes ("style" in particular) the Web Inspector is not coping with (parsing + handling).

>> Source/WebCore/inspector/Inspector.json:1018
>> +                "name": "inlineStyleInvalidated",
> 
> Please add a test for this new event.

Will do

>> Source/WebCore/inspector/InspectorDOMAgent.cpp:255
>> +    m_domAgent->notifyStyleAttrInvalidated(elements);
> 
> StyleAttributeInvalidated (no abbreaviations in WebCore)

Done
Comment 13 Alexander Pavlov (apavlov) 2011-06-15 08:56:31 PDT
Created attachment 97301 [details]
[PATCH] Comments addressed
Comment 14 Alexander Pavlov (apavlov) 2011-06-15 10:03:09 PDT
Committed r88950: <http://trac.webkit.org/changeset/88950>
Comment 15 Ryosuke Niwa 2011-06-15 13:34:33 PDT
inspector/styles/styles-update-from-js.html has been failing on GTK since this patch was landed:
http://build.webkit.org/builders/GTK%20Linux%2064-bit%20Debug/builds/23400
http://build.webkit.org/results/GTK%20Linux%2064-bit%20Debug/r88953%20(23400)/results.html
Comment 16 Ryosuke Niwa 2011-06-15 13:35:04 PDT
+mrobinson since this patch caused a test failure on GTK.