Closed Bug 2092459 Opened 17 days ago Closed 12 days ago

[wpt-sync] Sync PR 64243 - Fix intrinsic widths under-invalidation for orthogonal roots

Categories

(Core :: Layout, task, P4)

task

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 64243 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/64243
Details from upstream follow.

Philip Rogers <pdr@chromium.org> wrote:

Fix intrinsic widths under-invalidation for orthogonal roots

An orthogonal flow root's block-size (determined by layout) contributes
to its container's inline-size. For orthogonal flow roots,
BlockNode::ComputeMinMaxSizes() lays out the orthogonal subtree to
determine its block-size rather than computing min/max sizes, without
clearing IntrinsicLogicalWidthsDirty() on blocks within the
orthogonal subtree (when their inline-size is definite or stretched).
Because IntrinsicLogicalWidthsDirty() is never cleared on those
blocks, InvalidateContainerIntrinsicLogicalWidths() stops early
without invalidating ancestors of the orthogonal root.
ShouldInvalidateBeyond() cannot be used here because normal blocks
nested inside the orthogonal root also remain dirty and have the same
writing-mode as the orthogonal root.

When marking the container chain for full layout in
MarkContainerChainForLayout() outside PerformLayout(), call
InvalidateContainerIntrinsicLogicalWidths() when crossing an
orthogonal writing-mode boundary (skipping this during layout so
interleaved style recalc such as container queries does not invalidate
ancestors already in layout). Also update
MarkParentForSpannerOrOutOfFlowPositionedChange() to use
SetChildNeedsLayout() (with default kMarkContainerChain) rather
than kMarkOnlyThis so that MarkContainerChainForLayout() runs and
invalidates intrinsic widths when crossing an orthogonal writing-mode
boundary.

This patch also deflakes orthogonal-parent-shrink-to-fit-001.html.

Bug: 568337130
Change-Id: I5612dbf8233ffe000510f5e323686d5293b76eda
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8522118
Auto-Submit: Philip Rogers \<pdr@chromium.org>
Reviewed-by: Ian Kilpatrick \<ikilpatrick@chromium.org>
Commit-Queue: Philip Rogers \<pdr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1733472}

Component: web-platform-tests → Layout
Product: Testing → Core

CI Results

Ran 11 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 1256 tests and 3 subtests

Status Summary

Firefox

OK : 84
PASS: 6[GitHub] 13[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt] 395[Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt] 1526[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 1529[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 1533[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt]
FAIL: 27[Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt] 48[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt] 50[Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 55[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]

Chrome

PASS: 3
FAIL: 3

Safari

PASS: 3
FAIL: 3

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

Tests Disabled in Gecko Infrastructure

Pushed by wptsync@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/92fd0d187627 https://hg.mozilla.org/integration/autoland/rev/fe386cf4c16b [wpt PR 64243] - Fix intrinsic widths under-invalidation for orthogonal roots, a=testonly
Status: NEW → RESOLVED
Closed: 12 days ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.