Commit Graph

60 Commits

Author SHA1 Message Date
Dzmitry Malyshau
544f262737 Bug 1653161 - Implement Queue.writeBuffer and writeTexture in WebGPU r=jgilbert,webidl,smaug
Updates wgpu to bd50867bb8c66ac9dec50046d066c02b8f7a3fc1

Differential Revision: https://phabricator.services.mozilla.com/D83734
2020-07-28 22:26:21 +00:00
Jeff Muizelaar
b083673982 Bug 1654699. Update core-foundation/core-graphics. r=kvark,keeler,jcj,chunmin
This includes updates to authenticator, cubeb-coreaudio,
metal, gfx-backend-vulkan, gfx-backend-metal, freetype

libloading is duplicated because of ash

Differential Revision: https://phabricator.services.mozilla.com/D84688
2020-07-24 22:35:25 +00:00
Csoregi Natalia
ea1ddfabbf Backed out changeset 9702b4a4f53c (bug 1654699) for Gtest failures. CLOSED TREE 2020-07-24 21:29:52 +03:00
Jeff Muizelaar
b17ab0c2e7 Bug 1654699. Update core-foundation/core-graphics. r=kvark,keeler,jcj,chunmin
This includes updates to authenticator, cubeb-coreaudio,
metal, gfx-backend-vulkan, gfx-backend-metal, freetype

libloading is duplicated because of ash

Differential Revision: https://phabricator.services.mozilla.com/D84688
2020-07-24 15:59:54 +00:00
Mihai Alexandru Michis
c3d9e17fa4 Backed out changeset 45fc4a780b2b (bug 1654699) for causing failures regarding AudioStream position.
CLOSED TREE
2020-07-23 23:13:52 +03:00
Jeff Muizelaar
4b666af85b Bug 1654699. Update core-foundation/core-graphics. r=kvark,keeler,chunmin
This includes updates to authenticator, cubeb-coreaudio,
metal, gfx-backend-vulkan, gfx-backend-metal, freetype

libloading is duplicated because of ash

Differential Revision: https://phabricator.services.mozilla.com/D84688
2020-07-23 17:01:14 +00:00
Dzmitry Malyshau
74b412c826 Bug 1641370 - Add optional SPIR-V shader validation to WebGPU, via naga r=jgilbert
This change attempts to parse the incoming SPIR-V shader modules with
Naga SPIR-V front-end. It's not complete, but it returns an Error if it's unable to parse,
in which case we just continue without the validation (for now).
If it succeeds, we extract the reflection information from it, and use it for the pipeline.

This is just a start. More states would need to be validated, and SPIR-V front-end needs more work.

Differential Revision: https://phabricator.services.mozilla.com/D77170
2020-06-22 21:21:18 +00:00
Dzmitry Malyshau
421a94b374 Bug 1637998 - Fix multi-threaded cleanup of wgpu command pools r=groves
Differential Revision: https://phabricator.services.mozilla.com/D77156
2020-05-31 04:14:17 +00:00
Dzmitry Malyshau
e5e0a70cb4 Bug 1637998 - Hook up loom for concurrency testingting of wgpu r=groves
Differential Revision: https://phabricator.services.mozilla.com/D77159
2020-05-28 03:38:21 +00:00
Dzmitry Malyshau
d6f8c568eb Bug 1637998 - Make wgpu pass destruction more explicit r=groves
The old way of calling `into_vec` on destruction was awkward

Differential Revision: https://phabricator.services.mozilla.com/D77154
2020-05-28 03:12:13 +00:00
Dzmitry Malyshau
9c32261cd8 Bug 1637998 - wgpu create_surface refactor r=groves
just reducing some code

Differential Revision: https://phabricator.services.mozilla.com/D77150
2020-05-28 03:07:42 +00:00
Dzmitry Malyshau
abaaa872a5 Bug 1634425 - Integrate WebGPU API tracing r=jgilbert
This is the logic of tracing the WebGPU API calls at the level of wgpu-core,
serialized into a folder of choosing on the user drive. Traces are extremely portable,
they can be shared (on BugZilla) and then replayed on the developer machine,
which can have a different architecture from the users machine.

The standalone player is introduced in `gfx/wgpu/player`, similar to WebRender's Wrench.

The output dir is controlled by "dom.webgpu.traceDir" pref. No tracing happens if it's empty.

