Bug 42408

Summary: Assertion when turning Accelerated Compositing off on a composited page
Product: WebKit Reporter: Simon Fraser (smfr) <simon.fraser>
Component: Layout and RenderingAssignee: Simon Fraser (smfr) <simon.fraser>
Status: RESOLVED FIXED    
Severity: Normal CC: darin, kbalazs, qi.2.zhang, simon.fraser
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
Attachments:
Description Flags
Patch sam: review+

Simon Fraser (smfr)
Reported 2010-07-15 14:33:22 PDT
When turning off Accelerated Compositing, we hit one of the ASSERT(willBeComposited == needsToBeComposited(layer)); assertions in RenderLayerCompositor::computeCompositingRequirements().
Attachments
Patch (1.72 KB, patch)
2010-07-15 14:36 PDT, Simon Fraser (smfr)
sam: review+
Simon Fraser (smfr)
Comment 1 2010-07-15 14:36:03 PDT
Darin Adler
Comment 2 2010-07-15 14:39:40 PDT
Comment on attachment 61724 [details] Patch Does this fix only the assertion, or does it affect behavior too? If it does have an effect on behavior, what is that effect?
Simon Fraser (smfr)
Comment 3 2010-07-15 14:58:52 PDT
There is no change in behavior; we used to do a bit of extra work for the one call to computeCompositingRequirements() after compositing was disabled, because we thought we needed to make layers, and then when we tried to, noticed that m_hasAcceleratedCompositing was false. With the patch we never even try to make layers in that situation.
Simon Fraser (smfr)
Comment 4 2010-07-16 13:18:37 PDT
qi
Comment 5 2010-07-19 12:42:52 PDT
*** Bug 42582 has been marked as a duplicate of this bug. ***
Balazs Kelemen
Comment 6 2011-12-20 07:09:19 PST
I have a similar issue: https://bugs.webkit.org/show_bug.cgi?id=74511. When running fast/multicol/pagination-v-vertical-lr.html it hits the assertion in RenderLayerCompositor: // If we just entered compositing mode, the root will have become composited (as long as accelerated compositing is enabled). if (layer->isRootLayer()) { if (inCompositingMode() && m_hasAcceleratedCompositing) willBeComposited = true; } ASSERT(willBeComposited == needsToBeComposited(layer)); <<<<<<<<<< In this case the layer is a root layer, and both inCompositingMode() and m_hasAcceleratedCompositing are true, but needsToBeComposited(layer) is false because layer->isNormalFlowOnly() => !layer->isSelfPaintingLayer() => !canBeComposited(layer) Do you think another condition could be sufficient? i.e: -if (layer->isRootLayer()) { +if (layer->isRootLayer() && canBeComposited(layer)) Thanks in advance to your help!
Simon Fraser (smfr)
Comment 7 2011-12-20 07:21:52 PST
(In reply to comment #6) > I have a similar issue: https://bugs.webkit.org/show_bug.cgi?id=74511. When running fast/multicol/pagination-v-vertical-lr.html it hits the assertion in RenderLayerCompositor: Please file a new bug for this assertion. > In this case the layer is a root layer, and both inCompositingMode() and m_hasAcceleratedCompositing are true, but needsToBeComposited(layer) is false because layer->isNormalFlowOnly() => !layer->isSelfPaintingLayer() => !canBeComposited(layer) > Do you think another condition could be sufficient? i.e: > -if (layer->isRootLayer()) { > +if (layer->isRootLayer() && canBeComposited(layer)) If the root layer cannot be composited, then all kinds of stuff will break. I think we'll have to fix this another way.
Balazs Kelemen
Comment 8 2011-12-21 01:16:35 PST
(In reply to comment #7) > (In reply to comment #6) > > I have a similar issue: https://bugs.webkit.org/show_bug.cgi?id=74511. When running fast/multicol/pagination-v-vertical-lr.html it hits the assertion in RenderLayerCompositor: > > Please file a new bug for this assertion. Filed https://bugs.webkit.org/show_bug.cgi?id=74999.
Note You need to log in before you can comment on or make changes to this bug.