From a96271374d64a9e345fbed5cec7737e31f0e167c Mon Sep 17 00:00:00 2001 From: Andy Leiserson Date: Wed, 1 Jul 2026 12:04:20 -0700 Subject: [PATCH] Cherry pick "fix(metal): Restore the `Queue::as_raw` method" to v29 (#9789) --- CHANGELOG.md | 4 ++++ wgpu-hal/src/metal/mod.rs | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 331943248..04d1e3326 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -44,6 +44,10 @@ Bottom level categories: ### Bug Fixes +#### Metal + +- Restore the `Queue::as_raw` method, which was removed without good reason in v29. It now returns `&ProtocolObject`. By @andyleiserson in [#9560](https://github.com/gfx-rs/wgpu/pull/9560). + #### Vulkan - Fixed `VUID-RuntimeSpirv-vulkanMemoryModel-06265` validation errors by enabling `vulkanMemoryModelDeviceScope` whenever the Vulkan memory model is enabled, since the SPIR-V backend emits storage atomics with `Device` scope. By @francisdb in [#9741](https://github.com/gfx-rs/wgpu/pull/9741). diff --git a/wgpu-hal/src/metal/mod.rs b/wgpu-hal/src/metal/mod.rs index 5006048a5..83688e8a0 100644 --- a/wgpu-hal/src/metal/mod.rs +++ b/wgpu-hal/src/metal/mod.rs @@ -477,6 +477,10 @@ impl Queue { timestamp_period, } } + + pub fn as_raw(&self) -> &ProtocolObject { + &self.shared.raw + } } #[derive(Debug)]