On platforms supporting Metal each Platform* definition points to an ObjC construct which is wrapped in a RetainPtr. For Dawn clients more code is required for smart pointers to function properly. Idea is to include a GPUPlatformTypes.h with all the Platform* and Platform*SmartPtr definitions. Then when Dawn is added it'll just have that file to include which will contain its definitions.
Created attachment 411437 [details] WIP Patch
Created attachment 411441 [details] WIP Patch
Created attachment 411458 [details] WIP Patch
Created attachment 411461 [details] WIP Patch
Created attachment 411473 [details] Patch
Comment on attachment 411473 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=411473&action=review Good cleanup. > Source/WebCore/platform/graphics/gpu/cocoa/GPUPlatformTypes.h:1 > +/* IIRC it's impossible (or maybe just error-prone?) to have two files with the same name in different directories. If that's true, then this will have to be moved out of cocoa/ and have PLATFORM guards inside the file.
Comment on attachment 411473 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=411473&action=review >> Source/WebCore/platform/graphics/gpu/cocoa/GPUPlatformTypes.h:1 >> +/* > > IIRC it's impossible (or maybe just error-prone?) to have two files with the same name in different directories. If that's true, then this will have to be moved out of cocoa/ and have PLATFORM guards inside the file. Oh, PLATFORM isn't right. It should be the same check that is used in the rest of the code.
Created attachment 411577 [details] Check build
Created attachment 411578 [details] Check build
Created attachment 411600 [details] Patch
Committed r268603: <https://trac.webkit.org/changeset/268603> All reviewed patches have been landed. Closing bug and clearing flags on attachment 411600 [details].
<rdar://problem/70387909>