[css-grid] Assertion failure: false (MOZ_ASSERT_UNREACHABLE: unexpected child reflow status) [@ nsGridContainerFrame::ReflowRowsInFragmentainer]

NEW
Assigned to

Status

()

Core
Layout
P4
minor
16 days ago
15 days ago

People

(Reporter: tsmith, Assigned: mats)

Tracking

(Blocks: 1 bug, {assertion, testcase})

58 Branch
assertion, testcase
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite ?

Firefox Tracking Flags

(firefox-esr52 wontfix, firefox56 wontfix, firefox57 wontfix, firefox58 fix-optional)

Details

Attachments

(1 attachment)

(Reporter)

Description

16 days ago
Created attachment 8926602 [details]
testcase.html

Assertion failure: false (MOZ_ASSERT_UNREACHABLE: unexpected child reflow status), at /src/layout/generic/nsGridContainerFrame.cpp:5526

#0 nsGridContainerFrame::ReflowRowsInFragmentainer(nsGridContainerFrame::GridReflowInput&, mozilla::LogicalRect const&, mozilla::ReflowOutput&, nsReflowStatus&, nsGridContainerFrame::Fragmentainer&, nsSize const&, nsTArray<nsGridContainerFrame::GridItemInfo const*> const&, unsigned int, unsigned int, int, int) /src/layout/generic/nsGridContainerFrame.cpp:5403:59
#1 nsGridContainerFrame::ReflowInFragmentainer(nsGridContainerFrame::GridReflowInput&, mozilla::LogicalRect const&, mozilla::ReflowOutput&, nsReflowStatus&, nsGridContainerFrame::Fragmentainer&, nsSize const&) /src/layout/generic/nsGridContainerFrame.cpp:5371:10
#2 nsGridContainerFrame::ReflowChildren(nsGridContainerFrame::GridReflowInput&, mozilla::LogicalRect const&, mozilla::ReflowOutput&, nsReflowStatus&) /src/layout/generic/nsGridContainerFrame.cpp:5687:13
#3 nsGridContainerFrame::Reflow(nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&) /src/layout/generic/nsGridContainerFrame.cpp:6000:11
#4 nsBlockReflowContext::ReflowBlock(mozilla::LogicalRect const&, bool, nsCollapsingMargin&, int, bool, nsLineBox*, mozilla::ReflowInput&, nsReflowStatus&, mozilla::BlockReflowInput&) /src/layout/generic/nsBlockReflowContext.cpp:306:11
#5 nsBlockFrame::ReflowBlockFrame(mozilla::BlockReflowInput&, nsLineList_iterator, bool*) /src/layout/generic/nsBlockFrame.cpp:3477:11
#6 nsBlockFrame::ReflowLine(mozilla::BlockReflowInput&, nsLineList_iterator, bool*) /src/layout/generic/nsBlockFrame.cpp:2826:5
#7 nsBlockFrame::ReflowDirtyLines(mozilla::BlockReflowInput&) /src/layout/generic/nsBlockFrame.cpp:2365:7
#8 nsBlockFrame::Reflow(nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&) /src/layout/generic/nsBlockFrame.cpp:1236:3
#9 nsContainerFrame::ReflowChild(nsIFrame*, nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, mozilla::WritingMode const&, mozilla::LogicalPoint const&, nsSize const&, unsigned int, nsReflowStatus&, nsOverflowContinuationTracker*) /src/layout/generic/nsContainerFrame.cpp:937:14
#10 nsColumnSetFrame::ReflowChildren(mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&, nsColumnSetFrame::ReflowConfig const&, bool, nsCollapsingMargin*, nsColumnSetFrame::ColumnBalanceData&) /src/layout/generic/nsColumnSetFrame.cpp:810:7
#11 nsColumnSetFrame::ReflowColumns(mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&, nsColumnSetFrame::ReflowConfig&, bool, nsCollapsingMargin*, nsColumnSetFrame::ColumnBalanceData&) /src/layout/generic/nsColumnSetFrame.cpp:507:19
#12 nsColumnSetFrame::FindBestBalanceBSize(mozilla::ReflowInput const&, nsPresContext*, nsColumnSetFrame::ReflowConfig&, nsColumnSetFrame::ColumnBalanceData&, mozilla::ReflowOutput&, nsCollapsingMargin&, bool&, bool&, nsReflowStatus&) /src/layout/generic/nsColumnSetFrame.cpp:1146:16
#13 nsColumnSetFrame::Reflow(nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&) /src/layout/generic/nsColumnSetFrame.cpp:1253:5
#14 nsContainerFrame::ReflowChild(nsIFrame*, nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, mozilla::WritingMode const&, mozilla::LogicalPoint const&, nsSize const&, unsigned int, nsReflowStatus&, nsOverflowContinuationTracker*) /src/layout/generic/nsContainerFrame.cpp:937:14
#15 nsCanvasFrame::Reflow(nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&) /src/layout/generic/nsCanvasFrame.cpp:759:5
#16 nsContainerFrame::ReflowChild(nsIFrame*, nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, mozilla::WritingMode const&, mozilla::LogicalPoint const&, nsSize const&, unsigned int, nsReflowStatus&, nsOverflowContinuationTracker*) /src/layout/generic/nsContainerFrame.cpp:937:14
#17 nsHTMLScrollFrame::ReflowScrolledFrame(mozilla::ScrollReflowInput*, bool, bool, mozilla::ReflowOutput*, bool) /src/layout/generic/nsGfxScrollFrame.cpp:551:3
#18 nsHTMLScrollFrame::ReflowContents(mozilla::ScrollReflowInput*, mozilla::ReflowOutput const&) /src/layout/generic/nsGfxScrollFrame.cpp:663:3
#19 nsHTMLScrollFrame::Reflow(nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&) /src/layout/generic/nsGfxScrollFrame.cpp:1040:3
#20 nsContainerFrame::ReflowChild(nsIFrame*, nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, int, int, unsigned int, nsReflowStatus&, nsOverflowContinuationTracker*) /src/layout/generic/nsContainerFrame.cpp:981:14
#21 mozilla::ViewportFrame::Reflow(nsPresContext*, mozilla::ReflowOutput&, mozilla::ReflowInput const&, nsReflowStatus&) /src/layout/generic/ViewportFrame.cpp:333:7
#22 mozilla::PresShell::DoReflow(nsIFrame*, bool) /src/layout/base/PresShell.cpp:8989:11
#23 mozilla::PresShell::ProcessReflowCommands(bool) /src/layout/base/PresShell.cpp:9162:24
#24 mozilla::PresShell::DoFlushPendingNotifications(mozilla::ChangesToFlush) /src/layout/base/PresShell.cpp:4233:11
#25 nsRefreshDriver::Tick(long, mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:1921:16
#26 mozilla::RefreshDriverTimer::TickRefreshDrivers(long, mozilla::TimeStamp, nsTArray<RefPtr<nsRefreshDriver> >&) /src/layout/base/nsRefreshDriver.cpp:306:7
#27 mozilla::RefreshDriverTimer::Tick(long, mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:327:5
#28 mozilla::VsyncRefreshDriverTimer::RunRefreshDrivers(mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:769:5
#29 mozilla::VsyncRefreshDriverTimer::RefreshDriverVsyncObserver::TickRefreshDriver(mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:682:35
#30 mozilla::VsyncRefreshDriverTimer::RefreshDriverVsyncObserver::ParentProcessVsyncNotifier::Run() /src/layout/base/nsRefreshDriver.cpp:528:20
#31 nsThread::ProcessNextEvent(bool, bool*) /src/xpcom/threads/nsThread.cpp:1037:14
#32 NS_ProcessNextEvent(nsIThread*, bool) /src/xpcom/threads/nsThreadUtils.cpp:513:10
#33 mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) /src/ipc/glue/MessagePump.cpp:97:21
#34 MessageLoop::RunInternal() /src/ipc/chromium/src/base/message_loop.cc:326:10
#35 MessageLoop::Run() /src/ipc/chromium/src/base/message_loop.cc:299:3
#36 nsBaseAppShell::Run() /src/widget/nsBaseAppShell.cpp:158:27
#37 nsAppStartup::Run() /src/toolkit/components/startup/nsAppStartup.cpp:288:30
#38 XREMain::XRE_mainRun() /src/toolkit/xre/nsAppRunner.cpp:4664:22
#39 XREMain::XRE_main(int, char**, mozilla::BootstrapConfig const&) /src/toolkit/xre/nsAppRunner.cpp:4826:8
#40 XRE_main(int, char**, mozilla::BootstrapConfig const&) /src/toolkit/xre/nsAppRunner.cpp:4921:21
#41 do_main(int, char**, char**) /src/browser/app/nsBrowserApp.cpp:231:22
#42 main /src/browser/app/nsBrowserApp.cpp:304:16
#43 __libc_start_main /build/glibc-bfm8X4/glibc-2.23/csu/../csu/libc-start.c:291
#44 _start (firefox+0x41ebe4)
Flags: in-testsuite?
I suspect Mats is the best person to look at this :). Any chance you have the time?

