-
Notifications
You must be signed in to change notification settings - Fork 572
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
Validator should not check for capability when seeing decorations of ClipDistance, CullDistance, or PointSize #365
Comments
I fixed the title, as this should not be generalized beyond ClipDistance, CullDistance, and PointSize. |
I made that change to the validator on July 7: But it's conditioned on using a Vulkan 1.0 context, since it was a Vulkan decision to relax that rule. The master branch of the Vulkan layers tree specifies revision 6c61bf2 from July 22 which should be fresh enough. And its only call to spvContextCreate does use SPV_ENV_VULKAN_1_0. |
Commented on the layers bug suggesting that maybe the command line tool was not being used, and that you should use |
What situation should error on ClipDistance (et. al.) Decoration with no capability? I don't think there is one; rather the validator should unconditionally tolerate ClipDistance/CullDistance/PointSize decoration, and not require specific options be specified to do so. |
The basic rule applied is any mention of an enum that lists a required capability may only be in a module that declares that capability. That's even as a decoration. In particular we now have OpenGL environments in SPIRV-Tools. Almost certainly the same rule override would apply there. Since it's basically the same GLSL variation is going to be used any time ClipDistance (and friends) is to be used, there's a strong argument to say the rule should always be relaxed for ClipDistance, CullDistance, PointSize. I would guess that's your recommendation @johnkslang ? |
Yes, the exception is driven by whether it is ClipDistance/CullDistance/PointSize, and not driven by what the environment is. The general rule (decoration requires capability), would also apply universally, unless it was ClipDistance/CullDistance/PointSize. So, slice along decoration name, not along environment. |
Ok. I'll do that. |
FYI. The previous relaxation was prompted by #261 |
FYI. Mention of PointSize as a BuiltIn will still trigger requirement of the Shader capability. Nobody has complained about that yet. |
So, we need to reopen? That's not to spec. Note this is all "spirit of the law" as well as now to spec.:
|
Fixes KhronosGroup#365 which was reopened for this.
Fixes KhronosGroup#365 which was reopened for this.
Fixes KhronosGroup#365 which was reopened for this.
Fixes KhronosGroup#365 which was reopened for this.
See KhronosGroup/Vulkan-LoaderAndValidationLayers#858, KhronosGroup/glslang#472.
The text was updated successfully, but these errors were encountered: