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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutBlock.cpp

Issue 1577433003: Statistics of LayoutBox rare data reasons Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: - Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/layout/LayoutBlock.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutBlock.cpp b/third_party/WebKit/Source/core/layout/LayoutBlock.cpp
index 2a970993c83368ec5dcfb32438c3eac7fea2f8c5..ae153d2bdcf935728c759f82f369cd39e7234e64 100644
--- a/third_party/WebKit/Source/core/layout/LayoutBlock.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutBlock.cpp
@@ -103,6 +103,7 @@ LayoutBlock::LayoutBlock(ContainerNode* node)
m_paginationStateChanged(false) {
// LayoutBlockFlow calls setChildrenInline(true).
// By default, subclasses do not have inline children.
+ m_rareStat.addReason(ReasonLBLAll);
}
void LayoutBlock::removeFromGlobalMaps() {
@@ -955,6 +956,9 @@ void LayoutBlock::insertPositionedObject(LayoutBox* o) {
}
descendantSet->insert(o);
+ o->m_rareStat.addReason(ReasonLBPositionedContainer);
+ m_rareStat.addReason(ReasonLBLPositionedDescendants);
+
m_hasPositionedObjects = true;
}
@@ -1064,6 +1068,8 @@ void LayoutBlock::addPercentHeightDescendant(LayoutBox* descendant) {
}
descendantSet->insert(descendant);
+ m_rareStat.addReason(ReasonLBLPercentHeightDescendants);
+
m_hasPercentHeightDescendants = true;
}
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutBlockFlow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698