Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Issue 639433002: Drop InvalidationSetMode. (Closed)

Created:
6 years, 2 months ago by rune
Modified:
6 years, 1 month ago
Reviewers:
chrishtr, esprehn
CC:
darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, dglazkov+blink, ed+blinkwatch_opera.com, rwlbuis, rune+blink
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Project:
blink
Visibility:
Public.

Description

Drop InvalidationSetMode. *** NOT FOR LANDING *** This is a demonstration of the end result of allowing all selectors to update invalidation sets using updateInvalidationSets and never fall back to a separate wholesubtree loop in collectFeaturesFromSelector. The method for finding the InvalidationSetMode can be dropped completely, handling selectors without features and selectors requiring subtree recalcs when extracting the features instead. By introducing a flag for crossing insertion points, the only special handling left is to "clear" the InvalidationSetFeatures, and use a subtree recalc when finding a ::first-line, ::first-letter, or :host-context in the right-most compound selector. There are a bunch of pseudo classes/elements which are white-listed in this CL which needs to be white-listed on a case-by-case basis backed up with tests, but there were no tests failing locally. I've added switch-asserts causing compile errors if added selector types are neither white- nor black-listed. I have renamed the "wholeSubtree" flag to "adjacent" since it keeps track of whether the last seen combinator was an adjacent combinator. RuleFeaturesSet::collectFeaturesFromSelector is now back to how it was before we introduced invalidation sets (without the feature hash sets). Now, it only counts adjacent combinators and sets a flag when finding ::first-line, so it is possible to squash it into the same method as updateInvalidationSets() to have a single pass over the selector when finding rule features.

Patch Set 1 #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+264 lines, -195 lines) Patch
M LayoutTests/fast/css/invalidation/targeted-class-host-context.html View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/css/CSSSelector.h View 2 chunks +15 lines, -1 line 0 comments Download
M Source/core/css/RuleFeature.h View 1 chunk +20 lines, -13 lines 0 comments Download
M Source/core/css/RuleFeature.cpp View 11 chunks +198 lines, -180 lines 1 comment Download
M Source/core/css/invalidation/DescendantInvalidationSet.h View 2 chunks +6 lines, -0 lines 0 comments Download
M Source/core/css/invalidation/DescendantInvalidationSet.cpp View 4 chunks +7 lines, -0 lines 0 comments Download
M Source/core/css/invalidation/StyleInvalidator.h View 5 chunks +6 lines, -0 lines 0 comments Download
M Source/core/css/invalidation/StyleInvalidator.cpp View 3 chunks +11 lines, -0 lines 0 comments Download

Messages

Total messages: 5 (1 generated)
rune
@chrishtr, @esprehn: I'm trying to make invalidation set generation more straight-forward and understandable with less ...
6 years, 2 months ago (2014-10-07 14:36:51 UTC) #2
chrishtr
Looks like a nice improvement. https://codereview.chromium.org/639433002/diff/1/Source/core/css/RuleFeature.cpp File Source/core/css/RuleFeature.cpp (right): https://codereview.chromium.org/639433002/diff/1/Source/core/css/RuleFeature.cpp#newcode282 Source/core/css/RuleFeature.cpp:282: features.hasFeatures = false; It's ...
6 years, 2 months ago (2014-10-10 16:45:06 UTC) #3
rune
On 2014/10/10 16:45:06, chrishtr wrote: > Looks like a nice improvement. Thanks! Unless @esprehn has ...
6 years, 2 months ago (2014-10-13 07:56:41 UTC) #4
rune
6 years, 1 month ago (2014-11-13 13:30:05 UTC) #5
Message was sent while issue was closed.
Closed as this has now been replaced by smaller CLs. All but [1] landed.

[1] https://codereview.chromium.org/726503003

Powered by Google App Engine
This is Rietveld 408576698