-
Notifications
You must be signed in to change notification settings - Fork 260
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
Convention and intent for grammar for aliases. (Was: Possibly wrong extensions
and version
for the aliased operands?)
#109
Comments
We've agreed to evolve this so that:
There was some tooling that wasn't quite ready for this yet, so the JSON file is not yet sanitized in this way. |
extensions
and version
for the aliased operands?extensions
and version
for the aliased operands?)
So, taking the examples above and modify them to follow the new rules. The decorate string ones would only omit fields in aliases, without changes:
And the HLSL related ones:
Is that correct? If so, why not just add a "aliases" field in the main opcode, and have a single entry per opcode? Room for adding more per-alias data? |
My understanding is there are still some consumers that want both sets of complete information. I like the idea of adding an aliases field. These questions need to be answered both for instruction enumerants and for non-instruction enumerants, which generally are treated a bit differently. We need to evolve this while keeping the spec., SPIRV-Tools, and likely other consumers in mind. (It seems you just cared about the instructions(?), as this style of aliasing has been present for some time in other enumerants; it was not novel, it was following the precedent already set.) |
I agree it's a good direction to ensure consistency for each token. We haven't implemented the update to SPIRV-Tools to understand the new form. I filed an issue (see above) to do that. |
Also see #108 for any loose ends in documentation. |
So this "the first item is the truth" isn't followed here {
"opname" : "OpTypeAccelerationStructureNV",
"class" : "Reserved",
"opcode" : 5341,
"operands" : [
{ "kind" : "IdResult" }
],
"capabilities" : [ "RayTracingNV" , "RayTracingKHR", "RayQueryKHR" ],
"extensions" : [ "SPV_NV_ray_tracing" , "SPV_KHR_ray_tracing", "SPV_KHR_ray_query" ],
"version" : "None"
},
{
"opname" : "OpTypeAccelerationStructureKHR",
"class" : "Reserved",
"opcode" : 5341,
"operands" : [
{ "kind" : "IdResult" }
],
"capabilities" : [ "RayTracingNV" , "RayTracingKHR", "RayQueryKHR" ],
"extensions" : [ "SPV_NV_ray_tracing" , "SPV_KHR_ray_tracing", "SPV_KHR_ray_query" ],
"version" : "None"
}, I guess personally, instead of worrying about ordering, I would also prefer something like a (cc @bashbaug ) |
Should GOOGLE aliases be tagged with 1.4? (I'm guessing no)
Should the non-GOOGLE variants have empty "extensions" field? (I'm guessing yes)
I'd expect decorate string and hlsl-related annotations to follow the same convention, but they disagree in both questions.
Decorate string (with params omitted):
Hlsl-related annotations (with params omitted):
The text was updated successfully, but these errors were encountered: