Bug 227783 - add logging for GraphicsLayerCA::m_uncommittedChanges
Summary: add logging for GraphicsLayerCA::m_uncommittedChanges
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Compositing (show other bugs)
Version: WebKit Local Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Cameron McCormack (:heycam)
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-07-07 17:53 PDT by Cameron McCormack (:heycam)
Modified: 2021-07-07 23:54 PDT (History)
2 users (show)

See Also:


Attachments
Patch (7.03 KB, patch)
2021-07-07 17:56 PDT, Cameron McCormack (:heycam)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Cameron McCormack (:heycam) 2021-07-07 17:53:42 PDT
.
Comment 1 Cameron McCormack (:heycam) 2021-07-07 17:56:05 PDT
Created attachment 433102 [details]
Patch
Comment 2 Simon Fraser (smfr) 2021-07-07 20:04:57 PDT
Comment on attachment 433102 [details]
Patch

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

> Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:4136
> +const char* GraphicsLayerCA::layerChangeAsString(LayerChange layerChange)

This is better implemented as TextStream& operator<<(TextStream&, LayerChange)
Comment 3 Cameron McCormack (:heycam) 2021-07-07 20:09:00 PDT
I wanted to but struggled with the enum being private.
Comment 4 Simon Fraser (smfr) 2021-07-07 20:17:24 PDT
Comment on attachment 433102 [details]
Patch

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

> Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:4207
> +    bool first = true;
> +    while (layerChangeFlags) {
> +        if (layerChangeFlags & bit) {
> +            textStream << (first ? " " : ", ") << layerChangeAsString(static_cast<LayerChange>(bit));
> +            first = false;
> +        }
> +        layerChangeFlags &= ~bit;
> +        bit <<= 1;
> +    }
> +    textStream << " }";

Shame that LayerChangeFlags isn' an OptionSet<> because they you wouldn't need this either.
Comment 5 Cameron McCormack (:heycam) 2021-07-07 20:29:52 PDT
Will do that later. https://bugs.webkit.org/show_bug.cgi?id=227787
Comment 6 EWS 2021-07-07 23:53:08 PDT
Committed r279712 (239504@main): <https://commits.webkit.org/239504@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 433102 [details].
Comment 7 Radar WebKit Bug Importer 2021-07-07 23:54:17 PDT
<rdar://problem/80308784>