commit | f668ed6c79c55fd9641ca76bc1109d10257bac9c | [log] [tgz] |
---|---|---|
author | Rune Lillesveen <rune@opera.com> | Fri Oct 13 13:48:40 2017 |
committer | Commit Bot <commit-bot@chromium.org> | Fri Oct 13 13:48:40 2017 |
tree | 88838ca72461fd77df1ce78496db53379352cd23 | |
parent | b0e8a53a83569be65979a3984895126b2d87aac1 [diff] |
Use a singleton invalidation set for self invalidations. We used to create separate invalidation set instances for every single invalidation set which just contains InvalidatesSelf(). That is, every simple selector which only appears in the rightmost compound selector: .a {} #b:hover {} #parent > .c {} The invalidation sets for ".a", "#b", ".c", and ":hover" above are all the same with only InvalidatesSelf() set. Instead we can use a singleton invalidation set which is shared for all such invalidation sets. If we later add more features to the set, we replace the singleton with a new DescendantInvalidationSet instance with InvalidatesSelf() set and add new features to that set. This reduces memory use for invalidation sets from ~1MB to ~256kB on facebook.com (see measurements in 773880). Bug: 773880 Change-Id: I1018cea1f51628f1f940c3722cc2b48a3164a777 Reviewed-on: https://chromium-review.googlesource.com/713859 Reviewed-by: Eric Willigers <ericwilligers@chromium.org> Commit-Queue: Rune Lillesveen <rune@opera.com> Cr-Commit-Position: refs/heads/master@{#508692}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .