Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: f6831edd45a88907a4cf1d3d3d690338fb1db597
      
https://github.com/WebKit/WebKit/commit/f6831edd45a88907a4cf1d3d3d690338fb1db597
  Author: Brandon Stewart <[email protected]>
  Date:   2024-07-12 (Fri, 12 Jul 2024)

  Changed paths:
    M Source/WebCore/rendering/GridTrackSizingAlgorithm.cpp
    M Source/WebCore/rendering/GridTrackSizingAlgorithm.h

  Log Message:
  -----------
  [masonry] Optimize grid items with a span 1
https://bugs.webkit.org/show_bug.cgi?id=276385
rdar://problem/131407028

Reviewed by Sammy Gill.

General Case: grouping auto-placed items by span size -> Nitems + Ntracks x 
Nspans
- compute aggregate items (Nitems)
- apply to tracks (Ntracks x Nspans)

This implements the algorithm for single track items. Items that span multiple 
tracks
and items that are 'fr' will be handled in a follow up patch.

Runtime on microbenchark was reduced from 1.2 seconds to 38 ms.
Benchmark tested 1000 columns with 'auto' and 10,000 grid items.
Tested on M1 Ultra.

* Source/WebCore/rendering/GridTrackSizingAlgorithm.cpp:
(WebCore::GridTrackSizingAlgorithm::accumulateIntrinsicSizesForTrack):
(WebCore::GridTrackSizingAlgorithm::resolveIntrinsicTrackSizes):
* Source/WebCore/rendering/GridTrackSizingAlgorithm.h:

Canonical link: https://commits.webkit.org/280919@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to