This one is pretty straightforward. The setup:
1. VkPhysicalDeviceFeatures::sampleRateShading = VK_TRUE
2. VkPipelineMultisampleStateCreateInfo::sampleShadingEnable = VK_FALSE for the VkPipeline object
3. An image with sample count > 1 is attached to the draw call consuming the pipeline
With this setup, NAVI GPUs, both RX5000 and RX6000 series render garbage output. Specifically, only the edges are rendered, which seems like the usual multisample setup minus one sample - i.e inside polygons where we don't need multiple samples it renders 0 samples instead of at least 1, but for edges where we typically want N samples, it renders at least N-1 because sample count of 2 also shows this behavior. This issue has been present since RDNA1 launch. For NAVI, it seems VkPipelineMultisampleStateCreateInfo::sampleShadingEnable must always be VK_TRUE if VkPhysicalDeviceFeatures::sampleRateShading is VK_TRUE. I could not find any such constraint in the spec for the positive case, only for the negative case (i.e If the feature is disabled then the pipeline must also have it disabled). This feels like an undesirable result to me. Forcefully enabling sampleRateShading for all pipelines and calculating the minimum ratio works around this problem, but it still feels like a bug to me.
dit you try another GPU ?
does it work on nVidia Intel ?
doy you have any validation errora from Vulkan Validation layers ?
Could you provide a minimal sample case ? I guess @dorisyan could help you
Other GPUs are not affected. There is also no error from validation errors and looking at the spec there is no violation from this specific setup.
As for sample case, I can try and get something together in a few days if needed.
Hi @kd-11
You mean it works well on NV's platform, but only failed on AMD?
If so, Could you please provide a minimal demo to reproduce this problem? I will investigate it soon 🙂
Hello,
Indeed, all other platforms are unaffected. Sorry for the extremely late reply, some unavoidable circumstances sidelined me for a while and I forgot about my pending tickets.
AMD GCN and nvidia GPUs render correctly, but AMD RDNA does not. I've still not gotten my hands on a card that is impacted by this issue, but I will try and get a gfxreconstruct replay capture from one of our users for this purpose.