Граф коммитов

158 Коммитов

Автор SHA1 Сообщение Дата
Dzmitry Malyshau 179d3960ce Bug 1713162 - Detect copies into WebGPU swapchain for presentation r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D116132
2021-05-27 17:20:28 +00:00
Dzmitry Malyshau e827c89a98 Bug 1681765 - Fix accessing implicit WebGPU layouts r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D116033
2021-05-27 15:08:02 +00:00
Dzmitry Malyshau cee0219fda Bug 1710679 - Implement WebGPU render bundles r=webidl,jgilbert,smaug
Differential Revision: https://phabricator.services.mozilla.com/D114878
2021-05-26 20:30:45 +00:00
Dzmitry Malyshau f1987ffe07 Bug 1711926 - Spew WebGPU validation errors to the console r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D115503
2021-05-22 01:03:00 +00:00
Noemi Erli f14d163f31 Backed out changeset 5efc966ba9a4 (bug 1711926) for causing assertions in nsContentUtils.cpp 2021-05-21 02:46:09 +03:00
Dzmitry Malyshau 853497a156 Bug 1711926 - Spew WebGPU validation errors to the console r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D115503
2021-05-20 21:00:36 +00:00
Dzmitry Malyshau b1ba8a1269 Bug 1711587 - Support multiple canvases in WebGPU command encoder r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D115305
2021-05-20 19:20:03 +00:00
Dzmitry Malyshau d329bf1572 Bug 1711868 - Only free WebGPU implicit layouts if they are given r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D115537
2021-05-20 15:30:55 +00:00
Dzmitry Malyshau 163a4a7ed8 Bug 1709462 - Fix freeing of WebGPU bind group layouts r=jimb
When the pipeline layout is implicit at pipeline creation,
we collect the IDs of BGLs, to be able to produce GPUBindGroupLayout
object upon user request. However, the produced object didn't know if
it owns the ID or borrows it, so it would issue a "drop" when going out of scope.

This change establishes this distinction. In addition, it gets the Pipeline Layout ID,
and together with the BGL ids, they are sent to GPU process upon pipeline destruction.

When the GPU process is done with these IDs used, it will kick back a message to the
Content process, allowing the IDs to be reclaimed.

Differential Revision: https://phabricator.services.mozilla.com/D114649
2021-05-18 16:26:27 +00:00
Dzmitry Malyshau f25cc08f2a Bug 1710550 - Detect resolving into WebGPU canvas r=gw
Differential Revision: https://phabricator.services.mozilla.com/D114811
2021-05-11 05:42:20 +00:00
Dzmitry Malyshau 0fad36e113 Bug 1637972 - WebGPU handle canvas resize r=aosmond
we recreate the swapchain on the size change

Differential Revision: https://phabricator.services.mozilla.com/D113172
2021-04-27 18:36:48 +00:00
Dzmitry Malyshau cdb4fe1fcb Bug 1622846 - Update BlendFactor API in WebGPU r=webidl,jimb,smaug
This is another incremental update of wgpu and WebGPU APIs.
It increases stability and makes us run most of the Austin's samples (again).
Likely fixes https://bugzilla.mozilla.org/show_bug.cgi?id=1704148

Differential Revision: https://phabricator.services.mozilla.com/D112828
2021-04-22 19:18:49 +00:00
Dzmitry Malyshau 2e592c660f Bug 1704911 - Fix Shmem circulation for buffers that are both mappable and mapped at creation r=jgilbert
We are now passing an extra flag on Unmap to keep the shmem around.
Previously, we'd be freeing the Shmem accidentally on buffers that are writable and mapped at creation.
We also add a bit of logging on the WebGPUParent side.

Differential Revision: https://phabricator.services.mozilla.com/D112264
2021-04-16 22:32:44 +00:00
Dzmitry Malyshau 19e0b39108 Bug 1705531 - Hook up Adapter to Limits and Features for CC r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D112269
2021-04-16 21:08:11 +00:00
Dzmitry Malyshau 89ced952fc Bug 1622846 - Update wgpu and WebGPU IDL for the new copy views API r=webidl,jgilbert,smaug
Updates wgpu, WebGPU IDL, in particular the ImageCopyXxx types and render pass attachments.
Adds explicit mapping of the GPUTextureFormat enum. Our old casting was incorrect, because the enums diverged a bit.

Differential Revision: https://phabricator.services.mozilla.com/D110997
2021-04-08 14:35:42 +00:00
Butkovits Atila 8d90cf4b42 Backed out changeset 5b033d5d6e6d (bug 1622846) for causing bustages on WebGPUChild.cpp. CLOSED TREE 2021-04-08 06:08:25 +03:00
Dzmitry Malyshau 92d0383ea9 Bug 1622846 - Update wgpu and WebGPU IDL for the new copy views API r=webidl,jgilbert,smaug
Updates wgpu, WebGPU IDL, in particular the ImageCopyXxx types and render pass attachments.
Adds explicit mapping of the GPUTextureFormat enum. Our old casting was incorrect, because the enums diverged a bit.

Differential Revision: https://phabricator.services.mozilla.com/D110997
2021-04-07 22:46:47 +00:00
Simon Giesecke 760cc7e936 Bug 1679522 - Fix include directives and forward declarations. r=andi,necko-reviewers,jgilbert
- Add missing include directives and forward declarations.
- Remove some extra include directives.
- Add missing namespace qualifications.
- Move include directives out of namespace in toolkit/xre/GlobalSemaphore.h

Differential Revision: https://phabricator.services.mozilla.com/D98894
2021-03-25 10:19:44 +00:00
Dzmitry Malyshau 5249d3e499 Bug 1697509 - Fix WebGPU shaders and adapter limits r=jgilbert
Expose adapter limits, hook up spirv-cross

Differential Revision: https://phabricator.services.mozilla.com/D107840
2021-03-16 22:57:08 +00:00
Joshua Groves efea742965 Bug 1622846 - Use `view` instead of `attachment` to match upstream WebIDL r=kvark,emilio
Differential Revision: https://phabricator.services.mozilla.com/D107402
2021-03-08 16:20:34 +00:00
Dzmitry Malyshau 29595bee3e Bug 1696066 - Serialize Queue write commands with Rust r=jgilbert
Based on https://phabricator.services.mozilla.com/D107013
Refactors our Queue write commands to use less of WebGPUSerialize.h
Also routes the errors from all queue operations properly to the client.

Differential Revision: https://phabricator.services.mozilla.com/D107162
2021-03-05 00:07:24 +00:00
Dzmitry Malyshau 27e5308381 Bug 1622846 - Update WebGPU API with wgpu r=jgilbert,webidl,smaug
This is another WebGPU API update, it picks up a lot of changes that were made recently:
  - new bind group layout
  - new render pipeline descriptor
  - new vertex formats
  - limits
  - compressed texture formats
  - index format
  - query sets
  - and more small ones!

It also brings in the updated `gfx/wgpu` to support these API changes.

Differential Revision: https://phabricator.services.mozilla.com/D107013
2021-03-04 21:25:46 +00:00
Brindusan Cristian cae8a0ef30 Backed out changeset 0c0c723b0a0e (bug 1622846) for build bustages in Device.h. CLOSED TREE 2021-03-04 22:02:58 +02:00
Dzmitry Malyshau 65199ec16a Bug 1622846 - Update WebGPU API with wgpu r=jgilbert,webidl,smaug
This is another WebGPU API update, it picks up a lot of changes that were made recently:
  - new bind group layout
  - new render pipeline descriptor
  - new vertex formats
  - limits
  - compressed texture formats
  - index format
  - query sets
  - and more small ones!

It also brings in the updated `gfx/wgpu` to support these API changes.

Differential Revision: https://phabricator.services.mozilla.com/D107013
2021-03-04 17:48:28 +00:00
Dzmitry Malyshau 57efe16247 Bug 1693329 - Update WebGPU code to use the new drop IPC r=jgilbert
Instead of having a separate IPC message type for every kind of object ID freeing,
we are encoding this into Rust enums and passing under the same DropAction.
This saves a bunch of lines of code, and allows us to free IDs in bulk where we need it.

Differential Revision: https://phabricator.services.mozilla.com/D105492
2021-03-02 20:11:31 +00:00
Sylvestre Ledru b4f9be25d4 Bug 1519636 - Reformat recent changes to the Google coding style r=andi,necko-reviewers
Updated with clang-format version 11.0.1 (taskcluster-B6bdwSKDRF-luRQWXBuzpA)

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D105158
2021-02-15 08:49:20 +00:00
Alexander Meißner 8a39c1058f Bug 1691712 - WebGPU bindings for RenderPassEncoder rasterization state r=kvark,webidl,smaug
Differential Revision: https://phabricator.services.mozilla.com/D104591
2021-02-10 16:25:39 +00:00
Bogdan Tara 0eb980825a Backed out changeset 2badb161c9ca (bug 1691712) for wpt leakcheck failures CLOSED TREE 2021-02-11 00:02:25 +02:00
Alexander Meißner 0d9937175f Bug 1691712 - WebGPU bindings for RenderPassEncoder rasterization state r=kvark,webidl,smaug
Differential Revision: https://phabricator.services.mozilla.com/D104591
2021-02-10 16:25:39 +00:00
Dzmitry Malyshau 6b5716d415 Bug 1680376 - WebGPU error handling infrastructure r=jgilbert,webidl,smaug
the goal of this PR is to provide the necessary
infrastructure to handle errors on the GPU process side and send them
back to the client side, triggering the uncaptured error events.

Differential Revision: https://phabricator.services.mozilla.com/D98542
2020-12-18 20:07:47 +00:00
Kartik Gautam f7ffcd09fb Bug 1679758 - Remove trailing empty lines r=sylvestre,marionette-reviewers,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D99595
2020-12-15 10:34:54 +00:00
Dorel Luca 7320ae982a Backed out changeset f3aaf04fce3b (bug 1679758) for Devtool failures in browser_styleeditor_syncAddProperty.js. CLOSED TREE 2020-12-13 16:38:21 +02:00
Kartik Gautam caf549c200 Bug 1679758 - Remove trailing empty lines r=sylvestre
Differential Revision: https://phabricator.services.mozilla.com/D99595
2020-12-13 13:28:30 +00:00
Simon Giesecke 4cab6ac723 Bug 1677466 - Move ParamTraits specializations with extra dependencies out of IPCMessageUtils.h. r=mccr8
This moves parts of IPCMessageUtils.h to two new header files and adapts
the include directives as necessary. The new header files are:
- EnumSerializer.h, which defines the templates for enum serializers
- IPCMessageUtilsSpecializations.h, which defines template specializations
  of ParamTraits with extra dependencies (building upon both IPCMessageUtils.h
  and EnumSerializer.h)

This should minimize the dependencies pulled in by every consumer of
IPCMessageUtils.h

Differential Revision: https://phabricator.services.mozilla.com/D94459
2020-12-10 11:09:21 +00:00
Dzmitry Malyshau 4a4e2b7a06 Bug 1655357 - Disable use of external textures on macOS in WebGPU r=aosmond
The external texture we create in WebGPU to present the canvas was taking
a different path on macOS with specific resolutions:
https://searchfox.org/mozilla-central/rev/85b84f82489451362a351b144fe5232a8e46c61c/gfx/layers/composite/TextureHost.cpp#590

Differential Revision: https://phabricator.services.mozilla.com/D97927
2020-11-24 19:43:31 +00:00
Simon Giesecke 971b645fe3 Bug 1660470 - Add missing include directives/forward declarations. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D87865
2020-11-23 16:21:38 +00:00
Dzmitry Malyshau 921110e00f Bug 1678396 - Enable WebGPU uncaptured error r=webidl,smaug
No functional changes, just WebIDL.