Differential Revision: https://phabricator.services.mozilla.com/D73333
2020-05-27 16:49:03 +00:00
Bogdan Tara
6ed3c943f7 Backed out changeset f4ed4d3e0e9e (bug 1634425) for hazard failure on WebGPUParent.cpp CLOSED TREE 2020-05-27 01:12:40 +03:00
Dzmitry Malyshau
67c0d914f3 Bug 1634425 - Integrate WebGPU API tracing r=jgilbert
This is the logic of tracing the WebGPU API calls at the level of wgpu-core,
serialized into a folder of choosing on the user drive. Traces are extremely portable,
they can be shared (on BugZilla) and then replayed on the developer machine,
which can have a different architecture from the users machine.

The standalone player is introduced in `gfx/wgpu/player`, similar to WebRender's Wrench.

The output dir is controlled by "dom.webgpu.traceDir" pref. No tracing happens if it's empty.

Differential Revision: https://phabricator.services.mozilla.com/D73333
2020-05-26 21:15:40 +00:00
Dzmitry Malyshau
3e9c29fbeb Bug 1633661 - Keep wgpu bind group layouts alive r=groves
Differential Revision: https://phabricator.services.mozilla.com/D75340
2020-05-15 15:10:10 +00:00
Dzmitry Malyshau
4a18e10f04 Bug 1637998 - Fix wgpu swapchain cleanup on exit r=groves
Differential Revision: https://phabricator.services.mozilla.com/D75337
2020-05-15 14:59:18 +00:00
Dzmitry Malyshau
04f9e98d99 Bug 1637998 - Improve wgpu assertion errors r=groves
this improves the assertion messages, adds issue templates, and implements `From<TextureFormat>` for `TextureComponentType`.

Differential Revision: https://phabricator.services.mozilla.com/D75322
2020-05-15 02:11:41 +00:00
Dzmitry Malyshau
7bd6183491 Bug 1634239 - Keel WebGPU adapter alive r=groves
The internal logic accesses adapters during command recording.
This PR makes up to keep that reference for while the device lives.

Differential Revision: https://phabricator.services.mozilla.com/D73278
2020-05-01 14:29:04 +00:00
Dzmitry Malyshau
01bd7e3c8a Bug 1632323 - Separate WebGPU internal usage bits from the public API r=groves
Differential Revision: https://phabricator.services.mozilla.com/D72065
2020-04-23 15:52:01 +00:00
Dzmitry Malyshau
4b29474d3f Bug 1630813 - Remove gfx/wgpu/wgpu-native, move wgpu-remote out into gfx/wgpu_bindings r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D71699
2020-04-22 15:35:13 +00:00
Dzmitry Malyshau
dee044c7f2 Bug 1629738 - Keep WebGPU pipeline layouts alive r=jgilbert
We need to access the contents of pipeline layouts on CPU
when we are recording commands. This PR adds refcounting to them
and improves the destruction code path to happen once all references are gone.

Differential Revision: https://phabricator.services.mozilla.com/D70868

--HG--
extra : moz-landing-system : lando
2020-04-14 21:51:45 +00:00
Dzmitry Malyshau
97fcffa123 Bug 1629896 - Fix WebGPU vertex format values r=jgilbert
it wasn't matching webgpu-native or the WebIDL

Differential Revision: https://phabricator.services.mozilla.com/D70942

--HG--
extra : moz-landing-system : lando
2020-04-14 21:21:21 +00:00
Dzmitry Malyshau
86ff5eeab6 Bug 1629739 - Fix WebGPU buffer unmap warning r=jgilbert
it was a bogus warning that erroneously fire when Gecko flushed mapped contents

Differential Revision: https://phabricator.services.mozilla.com/D70789

--HG--
extra : moz-landing-system : lando
2020-04-14 21:09:17 +00:00
Dzmitry Malyshau
15435c2bf5 Bug 1622846 - Update WebGPU TextureDescriptor API r=jgilbert,webidl,smaug
Differential Revision: https://phabricator.services.mozilla.com/D70762

--HG--
extra : moz-landing-system : lando
2020-04-14 12:52:03 +00:00
Dzmitry Malyshau
964f4f889c Bug 1629605 - wgpu tracking fixes r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D70707

--HG--
extra : moz-landing-system : lando
2020-04-14 00:32:50 +00:00
Brindusan Cristian
090d7a16dc Backed out changeset 2c1a2c08592a (bug 1629605) for sm bustages. CLOSED TREE 2020-04-14 03:11:24 +03:00
Dzmitry Malyshau
64c80998c6 Bug 1629605 - wgpu tracking fixes r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D70707

--HG--
extra : moz-landing-system : lando
2020-04-13 22:46:31 +00:00
Dzmitry Malyshau
a3e5cb126b Bug 1617369 - Rustfmt pass over gfx/wgpu r=sylvestre
uses the default config with rustfmt-stable

