Skip to content

Passthrough: Error on layout: None instead of creating an invalid pipeline layout #8854

@Firestar99

Description

@Firestar99

Is your feature request related to a problem? Please describe.
When you create a graphics pipeline with wgpu with a "normal" shader module, you can pass layout: None for wgpu to automatically create the pipeline layout for you. But you switch the shader module to a passthrough one, wgpu will still try to automatically create a pipeline layout, fail to find any information on the shader, and creating one without any bindings. Which in Vulkan trips the validation layers, if you remember to turn them on, or you just get random segfaults in the driver (RADV).

Describe the solution you'd like
Could wgpu just hard error when you create a graphics pipeline with a passthrough shader module and layout: None, instead of creating an mismatched pipeline layout that may segfault drivers?

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions