Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve error message for vkCmdDraw-None-08600 #9068

Open
arno-lunarg opened this issue Dec 20, 2024 · 2 comments
Open

Improve error message for vkCmdDraw-None-08600 #9068

arno-lunarg opened this issue Dec 20, 2024 · 2 comments
Assignees
Labels
Enhancement New feature or request

Comments

@arno-lunarg
Copy link
Contributor

Example:

Self Validation Error: [ VUID-vkCmdDraw-None-08600 ] Object 0: handle = 0x7323f50000000048, type = VK_OBJECT_TYPE_PIPELINE; Object 1: handle = 0x4fac1c0000000032, type = VK_OBJECT_TYPE_PIPELINE_LAYOUT; Object 2: handle = 0xa808d50000000033, type = VK_OBJECT_TYPE_PIPELINE_LAYOUT; Object 3: handle = 0x4fac1c0000000032, type = VK_OBJECT_TYPE_PIPELINE_LAYOUT; | MessageID = 0x4768cf39 | vkCmdDraw(): The VkPipeline 0x7323f50000000048[] (created with a union of layouts [ VkPipelineLayout 0x4fac1c0000000032[] VkPipelineLayout 0xa808d50000000033[] ]) statically uses descriptor set 31, but all sets 0 to 31 are not compatible with the pipeline layout bound with vkCmdBindDescriptorSets (VkPipelineLayout 0x4fac1c0000000032[])
Set 1 contains a null set which is considered non-compatible
The Vulkan spec states: For each set n that is statically used by a bound shader, a descriptor set must have been bound to n at the same pipeline bind point, with a VkPipelineLayout that is compatible for set n, with the VkPipelineLayout used to create the current VkPipeline or the VkDescriptorSetLayout array used to create the current VkShaderEXT , as described in Pipeline Layout Compatibility (https://docs.vulkan.org/spec/latest/chapters/drawing.html#VUID-vkCmdDraw-None-08600)

It is unclear what "set 1" refers to. This is just one example, the "describe difference" part of this error message generally needs improvements. IMO we need to not only mention the difference, telling precisely what part of the described difference comes from what, but also log how both pipeline layout look like. Maybe just the relevant parts, here for instance the descriptor set layouts, not necessarily the push constant ranges layout

@arno-lunarg arno-lunarg added the Enhancement New feature or request label Dec 20, 2024
@spencer-lunarg
Copy link
Contributor

It is unclear what "set 1" refers to.

You didn't bind a Descriptor Set at "set index 1" in your command buffer (for GLSL it would be set = 1)

I guess not sure how else to reference that unbound set other than "set 1" here (since there is not handle to point at)

@arno-lunarg
Copy link
Contributor Author

arno-lunarg commented Dec 20, 2024

If I follow things correctly, I think you got caught too! The code to describe the difference is the following:

       const auto &descriptor_set_layouts = *set_layouts_id.get();
        const auto &other_ds_layouts = *other.set_layouts_id.get();
        for (uint32_t i = 0; i <= set; i++) {
            if (descriptor_set_layouts[i] != other_ds_layouts[i]) {
                if (!descriptor_set_layouts[i] || !other_ds_layouts[i]) {
                    ss << "Set layout " << i << " contains a null set which is considered non-compatible\n";
                    break;
                }
                return descriptor_set_layouts[i]->DescribeDifference(i, *other_ds_layouts[i]);
            }
        }

So only descriptor set layouts are considered, not actual bound descriptor set. And which pipeline layout has this null descriptor set layout, and what is the other descriptor set layout that is not null? I think the error message should answer those questions

@spencer-lunarg spencer-lunarg self-assigned this Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants