-
Notifications
You must be signed in to change notification settings - Fork 475
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
Fix the CullPrimitiveEXT VUID's #2475
base: main
Are you sure you want to change the base?
Fix the CullPrimitiveEXT VUID's #2475
Conversation
0ce6b9b
to
370033f
Compare
370033f
to
35c1e28
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I don't think this is correct. When CullPrimitiveEXT is part of a Block, it must be a plain bool, but if it's declared as a standalone OpVariable, i.e. not in a Block, it must be an array of booleans, so I think this VUID needs to cover both cases. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not correct I think as stated above.
GLSL spec has folowing definition
Then the array validation rule will applly to all the other builtins like PrimitiveId , Layer etc? Because currently none of the other builtins have such a validation rule |
We will then probably need new VUID's for each of the above builtins. Kindly review these three new VUID's for CullPrimitiveEXT, i can replicate it for all the other builtins:
|
35c1e28
to
e6e4c04
Compare
@HansKristian-Work can you review the new VUID's. Based on how they look, I will add VUID's for other builtins defined in gl_MeshPerPrimitiveEXT |
be used as part of a structure or as a array of boolean. Corresponding VUID changes are also needed for PrimitiveID, Layer, ViewPortIndex, PrimitiveShadingRateEXT
e6e4c04
to
95ed035
Compare
code:CullPrimitiveEXT must: be declared as a boolean value member of a structure or a variable of type code:OpTypeArray of boolean values. | ||
* If code:CullPrimitiveEXT declared as an array of boolean values. The size of the array | ||
decorated with code:CullPrimitiveEXT must: match the value specified by code:OutputPrimitivesEXT | ||
* If code:CullPrimitiveEXT is a member of a structure, there must: be a variable declared | ||
which is array of parent strucure that contains code:CullPrimitiveEXT. The size of the array must: match the value specified by code:OutputPrimitivesEXT. | ||
* There must be only one declaration of the code:CullPrimitiveEXT associated with a entry | ||
point's interface. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
code:CullPrimitiveEXT must: be declared as a boolean value member of a structure or a variable of type code:OpTypeArray of boolean values. | |
* If code:CullPrimitiveEXT declared as an array of boolean values. The size of the array | |
decorated with code:CullPrimitiveEXT must: match the value specified by code:OutputPrimitivesEXT | |
* If code:CullPrimitiveEXT is a member of a structure, there must: be a variable declared | |
which is array of parent strucure that contains code:CullPrimitiveEXT. The size of the array must: match the value specified by code:OutputPrimitivesEXT. | |
* There must be only one declaration of the code:CullPrimitiveEXT associated with a entry | |
point's interface. | |
code:CullPrimitiveEXT must: decorate a scalar boolean member of a structure decorated as code:Block, or decorate a variable of type code:OpTypeArray of boolean values. | |
* If code:CullPrimitiveEXT is declared as an array of boolean values, the size of the array | |
must: match the value specified by code:OutputPrimitivesEXT | |
* If code:CullPrimitiveEXT decorates a member of a structure, the variable declaration of the containing code:Block type must: have an array size that matches the value specified by code:OutputPrimitivesEXT | |
* There must be only one declaration of the code:CullPrimitiveEXT associated with a entry | |
point's interface. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this language reads closer to the rest of the spec, but otherwise, the gist of it is fine.
Fixes bug https://gitlab.khronos.org/vulkan/vulkan/-/issues/3296