Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate serialization for ScrollingStateFrameHostingNode #19580

Conversation

achristensen07
Copy link
Contributor

@achristensen07 achristensen07 commented Oct 26, 2023

887ac88

Generate serialization for ScrollingStateFrameHostingNode
https://bugs.webkit.org/show_bug.cgi?id=263704
rdar://117513008

Reviewed by Brady Eidson.

This required some new constructors, but the interesting part was teaching the
code generator how to handle types with OptionalTupleBits and non-OptionalTuple members.

* Source/WebCore/page/scrolling/ScrollingStateFrameHostingNode.cpp:
(WebCore::ScrollingStateFrameHostingNode::create):
(WebCore::ScrollingStateFrameHostingNode::ScrollingStateFrameHostingNode):
* Source/WebCore/page/scrolling/ScrollingStateFrameHostingNode.h:
* Source/WebCore/page/scrolling/ScrollingStateNode.cpp:
(WebCore::ScrollingStateNode::ScrollingStateNode):
* Source/WebCore/page/scrolling/ScrollingStateNode.h:
* Source/WebKit/Scripts/generate-serializers.py:
(SerializedType.has_optional_tuple_bits):
(check_type_members):
(encode_type):
(decode_type):
(generate_one_impl):
(generate_serialized_type_info):
(encode_optional_tuple): Deleted.
(decode_optional_tuple): Deleted.
* Source/WebKit/Scripts/webkit/tests/GeneratedSerializers.cpp:
(IPC::ArgumentCoder<Namespace::Subnamespace::StructName>::encode):
(IPC::ArgumentCoder<Namespace::OtherClass>::encode):
(IPC::ArgumentCoder<Namespace::ReturnRefClass>::encode):
(IPC::ArgumentCoder<Namespace::EmptyConstructorStruct>::encode):
(IPC::ArgumentCoder<Namespace::EmptyConstructorWithIf>::encode):
(IPC::ArgumentCoder<WithoutNamespace>::encode):
(IPC::ArgumentCoder<WithoutNamespaceWithAttributes>::encode):
(IPC::ArgumentCoder<WebCore::InheritsFrom>::encode):
(IPC::ArgumentCoder<WebCore::InheritanceGrandchild>::encode):
(IPC::ArgumentCoder<WTF::Seconds>::encode):
(IPC::ArgumentCoder<WTF::CreateUsingClass>::encode):
(IPC::ArgumentCoder<WebCore::FloatBoxExtent>::encode):
(IPC::ArgumentCoder<SoftLinkedMember>::encode):
(IPC::ArgumentCoder<Namespace::ConditionalCommonClass>::encode):
(IPC::ArgumentCoder<Namespace::CommonClass>::encode):
(IPC::ArgumentCoder<Namespace::AnotherCommonClass>::encode):
(IPC::ArgumentCoder<WebCore::MoveOnlyDerivedClass>::encode):
(IPC::ArgumentCoder<WebKit::LayerProperties>::encode):
(IPC::ArgumentCoder<WebKit::LayerProperties>::decode):
(IPC::ArgumentCoder<WebKit::TemplateTest<WebKit::Fabulous>>::encode):
(IPC::ArgumentCoder<WebKit::TemplateTest<WebCore::Amazing>>::encode):
(IPC::ArgumentCoder<WebKit::TemplateTest<JSC::Incredible>>::encode):
(IPC::ArgumentCoder<WebKit::TemplateTest<Testing::StorageSize>>::encode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::encode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::decode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNodeWithStuffAfterTuple>::encode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNodeWithStuffAfterTuple>::decode):
* Source/WebKit/Scripts/webkit/tests/GeneratedSerializers.h:
* Source/WebKit/Scripts/webkit/tests/SerializedTypeInfo.cpp:
(WebKit::allSerializedTypes):
* Source/WebKit/Scripts/webkit/tests/TestSerializedType.serialization.in:
* Source/WebKit/Scripts/webkit/tests/WebKitPlatformGeneratedSerializers.cpp:
(IPC::ArgumentCoder<WebKit::PlatformClass>::encode):
* Source/WebKit/Shared/RemoteLayerTree/RemoteLayerTree.serialization.in:
* Source/WebKit/Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.cpp:
(ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::encode): Deleted.
(ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::decode): Deleted.
* Source/WebKit/Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.h:
* Source/WebKit/Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.serialization.in:

Canonical link: https://commits.webkit.org/269811@main

c797d7e

Misc iOS, tvOS & watchOS macOS Linux Windows
❌ πŸ§ͺ style βœ… πŸ›  ios βœ… πŸ›  mac βœ… πŸ›  wpe βœ… πŸ›  wincairo
βœ… πŸ§ͺ bindings βœ… πŸ›  ios-sim βœ… πŸ›  mac-AS-debug βœ… πŸ§ͺ wpe-wk2
βœ… πŸ§ͺ webkitperl βœ… πŸ§ͺ ios-wk2 βœ… πŸ§ͺ api-mac βœ… πŸ›  gtk
βœ… πŸ§ͺ webkitpy βœ… πŸ§ͺ ios-wk2-wpt βœ… πŸ§ͺ mac-wk1 βœ… πŸ§ͺ gtk-wk2
βœ… πŸ§ͺ api-ios βœ… πŸ§ͺ mac-wk2 βœ… πŸ§ͺ api-gtk
βœ… πŸ›  tv βœ… πŸ§ͺ mac-AS-debug-wk2
βœ… πŸ›  tv-sim
βœ… πŸ›  watch
βœ… πŸ›  πŸ§ͺ unsafe-merge βœ… πŸ›  watch-sim

@achristensen07 achristensen07 self-assigned this Oct 26, 2023
@achristensen07 achristensen07 added the WebKit Misc. For miscellaneous bugs in the WebKit framework (and not JavaScriptCore or WebCore). label Oct 26, 2023
Copy link
Contributor

@beidson beidson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

I don't have the skillset to be hypercritical of the python changes, but they pass the sniff test and are regression tested, so... πŸ‘

