DescriptionImprove positioned/percentHeight descendant/container tracking
- Add LayoutBoxRareData::m_percentHeightContainer to track percent height
containers.
(rare rate: 1.52% based on top 10k sites -- Run 402
https://ct.skia.org/chromium_perf_runs/ )
- Still use global maps to track percent height descendants, positioned
descendants and positioned containers, but add bit field to indicate if
descendants set exists for a LayoutBlock to avoid hash lookups if the
block doesn't have percent-height or positioned descendants.
- As a positioned box has only one positioned container at a time, positioned
container map is simplified to HashMap<LayoutBox*, LayoutBlock*> instead of
HashMap<LayoutBox*, HashSet<LayoutBlock*>>. Also modify code to handle
previously (unnecessarily) multiple containers situation.
This will improve blink_perf.layout tests performance by 0%~20%:
http://storage.googleapis.com/chromium-telemetry/html-results/results-2016-01-10_00-31-59
http://storage.googleapis.com/chromium-telemetry/html-results/results-2016-01-10_11-52-52
More discussions: https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/xWMmQfD_X0A
Committed: https://crrev.com/0ba5554bd01f1f3dd94f38375d02f234e683c9ca
Cr-Commit-Position: refs/heads/master@{#371388}
Patch Set 1 #Patch Set 2 : #Patch Set 3 : #Patch Set 4 : #Patch Set 5 : #Patch Set 6 : Raredata #Patch Set 7 : #Patch Set 8 : #Patch Set 9 : virtual destructor #
Total comments: 6
Patch Set 10 : #Patch Set 11 : #Patch Set 12 : Keep map #Patch Set 13 : #Patch Set 14 : Fix windows build break #
Total comments: 12
Patch Set 15 : #
Total comments: 2
Patch Set 16 : #Messages
Total messages: 43 (20 generated)
|