Bug 186712

Summary: Various RenderTable classes waste Vector capacity
Product: WebKit Reporter: Simon Fraser (smfr) <simon.fraser>
Component: Layout and RenderingAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: bfulgham, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Description Simon Fraser (smfr) 2018-06-15 15:17:23 PDT
See on nytimes.com. Tooling in bug 186698.

Wasted capacity: 25920 bytes (used 1728 of 27648 bytes, utilization: 6.25%) - 432 allocations
1   0x10889d2a5 WTF::VectorBuffer<WebCore::RenderTable::ColumnStruct, 0ul>::VectorBuffer()
2   0x10889d285 WTF::Vector<WebCore::RenderTable::ColumnStruct, 0ul, WTF::CrashOnOverflow, 16ul>::Vector()
3   0x1088620f5 WTF::Vector<WebCore::RenderTable::ColumnStruct, 0ul, WTF::CrashOnOverflow, 16ul>::Vector()
4   0x108861e6e WebCore::RenderTable::RenderTable(WebCore::Element&, WebCore::RenderStyle&&)
5   0x108862435 WebCore::RenderTable::RenderTable(WebCore::Element&, WebCore::RenderStyle&&)
6   0x1086d405b std::__1::unique_ptr<WebCore::RenderTable, WebCore::RenderObjectDeleter> WebCore::createRenderer<WebCore::RenderTable, WebCore::Element&, WebCore::RenderStyle>(WebCore::Element&&&, WebCore::RenderStyle&&)
7   0x1086d28fd WebCore::RenderElement::createFor(WebCore::Element&, WebCore::RenderStyle&&, WebCore::RenderElement::RendererCreationType)
8   0x10769ea05 WebCore::Element::createElementRenderer(WebCore::RenderStyle&&, WebCore::RenderTreePosition const&)

Wasted capacity: 24752 bytes (used 3536 of 28288 bytes, utilization: 12.50%) - 442 allocations
1   0x105f1cbe5 WTF::VectorBuffer<WebCore::LayoutUnit, 0ul>::VectorBuffer()
2   0x105f1cbc5 WTF::Vector<WebCore::LayoutUnit, 0ul, WTF::CrashOnOverflow, 16ul>::Vector()
3   0x105f1c9b5 WTF::Vector<WebCore::LayoutUnit, 0ul, WTF::CrashOnOverflow, 16ul>::Vector()
4   0x10887ddac WebCore::RenderTableSection::RenderTableSection(WebCore::Document&, WebCore::RenderStyle&&)
5   0x10887de85 WebCore::RenderTableSection::RenderTableSection(WebCore::Document&, WebCore::RenderStyle&&)
6   0x10888607b std::__1::unique_ptr<WebCore::RenderTableSection, WebCore::RenderObjectDeleter> WebCore::createRenderer<WebCore::RenderTableSection, WebCore::Document&, WebCore::RenderStyle>(WebCore::Document&&&, WebCore::RenderStyle&&)
7   0x108885f2f WebCore::RenderTableSection::createTableSectionWithStyle(WebCore::Document&, WebCore::RenderStyle const&)
8   0x108886143 WebCore::RenderTableSection::createAnonymousWithParentRenderer(WebCore::RenderTable const&)

Wasted capacity: 24192 bytes (used 3456 of 27648 bytes, utilization: 12.50%) - 432 allocations
1   0x105f1cbe5 WTF::VectorBuffer<WebCore::LayoutUnit, 0ul>::VectorBuffer()
2   0x105f1cbc5 WTF::Vector<WebCore::LayoutUnit, 0ul, WTF::CrashOnOverflow, 16ul>::Vector()
3   0x105f1c9b5 WTF::Vector<WebCore::LayoutUnit, 0ul, WTF::CrashOnOverflow, 16ul>::Vector()
4   0x108861e59 WebCore::RenderTable::RenderTable(WebCore::Element&, WebCore::RenderStyle&&)
5   0x108862435 WebCore::RenderTable::RenderTable(WebCore::Element&, WebCore::RenderStyle&&)
6   0x1086d405b std::__1::unique_ptr<WebCore::RenderTable, WebCore::RenderObjectDeleter> WebCore::createRenderer<WebCore::RenderTable, WebCore::Element&, WebCore::RenderStyle>(WebCore::Element&&&, WebCore::RenderStyle&&)
7   0x1086d28fd WebCore::RenderElement::createFor(WebCore::Element&, WebCore::RenderStyle&&, WebCore::RenderElement::RendererCreationType)
8   0x10769ea05 WebCore::Element::createElementRenderer(WebCore::RenderStyle&&, WebCore::RenderTreePosition const&)
Comment 1 Simon Fraser (smfr) 2018-06-15 15:17:37 PDT
Wasted capacity: 13856 bytes (used 0 of 13856 bytes, utilization: 0.00%) - 433 allocations
1   0x1085673a1 WTF::VectorBuffer<WebCore::RenderTableCell*, 4ul>::VectorBuffer()
2   0x108567365 WTF::Vector<WebCore::RenderTableCell*, 4ul, WTF::CrashOnOverflow, 16ul>::Vector()
3   0x108557cb5 WTF::Vector<WebCore::RenderTableCell*, 4ul, WTF::CrashOnOverflow, 16ul>::Vector()
4   0x108557c17 WebCore::AutoTableLayout::AutoTableLayout(WebCore::RenderTable*)
5   0x108557cdd WebCore::AutoTableLayout::AutoTableLayout(WebCore::RenderTable*)
6   0x1088630af WebCore::RenderTable::styleDidChange(WebCore::StyleDifference, WebCore::RenderStyle const*)
7   0x1086d6d74 WebCore::RenderElement::initializeStyle()
8   0x108ab4954 WebCore::RenderTreeUpdater::createRenderer(WebCore::Element&, WebCore::RenderStyle&&)
Comment 2 Radar WebKit Bug Importer 2018-06-15 15:18:04 PDT
<rdar://problem/41174074>