Changeset 252829 in webkit
- Timestamp:
- Nov 23, 2019 5:33:49 AM (4 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r252828 r252829 1 2019-11-23 Zalan Bujtas <zalan@apple.com> 2 3 [LFC][IFC] Remove unnecessary Line::hasContent() calls in LineLayout::placeInlineItem 4 https://bugs.webkit.org/show_bug.cgi?id=204540 5 <rdar://problem/57443500> 6 7 Reviewed by Antti Koivisto. 8 9 LineLayout::placeInlineItem is hot. This shaves off ~3% on line-layout-simple.html 10 11 * layout/inlineformatting/InlineLineLayout.cpp: 12 (WebCore::Layout::LineLayout::placeInlineItem): 13 * page/FrameView.cpp: 14 (WebCore::FrameView::paintContents): 15 * page/FrameViewLayoutContext.cpp: 16 (WebCore::FrameViewLayoutContext::layoutUsingFormattingContext): 17 (WebCore::FrameViewLayoutContext::layout): 18 * rendering/updating/RenderTreeBuilder.cpp: 19 (WebCore::RenderTreeBuilder::attachToRenderElementInternal): 20 * rendering/updating/RenderTreeUpdater.cpp: 21 (WebCore::RenderTreeUpdater::updateRendererStyle): 22 1 23 2019-11-23 Antti Koivisto <antti@apple.com> 2 24 -
trunk/Source/WebCore/layout/inlineformatting/InlineLineLayout.cpp
r252696 r252829 167 167 auto currentLogicalRight = m_line.lineBox().logicalRight(); 168 168 auto itemLogicalWidth = inlineItemWidth(formattingContext(), inlineItem, currentLogicalRight); 169 auto lineIsConsideredEmpty = !m_line.hasContent() && !m_lineHasIntrusiveFloat;170 169 171 170 // Floats are special, they are intrusive but they don't really participate in the line layout context. … … 179 178 return IsEndOfLine::Yes; 180 179 } 180 auto lineIsConsideredEmpty = !m_line.hasContent() && !m_lineHasIntrusiveFloat; 181 181 if (LineBreaker().shouldWrapFloatBox(itemLogicalWidth, m_line.availableWidth() + m_line.trailingTrimmableWidth(), lineIsConsideredEmpty)) 182 182 return IsEndOfLine::Yes;
Note: See TracChangeset
for help on using the changeset viewer.