Closed teoxoy closed 7 months ago
The SPIR-V spec says that the BufferBlock
decoration is deprecated, and says we should instead:
use Block-decorated StorageBuffer Storage Class objects
Maybe there are details here, but generally we should take deprecation at face value.
Maybe the ideal solution would be to have the SPIR-V backend take an option to indicate whether it should require SPV_KHR_storage_buffer_storage_class
or instead fall back to the BufferBlock
decoration. Then wgpu-core
could look at the device, and check the device for VK_KHR_storage_buffer_storage_class
to see how it should set the Naga option.
Since the Naga issues and WGPU issues were merged, this is now really just a duplicate of #3348. Let's track further work there.
The
SPV_KHR_storage_buffer_storage_class
extension requires theVK_KHR_storage_buffer_storage_class
extension which might not be supported. We can instead conditionally translate storage buffers toUniform
address space and decorate them withBufferBlock
.wgpu issue: https://github.com/gfx-rs/wgpu/issues/3348