Closed Bug 802628 Opened 13 years ago Closed 13 years ago

Fix broken invalidation in ReflowSVG implementations

Categories

(Core :: SVG, defect)

17 Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla20
Tracking Status
firefox18 --- fixed
firefox19 --- fixed
firefox20 --- fixed
b2g18 --- fixed

People

(Reporter: jwatt, Assigned: jwatt)

References

Details

Attachments

(2 files, 2 obsolete files)

SVG still has its own invalidation mechanisms after landing of DLBI (bug 539356). There are a bunch of SVG invalidation bugs that were caused by the landing of DLBI, mostly because DLBI and the existing SVG invalidation mechanisms don't play nicely together. Ultimately we want SVG to solely use DLBI for invalidation, and it's probably easier to implement that than to fix all the DLBI SVG invalidation regressions individually. This bug is for getting rid of the SVG invalidation mechanisms and converting SVG to use DLBI.
Blocks: 786894
Simply to make the real patches easier to read.
Attachment #692793 - Flags: review?(matt.woodrow)
Attachment #692793 - Attachment is patch: true
One of the optimization in the old SVG invalidation code was that it wouldn't bother invalidating a frame if it knew the parent frame would be invalidating since the parents overflow area would include its children. In an active layers world that's not valid since we can have active layers between the outermost dirty container and dirty children. We need to invalidate all leaf SVG frames that are dirty, and thus there's no point in invalidating SVG containers (which never paint).
Attachment #692794 - Flags: review?(matt.woodrow)
Err, this is the correct patch for that.
Attachment #692794 - Attachment is obsolete: true
Attachment #692794 - Flags: review?(matt.woodrow)
Attachment #692796 - Flags: review?(matt.woodrow)
Attachment #692793 - Flags: review?(matt.woodrow) → review+
Comment on attachment 692796 [details] [diff] [review] Fix broken invalidation in ReflowSVG implementation Review of attachment 692796 [details] [diff] [review]: ----------------------------------------------------------------- ::: layout/svg/nsSVGGlyphFrame.cpp @@ +547,5 @@ > > mState &= ~(NS_FRAME_FIRST_REFLOW | NS_FRAME_IS_DIRTY | > NS_FRAME_HAS_DIRTY_CHILDREN); > > + InvalidateFrame(); Don't we still want to at least check NS_FRAME_IS_DIRTY, and NS_FRAME_FIRST_REFLOW on the parent? Ideally though, we wouldn't ever call InvalidateFrame from reflow. The only time we should need to invalidate during reflow is if the size/overflow changes, and DLBI should pick those up automatically (using geometry comparison).
(In reply to Matt Woodrow (:mattwoodrow) from comment #4) > Don't we still want to at least check NS_FRAME_IS_DIRTY, and > NS_FRAME_FIRST_REFLOW on the parent? For leaf frames, we know that NS_FRAME_IS_DIRTY is set because otherwise we wouldn't have ended up in ReflowSVG. I guess I can keep the NS_FRAME_FIRST_REFLOW check in order to do less work. > Ideally though, we wouldn't ever call InvalidateFrame from reflow. The only > time we should need to invalidate during reflow is if the size/overflow > changes, and DLBI should pick those up automatically (using geometry > comparison). Right. Removal of the InvalidateFrame calls comes later as a follow-up. Right now I'm trying to stay close to what the current code does though to minimize risk for branch landings.
Attachment #692796 - Attachment is obsolete: true
Attachment #692796 - Flags: review?(matt.woodrow)
Attachment #692800 - Flags: review?(matt.woodrow)
Attachment #692800 - Flags: review?(matt.woodrow) → review+
Comment on attachment 692793 [details] [diff] [review] Un-inline nsSVGUtils::InvalidateAndScheduleReflowSVG Requesting approval on these two patches in order to fix bug 786894. [Approval Request Comment] Bug caused by (feature/regressing bug #): bug 776054 User impact if declined: dynamic SVG (scripted/animated) will frequently be broken Testing completed (on m-c, etc.): passed m-i and landed on m-c now Risk to taking this patch (and alternatives if risky): low String or UUID changes made by this patch: none
Attachment #692793 - Flags: approval-mozilla-beta?
Attachment #692793 - Flags: approval-mozilla-aurora?
Attachment #692800 - Flags: approval-mozilla-beta?
Attachment #692800 - Flags: approval-mozilla-aurora?
Comment on attachment 692793 [details] [diff] [review] Un-inline nsSVGUtils::InvalidateAndScheduleReflowSVG Approving on aurora/beta as its a low risk patch for an SVG regression only on FF18/19.
Attachment #692793 - Flags: approval-mozilla-beta?
Attachment #692793 - Flags: approval-mozilla-beta+
Attachment #692793 - Flags: approval-mozilla-aurora?
Attachment #692793 - Flags: approval-mozilla-aurora+
Attachment #692800 - Flags: approval-mozilla-beta?
Attachment #692800 - Flags: approval-mozilla-beta+
Attachment #692800 - Flags: approval-mozilla-aurora?
Attachment #692800 - Flags: approval-mozilla-aurora+
Landed both part 1 and 2 on beta: https://hg.mozilla.org/releases/mozilla-beta/rev/76c63f26ba46 https://hg.mozilla.org/releases/mozilla-beta/rev/f887c6fc51d7 Aurora is currently closed, so I'll land on it later.
To make regression tracking cleaner given the patches landed on branches I'm closing this bug and have opened bug 827915 for the remaining work.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Summary: Convert SVG invalidation to DLBI → Fix broken invalidation in ReflowSVG implementations
Whiteboard: [leave open]
Target Milestone: --- → mozilla20
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: