Bug 78220 - Avoid unnecessary work when evaluating style sharing candidates.
Summary: Avoid unnecessary work when evaluating style sharing candidates.
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Andreas Kling
Depends on: 78274 80245
Blocks: 78070
  Show dependency treegraph
Reported: 2012-02-09 03:51 PST by Andreas Kling
Modified: 2012-03-04 23:51 PST (History)
5 users (show)

See Also:

Proposed patch (6.33 KB, patch)
2012-02-09 04:25 PST, Andreas Kling
koivisto: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Kling 2012-02-09 03:51:06 PST
CSSStyleSelector::canShareStyleWithElement() has gathered a fair bit of cruft, we can reorder parts of it, and avoid some bits altogether.
Comment 1 Andreas Kling 2012-02-09 04:25:10 PST
Created attachment 126277 [details]
Proposed patch
Comment 2 Andreas Kling 2012-02-09 10:56:52 PST
Committed r107261: <http://trac.webkit.org/changeset/107261>
Comment 3 Julien Chaffraix 2012-02-09 13:05:07 PST
Reopening as I rolled the change out in r107279.

This test started failing after the change:


Visually, it looked like the wrong lang() selector was applied: the test assumes we apply the lang(fr) one but we were applying lang(en) after the change.
Comment 4 Andreas Kling 2012-02-13 02:24:06 PST
Relanded in <http://trac.webkit.org/changeset/107551> without breaking the lang() selector.