Bug 154242 - Optimize style invalidations for attribute selectors
Summary: Optimize style invalidations for attribute selectors
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2016-02-15 06:25 PST by Antti Koivisto
Modified: 2016-02-16 00:21 PST (History)
3 users (show)

See Also:


Attachments
patch (49.85 KB, patch)
2016-02-15 08:45 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
patch (51.47 KB, patch)
2016-02-15 09:25 PST, Antti Koivisto
kling: review+
Details | Formatted Diff | Diff
for landing (52.21 KB, patch)
2016-02-15 12:47 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff
for landing (52.10 KB, patch)
2016-02-15 12:57 PST, Antti Koivisto
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Koivisto 2016-02-15 06:25:27 PST
Currently we invalidate the whole element subtree if there are any attribute selectors for the changed attribute. We should only invalidate what is really needed.
Comment 1 Antti Koivisto 2016-02-15 08:45:48 PST
Created attachment 271344 [details]
patch
Comment 2 Radar WebKit Bug Importer 2016-02-15 08:46:01 PST
<rdar://problem/24655799>
Comment 3 Antti Koivisto 2016-02-15 09:25:35 PST
Created attachment 271345 [details]
patch
Comment 4 Andreas Kling 2016-02-15 12:08:28 PST
Comment on attachment 271345 [details]
patch

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

r=me
This is a really solid performance hack!

> Source/WebCore/style/AttributeChangeInvalidation.h:47
> +    using ClassChangeVector = Vector<AtomicStringImpl*, 4>;

why
Comment 5 Antti Koivisto 2016-02-15 12:47:48 PST
Created attachment 271360 [details]
for landing
Comment 6 Antti Koivisto 2016-02-15 12:57:08 PST
Created attachment 271361 [details]
for landing
Comment 7 Antti Koivisto 2016-02-16 00:21:33 PST
https://trac.webkit.org/r196629