-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Wgpu 0.20 #13186
Wgpu 0.20 #13186
Conversation
Technically we should wait for gfx-rs/wgpu#5681 to be backported before landing this, but that's supposed to be merged and released tomorrow (May 29th). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested a bunch of 2d and 3d examples on windows 10 with a 4080 and everything worked correctly.
Would be nice not having TODOs, but they can be addressed later. We should still ship 0.14 with this
LGTM
The Todos shouldn't have any effect anyways, since they're for pipeline override constants which don't work on web currently (and aren't yet supported in naga_oil). |
examples/3d_shapes dies of SIGBUS after ~5s on NixOS Unstable, RX6600. 2024-05-28.20-49-41.mp4with EDIT: i relogged and now i can't reproduce it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested a bunch of 3d examples with VK + DX12, lgtm.
2024-05-29T06:50:45.203720Z INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "Windows 11 Home", kernel: "22631", cpu: "Intel(R) Core(TM) Ultra 7 155H", core_count: "16", memory: "15.6 GiB" }
2024-05-29T06:50:45.241110Z INFO bevy_winit::system: Creating new window "App" (Entity { index: 0, generation: 1 })
2024-05-29T06:50:45.572420Z INFO bevy_render::renderer: AdapterInfo { name: "Intel(R) Arc(TM) Graphics", vendor: 32902, device: 32085, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Dx12 }
Tested a bunch of examples on an Apple M1 Pro and they all looked good. |
Tested on Windows 11 with a 4070 + both Vulkan & Dx12.
|
I tracked down what's causing the crash (using multiple command encoders) and made a wgpu issue for it gfx-rs/wgpu#5774. |
v0.20.1 is out now, thanks @Elabajaba for pushing this through! |
We should check if this is fixed now: bevy/crates/bevy_render/src/renderer/mod.rs Line 372 in 2cffd14
|
no issue in CI after the wgpu 0.20.1 update on the examples 🎉 |
@@ -17,7 +17,7 @@ bevy_reflect = { path = "../bevy_reflect", version = "0.14.0-dev", features = [ | |||
bytemuck = { version = "1", features = ["derive"] } | |||
serde = { version = "1.0", features = ["derive"], optional = true } | |||
thiserror = "1.0" | |||
wgpu-types = { version = "0.19", default-features = false, optional = true } | |||
wgpu-types = { version = "0.20", default-features = false, optional = true } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wgpu-types = { version = "0.20", default-features = false, optional = true } | |
wgpu-types = { version = "0.20.1", default-features = false, optional = true } |
If 0.20.0 was so problematic, we should prevent it from being pulled in by making 0.20.1 the minimum version.
@@ -70,15 +70,15 @@ codespan-reporting = "0.11.0" | |||
# It is enabled for now to avoid having to do a significant overhaul of the renderer just for wasm. | |||
# When the 'atomics' feature is enabled `fragile-send-sync-non-atomic` does nothing | |||
# and Bevy instead wraps `wgpu` types to verify they are not used off their origin thread. | |||
wgpu = { version = "0.19.3", default-features = false, features = [ | |||
wgpu = { version = "0.20", default-features = false, features = [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wgpu = { version = "0.20", default-features = false, features = [ | |
wgpu = { version = "0.20.1", default-features = false, features = [ |
I'm planning to merge this in right at the start of the 0.15 cycle. |
Is it possible we could get this in 0.14 and address any stability issues, if they happen, in further 0.14.x releases? |
I'll check with the rendering SMEs and other maintainers :) |
Great; there's agreement to ship this in 0.14. Let me do a quick pass then let's get this merged. |
Diff looks reasonable, and it seems like the other issues are now resolved. Merging! |
Awesome, thanks so much! |
Currently blocked on gfx-rs/wgpu#5774 # Objective Update to wgpu 0.20 ## Solution Update to wgpu 0.20 and naga_oil 0.14. ## Testing Tested a few different examples on linux (vulkan, webgl2, webgpu) and windows (dx12 + vulkan) and they worked. --- ## Changelog - Updated to wgpu 0.20. Note that we don't currently support wgpu's new pipeline overridable constants, as they don't work on web currently and need some more changes to naga_oil (and are somewhat redundant with naga_oil's shader defs). See wgpu's changelog for more https://github.com/gfx-rs/wgpu/blob/trunk/CHANGELOG.md#v0200-2024-04-28 ## Migration Guide TODO --------- Co-authored-by: Alice Cecile <alice.i.cecile@gmail.com> Co-authored-by: François Mockers <mockersf@gmail.com>
Currently blocked on gfx-rs/wgpu#5774
Objective
Update to wgpu 0.20
Solution
Update to wgpu 0.20 and naga_oil 0.14.
Testing
Tested a few different examples on linux (vulkan, webgl2, webgpu) and windows (dx12 + vulkan) and they worked.
Changelog
wgpu
0.20,naga
0.20, andnaga_oil
0.14. Note that we don't currently support wgpu's new pipeline overridable constants, as they don't work on web currently and need some more changes to naga_oil (and are somewhat redundant with naga_oil's shader defs). See wgpu's changelog for more https://github.com/gfx-rs/wgpu/blob/trunk/CHANGELOG.md#v0200-2024-04-28const
contexts (eg.abs
,cos
,floor
,max
, etc, see https://github.com/gfx-rs/wgpu/blob/v0.20/CHANGELOG.md#wgsl-const-evaluation-for-many-more-built-ins for the whole list)u64
andi64
are now supported in shaders on supported hardware (requires theSHADER_INT64
feature, supported on desktop Vulkan, DX12 with DXC, and Metal with MSL 2.3+)Migration Guide
wgpu
0.20,naga
0.20, andnaga_oil
0.14Capabilities
should now be properly detected and supported.TIMESTAMP_QUERY_INSIDE_ENCODERS
wgpu feature to check for support.const
contexts (eg.abs
,cos
,floor
,max
, etc, see https://github.com/gfx-rs/wgpu/blob/v0.20/CHANGELOG.md#wgsl-const-evaluation-for-many-more-built-ins for the whole list)u64
andi64
are now supported in shaders on supported hardware (requires theSHADER_INT64
feature, supported on desktop Vulkan, DX12 with DXC, and Metal with MSL 2.3+)