Differential Revision: https://phabricator.services.mozilla.com/D97642
2020-11-20 12:57:45 +00:00
Dzmitry Malyshau a028fe7df1 Bug 1677724 - Fix indentation in webgpu's mochitest manifest r=aryx
Differential Revision: https://phabricator.services.mozilla.com/D97330
2020-11-17 19:25:51 +00:00
Andi-Bogdan Postelnicu 522be9da14 Bug 1626555 - Add `dom/webgpu` to the list of non-unified-build-compatible directories. r=sg,kvark
Differential Revision: https://phabricator.services.mozilla.com/D97166
2020-11-16 19:57:04 +00:00
Razvan Maries bd8ba64c9d Backed out 2 changesets (bug 1626555) as per Andi's request. CLOSED TREE
Backed out changeset 22e23d9340a2 (bug 1626555)
Backed out changeset 02ea10ade875 (bug 1626555)
2020-11-16 18:45:15 +02:00
Andi-Bogdan Postelnicu 575adf71a5 Bug 1626555 - Add `dom/webgpu` to the list of non-unified-build-compatible directories. r=sg,kvark
Differential Revision: https://phabricator.services.mozilla.com/D97166
2020-11-16 15:37:09 +00:00
Dzmitry Malyshau 67a1f9eb04 Bug 1629357 - Make WebGPU dependent on WebRender feature r=aosmond
WebGPU itself doesn't care about WebRender or even the GPU process.
However, the presentation to canvas as written today only works with WebRender, so
it seems fine to have it as a dependency in general.

An alternative could be to just fail getContext() call if webrender is disabled.

Differential Revision: https://phabricator.services.mozilla.com/D70888
2020-11-16 15:25:39 +00:00
Dzmitry Malyshau 8f74799ba5 Bug 1676916 - Implicit bind group layouts in WebGPU r=jgilbert,webidl,smaug
This change updates and enables Naga to get the
SPIRV shaders parsed, validated, and reflected back into
implicit bind group layouts.
WebGPU examples heavily rely on the implicit layouts now,
and the PR also updates the WebIDL to make that possible.
With the change, we are able to run most of the examples again!

Differential Revision: https://phabricator.services.mozilla.com/D96850
2020-11-13 14:15:49 +00:00
Nika Layzell 630f9192f8 Bug 1676223 - Use ActorLifecycleProxy instead of WeakPtr for async returns, r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D96454
2020-11-12 17:59:03 +00:00
Brindusan Cristian 030df1b5cf Backed out changeset 98b994baee88 (bug 1676223) for build bustages at PChromiumCDMChild.cpp. CLOSED TREE 2020-11-10 01:59:18 +02:00
Nika Layzell 2d9159f48c Bug 1676223 - Use ActorLifecycleProxy instead of WeakPtr for async returns, r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D96454
2020-11-09 23:29:20 +00:00
Dzmitry Malyshau 55369907bf Bug 1675849 - Use Scoped to wrap WebGPU compute and render passes r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D96300
2020-11-07 14:42:28 +00:00
Dzmitry Malyshau f9116a751d Bug 1622846 - Serialize WebGPU descriptors via Serde for IPC r=jgilbert,webidl,smaug
This PR updates wgpu to the latest and changes the way we pass object descriptors to the GPU process.
Instead of trying to convert them between DOM-CPP-IPDL-FFI-Rust, we now do DOM-FFI-Rust
and serialize them by serde into ipc::ByteBuf objects.

Differential Revision: https://phabricator.services.mozilla.com/D94908
2020-11-07 02:43:09 +00:00
Csoregi Natalia 1a3ae2644d Backed out changeset bdd3d7eb5927 (bug 1622846) for linux bustage on gfx/wgpu/wgpu-types/src/lib.rs. CLOSED TREE 2020-11-07 00:48:50 +02:00
Dzmitry Malyshau 505438ed91 Bug 1622846 - Serialize WebGPU descriptors via Serde for IPC r=jgilbert,webidl,smaug
This PR updates wgpu to the latest and changes the way we pass object descriptors to the GPU process.
Instead of trying to convert them between DOM-CPP-IPDL-FFI-Rust, we now do DOM-FFI-Rust
and serialize them by serde into ipc::ByteBuf objects.

Differential Revision: https://phabricator.services.mozilla.com/D94908
2020-11-06 18:59:27 +00:00