Upgrade wgpu and naga to 30, accesskit to 0.25 - #2
Closed
chris-addison wants to merge 1 commit into
Closed
chris-addison wants to merge 1 commit into
chris-addison wants to merge 1 commit into
Conversation
- wgpu 29 -> 30.0.1 and naga 29 -> 30.0.1. API changes: surfaces take a color_space (SurfaceColorSpace::Auto, wgpu's pre-30 behavior), adapter requests take apply_limit_buckets (false), present() moved to Queue::present, metal texture_from_raw takes a drop callback (None) and create_texture_from_hal takes the initial state (UNINITIALIZED, what 29 hard-coded). - accesskit 0.24 -> 0.25.1, with accesskit_consumer 0.39.1, accesskit_macos 0.27.1, accesskit_unix 0.24.0 and accesskit_windows 0.35.1, so every platform adapter shares one consumer. Tree is renamed TreeInfo. - wgsl-rs: drop the workspace-wide validation feature, which only backs macro-generated #[cfg(test)] tests but linked wgsl-rs's own naga 29 into every consumer's build. gpui_render enables it as a dev-dependency, and its subpixel test validates with the workspace naga directly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Collaborator
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #1 (targets
unity/dependency-cleanup).Changes
SurfaceConfiguration.color_space: set toSurfaceColorSpace::Auto, which wgpu documents as its pre-30 behavior (sRGB, or extended linear sRGB for anRgba16Floatsurface).RequestAdapterOptions.apply_limit_buckets: set tofalse. Limit bucketing is an anti-fingerprinting option for code that exposes wgpu to untrusted content, which native gpui doesn't do.SurfaceTexture::present()becameQueue::present(frame).hal::metal::Device::texture_from_rawgained a drop callback:None, as before.Device::create_texture_from_halgainedinitial_state:TextureUses::UNINITIALIZED, which is what wgpu-core 29 hard-coded for every wrapped texture.accesskit_consumer0.39.1,accesskit_macos0.27.1,accesskit_unix0.24.0 andaccesskit_windows0.35.1. Before this, Windows used consumer 0.37 while macOS and Linux used 0.38; now there's one.accesskit::Treewas renamedTreeInfo.validationis no longer on workspace-wide. That feature only backs the#[cfg(test)]validation tests the#[wgsl]macro generates, but it linked wgsl-rs's own naga, still 29 at wgsl-rs's latest commit, into every consumer's normal build. Upgrading gpui to naga 30 would otherwise have left downstream builds with naga 24, 29 and 30.gpui_render, the only crate with#[wgsl]modules, enables it as a dev-dependency, so those 13 generated tests still run.gpui_render'sbuild.rsalready validates every pipeline's WGSL with the workspace naga on every build.wgsl_rs::validate_wgsl_sourcecall, inshaders/tests.rs, now validates with naga 30 directly.As a result, downstream builds carry only naga 30 plus the deliberate
naga-old24 floor validator.hashbrown0.15/0.16 andgpu-descriptoralso drop out, since wgpu 30 and the new accesskit are on hashbrown 0.17.objc20.5 stays on macOS: evenaccesskit_macos0.27.1 still depends on it.Verification
cargo clippy -p gpui-ce -p gpui_ce_platform -p gpui_ce_render -p gpui_ce_wgpu -p gpui_ce_macos -p gpui_ce_apple --all-targets -- -D warningsis clean.cargo testfor gpui-ce, gpui_ce_render, gpui_ce_wgpu, gpui_ce_macos and gpui_ce_apple passes, including the headless GPU primitives and the 13 macro-generated WGSL validation tests.-D warningsonx86_64-pc-windows-gnu, withscreen-capture, is clean. The sameredundant_cloneatgpui_windows/src/directx_renderer.rsthat the base commit already has is allowed on the command line for that run.cargo fmt --all -- --checkis clean.🤖 Generated with Claude Code