Vulkan: Load/Store op of shading rate attachments


I'm currently testing the KHR shading rate extension and found a detail that may need some clearance:

Is the load/store op of the shading rate attachment irrelevant to the actual hardware process? I found the UE5 implementation just hard-coded DONT_CARE load/store ops for any shading rate attachments and if I understand this correctly they prepare their attachments in a separate compute pass prior to the main render pass:

From my own testing on an Immortalis G715 device declaring load/store ops as DONT_CARE does works as intended, no matter where the attachment data is generated. But AFAIK there is no relevant info in the Vulkan spec that specifies this is the case.


  • I don't think it matters, but similarly struggling to find any spec wording that explains what is expected here. 

    *EDIT* The spec wording for loadOp and storeOp in VkAttachmentDescription is explicitly defining the behavior only for color and depth. I would expect the implementation to ignore these fields for non-color and non-depth attachments, so I think using DONT_CARE is reasonable to avoid leaving undefined memory lying around.

    That said, the wording say "color format" not "color attachment", so I still think it's ambiguous ...