cancel
Showing results for 
Search instead for 
Did you mean: 

OpenGL & Vulkan

kd-11
Adept II
Adept II

MSAA with sample shading disabled does not work on NAVI when using Vulkan

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.

 

 

0 Kudos
Reply
3 Replies
Andrey2007AMD
Adept III
Adept III

Re: MSAA with sample shading disabled does not work on NAVI when using Vulkan

@kd-11 

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

Tags (2)
0 Kudos
Reply
kd-11
Adept II
Adept II

Re: MSAA with sample shading disabled does not work on NAVI when using Vulkan

@Andrey2007AMD 

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.

0 Kudos
Reply
dorisyan
Staff
Staff

Re: MSAA with sample shading disabled does not work on NAVI when using Vulkan

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 :)