Differential Revision: https://phabricator.services.mozilla.com/D70698

--HG--
extra : moz-landing-system : lando
2020-04-13 17:26:41 +00:00
Dzmitry Malyshau
e8a60d2eab Bug 1624174 - Update wgpu to get the coordinate spaces right r=jgilbert
The updated wgpu has the coordinate space fixes.
Depends on

  - https://phabricator.services.mozilla.com/D70421
  - https://phabricator.services.mozilla.com/D70432
  - https://phabricator.services.mozilla.com/D70646

Differential Revision: https://phabricator.services.mozilla.com/D70140

--HG--
rename : third_party/rust/rendy-descriptor/Cargo.toml => third_party/rust/gfx-descriptor/Cargo.toml
rename : third_party/rust/rendy-memory/Cargo.toml => third_party/rust/gfx-memory/Cargo.toml
rename : third_party/rust/rendy-memory/src/allocator/dynamic.rs => third_party/rust/gfx-memory/src/allocator/general.rs
rename : third_party/rust/rendy-memory/src/heaps/heap.rs => third_party/rust/gfx-memory/src/heaps/heap.rs
rename : third_party/rust/rendy-memory/src/utilization.rs => third_party/rust/gfx-memory/src/stats.rs
extra : moz-landing-system : lando
2020-04-13 13:42:15 +00:00
Dzmitry Malyshau
540f1bea3f Bug 1629359 - Update parking_lot to 0.10 r=kats
Differential Revision: https://phabricator.services.mozilla.com/D70646

--HG--
rename : third_party/rust/parking_lot/src/mutex.rs => third_party/rust/parking_lot/src/fair_mutex.rs
extra : moz-landing-system : lando
2020-04-12 19:14:43 +00:00
Stefan Hindli
a8922cc7ff Backed out changeset 01cb2f16985e (bug 1629359) for linux x64 qr webgpu bustage
--HG--
extra : rebase_source : 29e879b00d66376a0508bc2df060fcf3f6028590
2020-04-12 22:09:15 +03:00
Dzmitry Malyshau
80f2377b05 Bug 1629359 - Update parking_lot to 0.10 r=kats
Differential Revision: https://phabricator.services.mozilla.com/D70646

--HG--
rename : third_party/rust/parking_lot/src/mutex.rs => third_party/rust/parking_lot/src/fair_mutex.rs
extra : moz-landing-system : lando
2020-04-12 16:25:25 +00:00
Dzmitry Malyshau
34dac56d81 Bug 1628754 - CBindGen update to 0.14.1 r=emilio,kats
Differential Revision: https://phabricator.services.mozilla.com/D70421

--HG--
extra : moz-landing-system : lando
2020-04-10 19:13:25 +00:00
Mihai Alexandru Michis
6013b44308 Backed out changeset e60ce7274c9f (bug 1628754) for causing bustages in ServoStyleConsts.h
CLOSED TREE
2020-04-10 04:05:15 +03:00
Dzmitry Malyshau
e71799ed9d Bug 1628754 - Cbindgen update to 0.14.0 r=kats
Differential Revision: https://phabricator.services.mozilla.com/D70421

--HG--
extra : moz-landing-system : lando
2020-04-09 21:10:40 +00:00
Dzmitry Malyshau
3021defc28 Bug 1602133 - WebGPU presentation r=jgilbert,webidl,smaug,aosmond
This change adds support for CanvasContext presenting WebGPU via CPU readback.
The presentation is handled mostly on GPU process side by managing a list of staging buffers
and copying the contents into a WR external image (backed by an external buffer).

Differential Revision: https://phabricator.services.mozilla.com/D68032

--HG--
extra : moz-landing-system : lando
2020-04-06 22:29:18 +00:00
Cosmin Sabou
2f4d9af7d3 Backed out changeset bc6b2b003c6e (bug 1602133) for causing build bustages on CanvasRenderingContextHelper.cpp.
--HG--
extra : histedit_source : 917f3627a3e3f8dab0d806b69fc716bfd9f1d483
2020-04-06 23:46:51 +03:00
Dzmitry Malyshau
5004affc0e Bug 1602133 - WebGPU presentation r=jgilbert,webidl,smaug,aosmond
This change adds support for CanvasContext presenting WebGPU via CPU readback.
The presentation is handled mostly on GPU process side by managing a list of staging buffers
and copying the contents into a WR external image (backed by an external buffer).

Differential Revision: https://phabricator.services.mozilla.com/D68032

