⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 249120 in webkit


Ignore:
Timestamp:
Aug 26, 2019, 3:21:38 PM (7 years ago)
Author:
Simon Fraser
Message:

Optimize computation of AbsoluteClipRects clip rects
https://bugs.webkit.org/show_bug.cgi?id=201148

Reviewed by Zalan Bujtas.

When adding layers to the compositing overlap map, we compute AbsoluteClipRects for every
layer which is expensive. This was more expensive than necessary because we converted them
to TemporaryClipRects when crossing painting boundaries, but AbsoluteClipRects don't
care about painting boundaries, so don't do this.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::calculateClipRects const):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r249119 r249120  
     12019-08-26  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Optimize computation of AbsoluteClipRects clip rects
     4        https://bugs.webkit.org/show_bug.cgi?id=201148
     5
     6        Reviewed by Zalan Bujtas.
     7
     8        When adding layers to the compositing overlap map, we compute AbsoluteClipRects for every
     9        layer which is expensive. This was more expensive than necessary because we converted them
     10        to TemporaryClipRects when crossing painting boundaries, but AbsoluteClipRects don't
     11        care about painting boundaries, so don't do this.
     12
     13        * rendering/RenderLayer.cpp:
     14        (WebCore::RenderLayer::calculateClipRects const):
     15
    1162019-08-26  Chris Dumez  <cdumez@apple.com>
    217
  • trunk/Source/WebCore/rendering/RenderLayer.cpp

    r249091 r249120  
    56325632            parentContext.overlayScrollbarSizeRelevancy = IgnoreOverlayScrollbarSize; // FIXME: why?
    56335633           
    5634             if (parentContext.clipRectsType != TemporaryClipRects && clipCrossesPaintingBoundary())
     5634            if ((parentContext.clipRectsType != TemporaryClipRects && parentContext.clipRectsType != AbsoluteClipRects) && clipCrossesPaintingBoundary())
    56355635                parentContext.clipRectsType = TemporaryClipRects;
    56365636
     
    56985698        return temporaryParentClipRects(clipRectsContext);
    56995699
    5700     if (clipCrossesPaintingBoundary()) {
     5700    if (clipRectsContext.clipRectsType != AbsoluteClipRects && clipCrossesPaintingBoundary()) {
    57015701        ClipRectsContext tempClipRectsContext(clipRectsContext);
    57025702        tempClipRectsContext.clipRectsType = TemporaryClipRects;
Note: See TracChangeset for help on using the changeset viewer.