(No rush, not sure how worrisome is this bug off-hand, just thought you may want to know about it)
Flags: needinfo?(mats)
Goes back more than a year.
Has Regression Range: --- → no
status-firefox56: --- → wontfix
status-firefox57: --- → wontfix
status-firefox58: affected → fix-optional
status-firefox-esr52: --- → wontfix
Priority: -- → P3
(Assignee)

Comment 3

15 days ago
We have this frame tree:
            GridContainer(body)<
              GridContainer(output)<
                GridContainer(li)<>

The <li> has 'page-break-after', which we propagate to the container, here:
http://searchfox.org/mozilla-central/rev/c99d035f00dd894feff38e4ad28a73fb679c63a6/layout/generic/nsGridContainerFrame.cpp#5259
It was intended for a block reflow context really, but I guess we need
to deal with it in a grid context too.  Probably by either propagating
it again (last row), or growing the current row and restarting it.

It looks rather harmless in non-debug builds though -- we might neglect
to enforce a requested page break.

Let me know if this blocks fuzzing and I'll downgrade it to a non-fatal
assertion.
Assignee: nobody → mats
Blocks: 1144096
Severity: normal → minor
Flags: needinfo?(mats)
OS: Unspecified → All
Priority: P3 → P4
Hardware: Unspecified → All
Summary: Assertion failure: false (MOZ_ASSERT_UNREACHABLE: unexpected child reflow status) [@ nsGridContainerFrame::ReflowRowsInFragmentainer] → [css-grid] Assertion failure: false (MOZ_ASSERT_UNREACHABLE: unexpected child reflow status) [@ nsGridContainerFrame::ReflowRowsInFragmentainer]
You need to log in before you can comment on or make changes to this bug.