[webkit-reviews] review denied: [Bug 230885] [Performance] Optimize RenderLayer::clipCrossesPaintingBoundary : [Attachment 439446] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Sep 29 10:42:53 PDT 2021


Simon Fraser (smfr) <simon.fraser at apple.com> has denied cathiechen
<cathiechen at igalia.com>'s request for review:
Bug 230885: [Performance] Optimize RenderLayer::clipCrossesPaintingBoundary
https://bugs.webkit.org/show_bug.cgi?id=230885

Attachment 439446: Patch

https://bugs.webkit.org/attachment.cgi?id=439446&action=review




--- Comment #6 from Simon Fraser (smfr) <simon.fraser at apple.com> ---
Comment on attachment 439446
  --> https://bugs.webkit.org/attachment.cgi?id=439446
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=439446&action=review

> Source/WebCore/rendering/RenderLayer.cpp:4455
> +    if
(parentLayer->enclosingPaginationLayer(IncludeCompositedPaginatedLayers) !=
enclosingPaginationLayer(IncludeCompositedPaginatedLayers))
> +	   return true;
> +
> +    if (compositedWithOwnBackingStore(*this))
> +	   return true;
> +
> +    if (paintsIntoProvidedBacking() && backingProviderLayer())
> +	   return true;
> +
> +    const RenderLayer* paintParent = paintOrderParent();
> +    if (parentLayer == paintParent)
> +	   return false;
> +
> +    return paintParent != parentLayer->paintOrderParent();

It's unfortunate that this effectively copies code from
enclosingCompositingLayerForRepaint(), and puts in a separate file, so fixes to
enclosingCompositingLayerForRepaint() are unlikely to be replicated here.

Think it would be better to add `bool
RenderLayer::sharesCompositingLayerForRepaint(RenderLayer& otherLayer)` and put
it next to RenderLayer::enclosingCompositingLayerForRepaint() so the code is
close.

Pagination is really rare, so move the pagination check last also.


More information about the webkit-reviews mailing list