-
Notifications
You must be signed in to change notification settings - Fork 54
Description
Which proposal does this relate to?
https://github.com/microsoft/hlsl-specs/blob/main/proposals/0049-variable-groupshared-memory.md
Describe the issue or outstanding question.
When reviewing the implementation PR microsoft/DirectXShaderCompiler#7871, I realized there may be a bit of an issue with the design.
Libraries already went in the direction of reporting groupshared memory usage by entry point in the RDAT shader info structure (with GroupSharedBytesUsed). This seems like a better way to report groupshared usage for a compiled shader than the limit value specified in the attribute. The attribute is still useful for limiting the groupshared memory to the specified maximum to remain within a capability target, but after a shader is compiled, the computed maximum groupshared memory used by a shader seems like the value that should be placed in PSV0 or RDAT for runtime checks against the device capability.
As the design already fails to address the RDAT/library side (required for node shaders), and RDAT already contains this usage value, it would make more sense to add the corresponding usage value to PSV0 instead of the maximum. The maximum would remain in DXIL metadata (and DxilFunctionProps) though, since that's still needed for checking that the calculated usage doesn't exceed this expected maximum.
Additional context
See comment on PR.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Status