@@ -69,6 +69,7 @@ void ArgumentCoder<WebKit::PlatformClass>::encode(Encoder& encoder, const WebKit
static_assert(MembersInCorrectOrder < 0
, offsetof(WebKit::PlatformClass, value)
>::value);

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stray?

@achristensen07 achristensen07 force-pushed the eng/Generate-serialization-for-ScrollingStateFrameHostingNode branch from 642ea5d to c797d7e Compare October 26, 2023 05:06
@achristensen07 achristensen07 added the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Oct 26, 2023
https://bugs.webkit.org/show_bug.cgi?id=263704
rdar://117513008

Reviewed by Brady Eidson.

This required some new constructors, but the interesting part was teaching the
code generator how to handle types with OptionalTupleBits and non-OptionalTuple members.

* Source/WebCore/page/scrolling/ScrollingStateFrameHostingNode.cpp:
(WebCore::ScrollingStateFrameHostingNode::create):
(WebCore::ScrollingStateFrameHostingNode::ScrollingStateFrameHostingNode):
* Source/WebCore/page/scrolling/ScrollingStateFrameHostingNode.h:
* Source/WebCore/page/scrolling/ScrollingStateNode.cpp:
(WebCore::ScrollingStateNode::ScrollingStateNode):
* Source/WebCore/page/scrolling/ScrollingStateNode.h:
* Source/WebKit/Scripts/generate-serializers.py:
(SerializedType.has_optional_tuple_bits):
(check_type_members):
(encode_type):
(decode_type):
(generate_one_impl):
(generate_serialized_type_info):
(encode_optional_tuple): Deleted.
(decode_optional_tuple): Deleted.
* Source/WebKit/Scripts/webkit/tests/GeneratedSerializers.cpp:
(IPC::ArgumentCoder<Namespace::Subnamespace::StructName>::encode):
(IPC::ArgumentCoder<Namespace::OtherClass>::encode):
(IPC::ArgumentCoder<Namespace::ReturnRefClass>::encode):
(IPC::ArgumentCoder<Namespace::EmptyConstructorStruct>::encode):
(IPC::ArgumentCoder<Namespace::EmptyConstructorWithIf>::encode):
(IPC::ArgumentCoder<WithoutNamespace>::encode):
(IPC::ArgumentCoder<WithoutNamespaceWithAttributes>::encode):
(IPC::ArgumentCoder<WebCore::InheritsFrom>::encode):
(IPC::ArgumentCoder<WebCore::InheritanceGrandchild>::encode):
(IPC::ArgumentCoder<WTF::Seconds>::encode):
(IPC::ArgumentCoder<WTF::CreateUsingClass>::encode):
(IPC::ArgumentCoder<WebCore::FloatBoxExtent>::encode):
(IPC::ArgumentCoder<SoftLinkedMember>::encode):
(IPC::ArgumentCoder<Namespace::ConditionalCommonClass>::encode):
(IPC::ArgumentCoder<Namespace::CommonClass>::encode):
(IPC::ArgumentCoder<Namespace::AnotherCommonClass>::encode):
(IPC::ArgumentCoder<WebCore::MoveOnlyDerivedClass>::encode):
(IPC::ArgumentCoder<WebKit::LayerProperties>::encode):
(IPC::ArgumentCoder<WebKit::LayerProperties>::decode):
(IPC::ArgumentCoder<WebKit::TemplateTest<WebKit::Fabulous>>::encode):
(IPC::ArgumentCoder<WebKit::TemplateTest<WebCore::Amazing>>::encode):
(IPC::ArgumentCoder<WebKit::TemplateTest<JSC::Incredible>>::encode):
(IPC::ArgumentCoder<WebKit::TemplateTest<Testing::StorageSize>>::encode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::encode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::decode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNodeWithStuffAfterTuple>::encode):
(IPC::ArgumentCoder<WebCore::ScrollingStateFrameHostingNodeWithStuffAfterTuple>::decode):
* Source/WebKit/Scripts/webkit/tests/GeneratedSerializers.h:
* Source/WebKit/Scripts/webkit/tests/SerializedTypeInfo.cpp:
(WebKit::allSerializedTypes):
* Source/WebKit/Scripts/webkit/tests/TestSerializedType.serialization.in:
* Source/WebKit/Scripts/webkit/tests/WebKitPlatformGeneratedSerializers.cpp:
(IPC::ArgumentCoder<WebKit::PlatformClass>::encode):
* Source/WebKit/Shared/RemoteLayerTree/RemoteLayerTree.serialization.in:
* Source/WebKit/Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.cpp:
(ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::encode): Deleted.
(ArgumentCoder<WebCore::ScrollingStateFrameHostingNode>::decode): Deleted.
* Source/WebKit/Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.h:
* Source/WebKit/Shared/RemoteLayerTree/RemoteScrollingCoordinatorTransaction.serialization.in:

Canonical link: https://commits.webkit.org/269811@main
@webkit-commit-queue webkit-commit-queue force-pushed the eng/Generate-serialization-for-ScrollingStateFrameHostingNode branch from c797d7e to 887ac88 Compare October 26, 2023 14:29
@webkit-commit-queue
Copy link
Collaborator

Committed 269811@main (887ac88): https://commits.webkit.org/269811@main

Reviewed commits have been landed. Closing PR #19580 and removing active labels.

@webkit-commit-queue webkit-commit-queue merged commit 887ac88 into WebKit:main Oct 26, 2023
@webkit-commit-queue webkit-commit-queue removed the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Oct 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WebKit Misc. For miscellaneous bugs in the WebKit framework (and not JavaScriptCore or WebCore).
Projects
None yet
4 participants