forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[LayoutNG] Fork NGLineBreaker::HandleText() for min-content
This patch forks NGLineBreaker::HandleText() to a specialized version for min-content. Only the longest word in the text is relevant to min-content. In order to avoid looping NGLineBreaker::NextLine as many times as the number of lines for zero available width, the new forked |HandleTextForFastMinContent()| creates one line (NGInlineItemResult) for each text node which contains the width of the longest word. This patch improves: line-layout-fit-content.html: ~10% line-layout-fit-content-break-word.html: ~35% in blink_perf.layout_ng: https://pinpoint-dot-chromeperf.appspot.com/job/13ce0c69540000 loading.desktop_layout_ng looks mostly noise: https://pinpoint-dot-chromeperf.appspot.com/job/14ff8a3a540000 Bug: 919123 Change-Id: I502318928c811d2ecf7645c553ddb180c0424fdf Reviewed-on: https://chromium-review.googlesource.com/c/1421420 Reviewed-by: Emil A Eklund <eae@chromium.org> Reviewed-by: Morten Stenshorne <mstensho@chromium.org> Commit-Queue: Koji Ishii <kojii@chromium.org> Cr-Commit-Position: refs/heads/master@{#625062}
- Loading branch information
Showing
4 changed files
with
113 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters