<div dir="ltr">Hi Samuel,<div><br></div><div>D16_UNORM support is mandatory on 2D images according to the spec ("Features, Limits and Formats" chapter).</div><div><br></div><div>Thanks,</div><div>Alex</div></div><div class="gmail_extra"><br><div class="gmail_quote">On 3 November 2017 at 10:02, Samuel Pitoiset <span dir="ltr"><<a href="mailto:samuel.pitoiset@gmail.com" target="_blank">samuel.pitoiset@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">TC compatible HTILE only supports D32_SFLOAT on VI, while GFX9<br>
supports both. This is a recommandation for apps because HTILE<br>
decompressions are costly.<br>
<br>
This improves performance with Talos (73->76FPS) and Serious<br>
Sam 2017 (119->134FPS) because they no longer use any 16bpp<br>
depth surfaces and thus no HTILE decompressions are needed.<br>
<br>
Mad Max and DOW3 are not affected, but F1 2017 still uses one<br>
16bpp depth surface even when the format is not advertised.<br>
<br>
Signed-off-by: Samuel Pitoiset <<a href="mailto:samuel.pitoiset@gmail.com">samuel.pitoiset@gmail.com</a>><br>
---<br>
src/amd/vulkan/radv_formats.c | 9 +++++++++<br>
1 file changed, 9 insertions(+)<br>
<br>
diff --git a/src/amd/vulkan/radv_formats.<wbr>c b/src/amd/vulkan/radv_formats.<wbr>c<br>
index 5c79ea7406..21a05c4bbd 100644<br>
--- a/src/amd/vulkan/radv_formats.<wbr>c<br>
+++ b/src/amd/vulkan/radv_formats.<wbr>c<br>
@@ -1122,6 +1122,15 @@ static VkResult radv_get_image_format_<wbr>properties(struct radv_physical_device *ph<br>
}<br>
}<br>
<br>
+ if (physical_device->rad_info.<wbr>chip_class == VI &&<br>
+ info->format == VK_FORMAT_D16_UNORM) {<br>
+ /* Do not advertise D16_UNORM on VI because TC compatible HTILE<br>
+ * only supports D32_SFLOAT (GFX9 supports both), and HTILE<br>
+ * decompressions are costly.<br>
+ */<br>
+ goto unsupported;<br>
+ }<br>
+<br>
*pImageFormatProperties = (VkImageFormatProperties) {<br>
.maxExtent = maxExtent,<br>
.maxMipLevels = maxMipLevels,<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.15.0<br>
<br>
______________________________<wbr>_________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div>