dynamic layout change that resizes conditionally processed outer SVG triggers "expected aContainer to be NS_FRAME_IS_DIRTY" assertion

RESOLVED FIXED in Firefox 55

Status

()

enhancement
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: dbaron, Assigned: dbaron)

Tracking

Trunk
mozilla55
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox55 fixed)

Details

Attachments

(1 attachment)

No description provided.
The primary patch in bug 1308876 causes frames to be reflowed less often
with NS_FRAME_IS_DIRTY, particularly when multiple passes of reflow are
required for the frame or one of its ancestors (which is generally the
case for a document that ends up not having scrollbars).  This change
causes this assert to fire on various SVG tests such as
layout/reftests/svg/svg-integration/conditions-outer-svg-01.xhtml .
This happens because the outer SVG with conditional processing (in this
test, systemLanguage="x") is reflowed due to its parent resizing,
without NS_FRAME_IS_DIRTY set.  This is a relatively normal thing to
happen during reflow; we just didn't have any tests that exercise it.

This patch adds a crashtest that triggers the assertion through the same
mechanism, but with a dynamic change, rather than depending on the
non-dirty reflow triggered by bug 1308876.  (I confirmed locally that
this test does trigger the assertion without this patch, when run in the
crashtest harness.)

I think fundamentally the assertion isn't valid, and we should instead
be testing the condition that it asserts.  (But I'm a little concerned
that maybe we need resize reflows to be propagated through?)

MozReview-Commit-ID: D8hjAbjKyuL
Attachment #8868844 - Flags: review?(cam)
(In reply to David Baron :dbaron: ⌚️UTC-7 from comment #1)
> I think fundamentally the assertion isn't valid, and we should instead
> be testing the condition that it asserts.  (But I'm a little concerned
> that maybe we need resize reflows to be propagated through?)

To clarify this:  I think the two obvious options are:
 (1) remove the assertion, and replace it with the test, as this patch does
 (2) remove the assertion, and replace it with nothing
Comment on attachment 8868844 [details] [diff] [review]
Replace assertion that non-display SVG containers are only reflowed with NS_FRAME_IS_DIRTY with a real test of the condition

Review of attachment 8868844 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks for the explanation, which makes sense to me.
Attachment #8868844 - Flags: review?(cam) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/4808d8fe4ea887a468fc8f1083ee51ef20f4d6ce
Bug 1365831 - Replace assertion that non-display SVG containers are only reflowed with NS_FRAME_IS_DIRTY with a real test of the condition.  r=heycam
https://hg.mozilla.org/mozilla-central/rev/4808d8fe4ea8
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
You need to log in before you can comment on or make changes to this bug.