WebKit Bugzilla
Attachment 358807 Details for
Bug 193298
: [WebGPU] Add BindGroupBinding, BindGroupDescriptor, and BufferBinding dictionaries from API
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for landing
bug-193298-20190110110114.patch (text/plain), 28.24 KB, created by
Justin Fan
on 2019-01-10 11:01:15 PST
(
hide
)
Description:
Patch for landing
Filename:
MIME Type:
Creator:
Justin Fan
Created:
2019-01-10 11:01:15 PST
Size:
28.24 KB
patch
obsolete
>Subversion Revision: 239780 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index bea20b023cc10c5b589dfd5cf02f246afa288bad..60a0bd1e672b62694cc64032b5311f84e9d8def1 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,41 @@ >+2019-01-09 Justin Fan <justin_fan@apple.com> >+ >+ [WebGPU] Add BindGroupBinding, BindGroupDescriptor, and BufferBinding dictionaries from API >+ https://bugs.webkit.org/show_bug.cgi?id=193298 >+ >+ Reviewed by Dean Jackson. >+ >+ No new tests. No change in behavior. >+ >+ * CMakeLists.txt: >+ * DerivedSources.make: >+ * Modules/webgpu/WebGPUBindGroupBinding.h: Added. >+ * Modules/webgpu/WebGPUBindGroupBinding.idl: Added. >+ * Modules/webgpu/WebGPUBindGroupDescriptor.h: Added. >+ * Modules/webgpu/WebGPUBindGroupDescriptor.idl: Added. >+ * Modules/webgpu/WebGPUBufferBinding.h: Added. >+ * Modules/webgpu/WebGPUBufferBinding.idl: Added. >+ * Sources.txt: >+ * WebCore.xcodeproj/project.pbxproj: >+ * platform/graphics/gpu/GPUBindGroupBinding.h: Added. >+ * platform/graphics/gpu/GPUBindGroupDescriptor.h: Added. >+ * platform/graphics/gpu/GPUBufferBinding.h: Added. >+ >+2019-01-09 Justin Fan <justin_fan@apple.com> >+ >+ [WebGPU] Fix vertex-buffer-triangle-strip test and small update to GPURenderPipeline >+ https://bugs.webkit.org/show_bug.cgi?id=193289 >+ >+ Reviewed by Dean Jackson. >+ >+ Fix broken test after pipeline layouts were added, and a small refactoring to GPURenderPipeline to avoid >+ retaining its descriptor after creation. >+ >+ * platform/graphics/gpu/GPURenderPipeline.h: >+ (WebCore::GPURenderPipeline::primitiveTopology const): >+ * platform/graphics/gpu/cocoa/GPURenderPipelineMetal.mm: >+ (WebCore::GPURenderPipeline::GPURenderPipeline): >+ > 2019-01-09 Justin Fan <justin_fan@apple.com> > > [WebGPU] Fix vertex-buffer-triangle-strip test and small update to GPURenderPipeline >diff --git a/Source/WebCore/CMakeLists.txt b/Source/WebCore/CMakeLists.txt >index 9c51418af76624841ebbf5c6589f250df85f1d50..1dd5329a9b596798239e7e2a71405873e402044c 100644 >--- a/Source/WebCore/CMakeLists.txt >+++ b/Source/WebCore/CMakeLists.txt >@@ -464,10 +464,13 @@ set(WebCore_NON_SVG_IDL_FILES > Modules/webgpu/WebGPU.idl > Modules/webgpu/WebGPUAdapter.idl > Modules/webgpu/WebGPUAdapterDescriptor.idl >+ Modules/webgpu/WebGPUBindGroupBinding.idl >+ Modules/webgpu/WebGPUBindGroupDescriptor.idl > Modules/webgpu/WebGPUBindGroupLayout.idl > Modules/webgpu/WebGPUBindGroupLayoutBinding.idl > Modules/webgpu/WebGPUBindGroupLayoutDescriptor.idl > Modules/webgpu/WebGPUBuffer.idl >+ Modules/webgpu/WebGPUBufferBinding.idl > Modules/webgpu/WebGPUBufferDescriptor.idl > Modules/webgpu/WebGPUBufferUsage.idl > Modules/webgpu/WebGPUColor.idl >diff --git a/Source/WebCore/DerivedSources.make b/Source/WebCore/DerivedSources.make >index e948b702f37a566e550a5ebe56e602fcb7922f8f..e17c6afa7a7c013191c8c3e9757f36eb60fb3e55 100644 >--- a/Source/WebCore/DerivedSources.make >+++ b/Source/WebCore/DerivedSources.make >@@ -375,10 +375,13 @@ JS_BINDING_IDLS = \ > $(WebCore)/Modules/webgpu/WebGPU.idl \ > $(WebCore)/Modules/webgpu/WebGPUAdapter.idl \ > $(WebCore)/Modules/webgpu/WebGPUAdapterDescriptor.idl \ >+ $(WebCore)/Modules/webgpu/WebGPUBindGroupBinding.idl \ >+ $(WebCore)/Modules/webgpu/WebGPUBindGroupDescriptor.idl \ > $(WebCore)/Modules/webgpu/WebGPUBindGroupLayout.idl \ > $(WebCore)/Modules/webgpu/WebGPUBindGroupLayoutBinding.idl \ > $(WebCore)/Modules/webgpu/WebGPUBindGroupLayoutDescriptor.idl \ > $(WebCore)/Modules/webgpu/WebGPUBuffer.idl \ >+ $(WebCore)/Modules/webgpu/WebGPUBufferBinding.idl \ > $(WebCore)/Modules/webgpu/WebGPUBufferDescriptor.idl \ > $(WebCore)/Modules/webgpu/WebGPUBufferUsage.idl \ > $(WebCore)/Modules/webgpu/WebGPUColor.idl \ >diff --git a/Source/WebCore/Modules/webgpu/WebGPUBindGroupBinding.h b/Source/WebCore/Modules/webgpu/WebGPUBindGroupBinding.h >new file mode 100644 >index 0000000000000000000000000000000000000000..dddf995c7226b5c1e952eeae1884398dfb689036 >--- /dev/null >+++ b/Source/WebCore/Modules/webgpu/WebGPUBindGroupBinding.h >@@ -0,0 +1,45 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#if ENABLE(WEBGPU) >+ >+#include "WebGPUBufferBinding.h" >+#include "WebGPUTextureView.h" >+#include <wtf/Variant.h> >+ >+namespace WebCore { >+ >+using WebGPUBindingResource = Variant<RefPtr<WebGPUTextureView>, WebGPUBufferBinding>; >+ >+struct WebGPUBindGroupBinding { >+ unsigned long binding; >+ WebGPUBindingResource resource; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(WEBGPU) >diff --git a/Source/WebCore/Modules/webgpu/WebGPUBindGroupBinding.idl b/Source/WebCore/Modules/webgpu/WebGPUBindGroupBinding.idl >new file mode 100644 >index 0000000000000000000000000000000000000000..a2672067802c9ae8ad4e5abe4581ec6e61f01ca5 >--- /dev/null >+++ b/Source/WebCore/Modules/webgpu/WebGPUBindGroupBinding.idl >@@ -0,0 +1,36 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+// https://github.com/gpuweb/gpuweb/blob/master/design/sketch.webidl >+ >+typedef unsigned long u32; >+typedef (/*WebGPUSampler or */WebGPUTextureView or WebGPUBufferBinding) WebGPUBindingResource; >+ >+[ >+ Conditional=WEBGPU, >+ EnabledAtRuntime=WebGPU >+] dictionary WebGPUBindGroupBinding { >+ u32 binding; >+ WebGPUBindingResource resource; >+}; >diff --git a/Source/WebCore/Modules/webgpu/WebGPUBindGroupDescriptor.h b/Source/WebCore/Modules/webgpu/WebGPUBindGroupDescriptor.h >new file mode 100644 >index 0000000000000000000000000000000000000000..67fd939cc4705a3913b3c33a8c8e31346b9dd4eb >--- /dev/null >+++ b/Source/WebCore/Modules/webgpu/WebGPUBindGroupDescriptor.h >@@ -0,0 +1,44 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#if ENABLE(WEBGPU) >+ >+#include "WebGPUBindGroupBinding.h" >+#include "WebGPUBindGroupLayout.h" >+#include <wtf/RefPtr.h> >+#include <wtf/Vector.h> >+ >+namespace WebCore { >+ >+struct WebGPUBindGroupDescriptor { >+ RefPtr<WebGPUBindGroupLayout> layout; >+ Vector<WebGPUBindGroupBinding> bindings; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(WEBGPU) >diff --git a/Source/WebCore/Modules/webgpu/WebGPUBindGroupDescriptor.idl b/Source/WebCore/Modules/webgpu/WebGPUBindGroupDescriptor.idl >new file mode 100644 >index 0000000000000000000000000000000000000000..3905610a69b17cc0cbdc2a143d8a6901d0526ecb >--- /dev/null >+++ b/Source/WebCore/Modules/webgpu/WebGPUBindGroupDescriptor.idl >@@ -0,0 +1,33 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+// https://github.com/gpuweb/gpuweb/blob/master/design/sketch.webidl >+ >+[ >+ Conditional=WEBGPU, >+ EnabledAtRuntime=WebGPU >+] dictionary WebGPUBindGroupDescriptor { >+ WebGPUBindGroupLayout layout; >+ sequence<WebGPUBindGroupBinding> bindings; >+}; >diff --git a/Source/WebCore/Modules/webgpu/WebGPUBufferBinding.h b/Source/WebCore/Modules/webgpu/WebGPUBufferBinding.h >new file mode 100644 >index 0000000000000000000000000000000000000000..b477b67ad6e334df46636ffdbcee4a360938faa9 >--- /dev/null >+++ b/Source/WebCore/Modules/webgpu/WebGPUBufferBinding.h >@@ -0,0 +1,43 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#if ENABLE(WEBGPU) >+ >+#include "WebGPUBuffer.h" >+#include <wtf/RefPtr.h> >+ >+namespace WebCore { >+ >+struct WebGPUBufferBinding { >+ RefPtr<WebGPUBuffer> buffer; >+ unsigned long offset; >+ unsigned long size; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(WEBGPU) >diff --git a/Source/WebCore/Modules/webgpu/WebGPUBufferBinding.idl b/Source/WebCore/Modules/webgpu/WebGPUBufferBinding.idl >new file mode 100644 >index 0000000000000000000000000000000000000000..ad7286681ba3d1f3fa1721c6fae80ebaeb304e8c >--- /dev/null >+++ b/Source/WebCore/Modules/webgpu/WebGPUBufferBinding.idl >@@ -0,0 +1,36 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+// https://github.com/gpuweb/gpuweb/blob/master/design/sketch.webidl >+ >+typedef unsigned long u32; >+ >+[ >+ Conditional=WEBGPU, >+ EnabledAtRuntime=WebGPU >+] dictionary WebGPUBufferBinding { >+ WebGPUBuffer buffer; >+ u32 offset; >+ u32 size; >+}; >diff --git a/Source/WebCore/Sources.txt b/Source/WebCore/Sources.txt >index 27b0b20dee7ed151c50397d782fd60411c1180d7..238ea7d338922097a66bff746ad40550dcfbca6f 100644 >--- a/Source/WebCore/Sources.txt >+++ b/Source/WebCore/Sources.txt >@@ -3235,10 +3235,13 @@ JSWebAnimation.cpp > JSWebGPU.cpp > JSWebGPUAdapter.cpp > JSWebGPUAdapterDescriptor.cpp >+JSWebGPUBindGroupBinding.cpp >+JSWebGPUBindGroupDescriptor.cpp > JSWebGPUBindGroupLayout.cpp > JSWebGPUBindGroupLayoutBinding.cpp > JSWebGPUBindGroupLayoutDescriptor.cpp > JSWebGPUBuffer.cpp >+JSWebGPUBufferBinding.cpp > JSWebGPUBufferDescriptor.cpp > JSWebGPUBufferUsage.cpp > JSWebGPUCommandBuffer.cpp >diff --git a/Source/WebCore/WebCore.xcodeproj/project.pbxproj b/Source/WebCore/WebCore.xcodeproj/project.pbxproj >index 3ec66782454401ef99f140eb997c306e70edcc50..ab0512c34034eb0b84054c5100ec52f06063f6b9 100644 >--- a/Source/WebCore/WebCore.xcodeproj/project.pbxproj >+++ b/Source/WebCore/WebCore.xcodeproj/project.pbxproj >@@ -13880,6 +13880,15 @@ > D0BC54481443AC4A00E105DA /* CachedStyleSheetClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CachedStyleSheetClient.h; sourceTree = "<group>"; }; > D0BD4F5A1408850F006839B6 /* DictationCommandIOS.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DictationCommandIOS.cpp; sourceTree = "<group>"; }; > D0BD4F5B1408850F006839B6 /* DictationCommandIOS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DictationCommandIOS.h; sourceTree = "<group>"; }; >+ D0BE104A21E6872F00E42A89 /* GPUBufferBinding.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GPUBufferBinding.h; sourceTree = "<group>"; }; >+ D0BE104C21E68F1500E42A89 /* WebGPUBufferBinding.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebGPUBufferBinding.h; sourceTree = "<group>"; }; >+ D0BE104D21E68F1500E42A89 /* WebGPUBufferBinding.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = WebGPUBufferBinding.idl; sourceTree = "<group>"; }; >+ D0BE104E21E695E200E42A89 /* GPUBindGroupBinding.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GPUBindGroupBinding.h; sourceTree = "<group>"; }; >+ D0BE104F21E69F8300E42A89 /* WebGPUBindGroupBinding.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebGPUBindGroupBinding.h; sourceTree = "<group>"; }; >+ D0BE105021E69F8300E42A89 /* WebGPUBindGroupBinding.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = WebGPUBindGroupBinding.idl; sourceTree = "<group>"; }; >+ D0BE105121E6A70E00E42A89 /* GPUBindGroupDescriptor.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GPUBindGroupDescriptor.h; sourceTree = "<group>"; }; >+ D0BE105221E6AA0D00E42A89 /* WebGPUBindGroupDescriptor.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebGPUBindGroupDescriptor.h; sourceTree = "<group>"; }; >+ D0BE105321E6AA0D00E42A89 /* WebGPUBindGroupDescriptor.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = WebGPUBindGroupDescriptor.idl; sourceTree = "<group>"; }; > D0C419EB2183CFA2009EC1DE /* WebGPUPipelineStageDescriptor.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebGPUPipelineStageDescriptor.h; sourceTree = "<group>"; }; > D0C419EC2183CFA2009EC1DE /* WebGPUPipelineStageDescriptor.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = WebGPUPipelineStageDescriptor.idl; sourceTree = "<group>"; }; > D0C419F02183EB31009EC1DE /* WebGPUPipelineDescriptorBase.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = WebGPUPipelineDescriptorBase.h; sourceTree = "<group>"; }; >@@ -18079,10 +18088,13 @@ > children = ( > D087CE3721ACA94200BDE174 /* cocoa */, > 312FF8CE21A4C33F00EB199D /* legacy */, >+ D0BE104E21E695E200E42A89 /* GPUBindGroupBinding.h */, >+ D0BE105121E6A70E00E42A89 /* GPUBindGroupDescriptor.h */, > D02454D021C4A41C00B73628 /* GPUBindGroupLayout.h */, > D0B8BB0121C46E78000C7681 /* GPUBindGroupLayoutBinding.h */, > D083D98421C48050008E8EFF /* GPUBindGroupLayoutDescriptor.h */, > D0D8649221B760F2003C983C /* GPUBuffer.h */, >+ D0BE104A21E6872F00E42A89 /* GPUBufferBinding.h */, > D0D8648721B64CAA003C983C /* GPUBufferDescriptor.h */, > D001D9AB21B0C7BF0023B9BC /* GPUColor.h */, > 312FF8BD21A4C2F100EB199D /* GPUCommandBuffer.h */, >@@ -25624,6 +25636,10 @@ > D00F5951216FFAC2000D71DB /* WebGPUAdapter.idl */, > D02C26912181416D00D818E4 /* WebGPUAdapterDescriptor.h */, > D02C26922181416D00D818E4 /* WebGPUAdapterDescriptor.idl */, >+ D0BE104F21E69F8300E42A89 /* WebGPUBindGroupBinding.h */, >+ D0BE105021E69F8300E42A89 /* WebGPUBindGroupBinding.idl */, >+ D0BE105221E6AA0D00E42A89 /* WebGPUBindGroupDescriptor.h */, >+ D0BE105321E6AA0D00E42A89 /* WebGPUBindGroupDescriptor.idl */, > D003287A21C8645B00622AA6 /* WebGPUBindGroupLayout.cpp */, > D003287921C8645B00622AA6 /* WebGPUBindGroupLayout.h */, > D003287B21C8645B00622AA6 /* WebGPUBindGroupLayout.idl */, >@@ -25634,6 +25650,8 @@ > D0D8648D21B70676003C983C /* WebGPUBuffer.cpp */, > D0D8648C21B70676003C983C /* WebGPUBuffer.h */, > D0D8648E21B70676003C983C /* WebGPUBuffer.idl */, >+ D0BE104C21E68F1500E42A89 /* WebGPUBufferBinding.h */, >+ D0BE104D21E68F1500E42A89 /* WebGPUBufferBinding.idl */, > D0D8648221B61727003C983C /* WebGPUBufferDescriptor.h */, > D0D8648321B61727003C983C /* WebGPUBufferDescriptor.idl */, > D063AE3F21C05DDD000E6A35 /* WebGPUBufferUsage.h */, >diff --git a/Source/WebCore/platform/graphics/gpu/GPUBindGroupBinding.h b/Source/WebCore/platform/graphics/gpu/GPUBindGroupBinding.h >new file mode 100644 >index 0000000000000000000000000000000000000000..cfa8b01fc26cf5a6a9acc10b70dbbe63e2d7fee6 >--- /dev/null >+++ b/Source/WebCore/platform/graphics/gpu/GPUBindGroupBinding.h >@@ -0,0 +1,45 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#if ENABLE(WEBGPU) >+ >+#include "GPUBufferBinding.h" >+#include "GPUTexture.h" >+#include <wtf/Variant.h> >+ >+namespace WebCore { >+ >+using GPUBindingResource = Variant<Ref<GPUTexture>, GPUBufferBinding>; >+ >+struct GPUBindGroupBinding { >+ unsigned long binding; >+ GPUBindingResource resource; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(WEBGPU) >diff --git a/Source/WebCore/platform/graphics/gpu/GPUBindGroupDescriptor.h b/Source/WebCore/platform/graphics/gpu/GPUBindGroupDescriptor.h >new file mode 100644 >index 0000000000000000000000000000000000000000..50711fe73884f78e49e8670ca942f998f4994feb >--- /dev/null >+++ b/Source/WebCore/platform/graphics/gpu/GPUBindGroupDescriptor.h >@@ -0,0 +1,44 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#if ENABLE(WEBGPU) >+ >+#include "GPUBindGroupBinding.h" >+#include "GPUBindGroupLayout.h" >+#include <wtf/Ref.h> >+#include <wtf/Vector.h> >+ >+namespace WebCore { >+ >+struct GPUBindGroupDescriptor { >+ Ref<GPUBindGroupLayout> layout; >+ Vector<GPUBindGroupBinding> bindings; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(WEBGPU) >diff --git a/Source/WebCore/platform/graphics/gpu/GPUBufferBinding.h b/Source/WebCore/platform/graphics/gpu/GPUBufferBinding.h >new file mode 100644 >index 0000000000000000000000000000000000000000..91e08733c6934887421cf94a75c6636294d2349c >--- /dev/null >+++ b/Source/WebCore/platform/graphics/gpu/GPUBufferBinding.h >@@ -0,0 +1,43 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#if ENABLE(WEBGPU) >+ >+#include "GPUBuffer.h" >+#include <wtf/Ref.h> >+ >+namespace WebCore { >+ >+struct GPUBufferBinding { >+ Ref<GPUBuffer> buffer; >+ unsigned long offset; >+ unsigned long size; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(WEBGPU) >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index b876efccf3a3935050ee29002eb783337f757973..0e7bc31326fa17038208146d34f43f0a892ba254 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -11,6 +11,19 @@ > (createBasicPipeline): Ensure pipeline layout is actually optional. > * webgpu/vertex-buffer-triangle-strip.html: > >+2019-01-09 Justin Fan <justin_fan@apple.com> >+ >+ [WebGPU] Fix vertex-buffer-triangle-strip test and small update to GPURenderPipeline >+ https://bugs.webkit.org/show_bug.cgi?id=193289 >+ >+ Reviewed by Dean Jackson. >+ >+ Fix broken test after pipeline layouts were added. >+ >+ * webgpu/js/webgpu-functions.js: >+ (createBasicPipeline): Ensure pipeline layout is actually optional. >+ * webgpu/vertex-buffer-triangle-strip.html: >+ > 2019-01-09 Wenson Hsieh <wenson_hsieh@apple.com> > > [iOS] editing/selection/ios/show-selection-in-empty-overflow-hidden-document.html often times out in internal automation
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 193298
:
358742
|
358745
| 358807