KhronosGroup / Vulkan-Docs

The Vulkan API Specification and related tools
Other
2.75k stars 462 forks source link

Runtime SPIR-V VUIDs that could be validated standalone #2267

Open Rua opened 10 months ago

Rua commented 10 months ago

The Runtime SPIR-V section of the spec is supposed to contain things that can only be validated at runtime, because they rely on properties of the device, enabled features, or input data from the user. But the following VUIDs don't seem to rely on anything at runtime, they use only information that's known from the SPIR-V code. So they should probably be moved to the Standalone SPIR-V section.

spencer-lunarg commented 10 months ago

VUID-RuntimeSpirv-OpImageWrite-07112

You need to know the descriptor bound to it in order to match the VkFormat

Rua commented 10 months ago

You need to know the descriptor bound to it in order to match the VkFormat

If the format is specified in the shader itself, do you not know how many components it has?

gnl21 commented 10 months ago

You need to know the descriptor bound to it in order to match the VkFormat

If the format is specified in the shader itself, do you not know how many components it has?

Yes, the table referred to in the VU gives the VkFormat corresponding to the format used in the SPIR-V code. It's not a reference to the actual format of the descriptor in this case. The VU that matches with the actual descriptor format it, for example, VUID-vkCmdDraw-OpImageWrite-08795.