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

Issue 2569733003: Use hash set instead of vector for changed RuleSets. (Closed)

Created:
4 years ago by rune
Modified:
4 years ago
Reviewers:
esprehn, sashab
CC:
darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, blink-reviews-dom_chromium.org, blink-reviews-style_chromium.org, chromium-reviews, dglazkov+blink, eae+blinkwatch, rwlbuis, sof
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Use hash set instead of vector for changed RuleSets. That way, we don't have to consider the same RuleSet multiple times for invalidation on active stylesheet update. This fixes a regression in PerformanceTests/CSS/StyleSheetInsert.html which would have been introduced by https://codereview.chromium.org/2557533005 This works because the same style element source text used multiple times will make us use the same StyleSheetContents from the cache and hence the same RuleSet for all 50 sheets added in that test. It's a bit like cheating, but this will also make sure we don't invalidate for the same RuleSet twice if we re-order stylesheets by removing/inserting a style element where the CSSStyleSheet pointer will be different, but the RuleSet stays the same. R=sashab@chromium.org,esprehn@chromium.org BUG=567021 Committed: https://crrev.com/5eefd373b4c293d23cb5f69a7e2fc0620eaead3b Cr-Commit-Position: refs/heads/master@{#438062}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+52 lines, -49 lines) Patch
M third_party/WebKit/Source/core/css/ActiveStyleSheets.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/css/ActiveStyleSheets.cpp View 4 chunks +18 lines, -15 lines 0 comments Download
M third_party/WebKit/Source/core/css/ActiveStyleSheetsTest.cpp View 13 chunks +25 lines, -25 lines 0 comments Download
M third_party/WebKit/Source/core/dom/StyleEngine.h View 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/dom/StyleEngine.cpp View 4 chunks +4 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/core/dom/StyleEngineTest.cpp View 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 13 (8 generated)
rune
ptal
4 years ago (2016-12-12 22:05:53 UTC) #3
esprehn
For real world content this might be a bit slower, but it does scale better. ...
4 years ago (2016-12-12 22:08:09 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2569733003/1
4 years ago (2016-12-13 05:13:51 UTC) #8
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years ago (2016-12-13 05:19:52 UTC) #11
commit-bot: I haz the power
4 years ago (2016-12-13 05:24:53 UTC) #13
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/5eefd373b4c293d23cb5f69a7e2fc0620eaead3b
Cr-Commit-Position: refs/heads/master@{#438062}

Powered by Google App Engine
This is Rietveld 408576698