--HG--
extra : moz-landing-system : lando
2020-04-06 20:10:03 +00:00
Bogdan Tara
7f7cc68c64 Backed out changeset 377a757c583d (bug 1602133) for webgpu related bustages CLOSED TREE 2020-04-06 21:59:57 +03:00
Dzmitry Malyshau
4c3a924336 Bug 1602133 - WebGPU presentation r=jgilbert,webidl,smaug,aosmond
This change adds support for CanvasContext presenting WebGPU via CPU readback.
The presentation is handled mostly on GPU process side by managing a list of staging buffers
and copying the contents into a WR external image (backed by an external buffer).

Differential Revision: https://phabricator.services.mozilla.com/D68032

--HG--
extra : moz-landing-system : lando
2020-04-02 19:55:01 +00:00
Dzmitry Malyshau
dcf75e7f03 Bug 1622261 - Refactor the ID recycling to always cycle through the GPU process
Previously, we kept the object IDs managed on content side only.
The GPU side would work with given indices.
When an object is destroyed, we'd free the ID on the content side and signal the GPU to delete the object.
Problem is that on the GPU process the object may still be kept alive for as long as any dependants are alive.

What this change is doing - hooking up the callbacks to the *actual* freeing of IDs on the GPU side.
These callbacks end up in messages from WebGPUParent to WebGPUChild, and only then the IDs are freed
on the content side and able to be reused.

Differential Revision: https://phabricator.services.mozilla.com/D67211

--HG--
extra : moz-landing-system : lando
2020-03-23 07:54:08 +00:00
Dzmitry Malyshau
80b79d4414 Bug 1622846 - WebGPU bindings update to the spec r=jgilbert,webidl,smaug
Updates `wgpu` code as well as our WebIDL bindings.

The `wgpu-types` is a new component crate that has public types available to
Rust applications that target the Web directly.

Differential Revision: https://phabricator.services.mozilla.com/D67013

--HG--
extra : moz-landing-system : lando
2020-03-16 21:32:37 +00:00
Dzmitry Malyshau
1b1bc98a76 Bug 1614703 - WebGPU render pipeline creation r=jgilbert,webidl,baku
Differential Revision: https://phabricator.services.mozilla.com/D64833

--HG--
extra : moz-landing-system : lando
2020-03-03 16:37:02 +00:00
Mihai Alexandru Michis
1e6afc5e96 Backed out changeset f1c86e7d23cd (bug 1614703) for causing bustages in WebGPUParent.cpp
CLOSED TREE
2020-03-03 17:23:55 +02:00
Dzmitry Malyshau
53a10a49a5 Bug 1614703 - WebGPU render pipeline creation r=jgilbert,webidl,baku
Differential Revision: https://phabricator.services.mozilla.com/D64833

--HG--
extra : moz-landing-system : lando
2020-03-03 15:08:24 +00:00
Dzmitry Malyshau
5437a922a7 Bug 1614702 - WebGPU textures, texture views, and samplers r=jgilbert,webidl,smaug
this change adds an ability to create WebGPU textures, views, and samplers

Differential Revision: https://phabricator.services.mozilla.com/D63595

--HG--
extra : source : 8f51a5fac21cb52e2ddb647f0b99a9bfccb41f6a
2020-02-24 20:12:16 +00:00
Dorel Luca
0d23881940 Backed out changeset 8f51a5fac21c (bug 1614702) for build-notarization failures. CLOSED TREE 2020-02-25 00:54:54 +02:00
Dzmitry Malyshau
757896954c Bug 1614702 - WebGPU textures, texture views, and samplers r=jgilbert,webidl,smaug
this change adds an ability to create WebGPU textures, views, and samplers

Differential Revision: https://phabricator.services.mozilla.com/D63595

--HG--
extra : moz-landing-system : lando
2020-02-24 20:12:16 +00:00
Dzmitry Malyshau
199a362906 Bug 1602131 - WebGPU render passes r=jgilbert,webidl,smaug
Adds support for recording render passes in WebGPU.
The `wgpu` logo is also added to the repository ("gfx/wgpu/logo.png") under [CC-BY-SA](https://creativecommons.org/licenses/by-sa/3.0/) license.

Differential Revision: https://phabricator.services.mozilla.com/D62461

--HG--
extra : moz-landing-system : lando
2020-02-19 19:25:30 +00:00
Dzmitry Malyshau
be7fae486d Bug 1609175 - WebGPU bind groups and compute pipelines r=jgilbert,webidl,smaug,bzbarsky
Adds support for bind groups and compute pipelines
The end goal of this PR is to run the compute example.

Differential Revision: https://phabricator.services.mozilla.com/D60746

--HG--
extra : moz-landing-system : lando
2020-01-24 16:27:09 +00:00