summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRohan Garg <rohan.garg@intel.com>2023-10-11 12:30:58 +0200
committerRohan Garg <rohan.garg@intel.com>2023-10-12 21:33:34 +0200
commit94ed71dad161edb01ee7acaae02e555af3e5dcac (patch)
tree6092c15c447a1881876a1ac860bc2c655cdbafac
parent24e51fa0ff5c2840b83ec4baf5cffc4d595c29c9 (diff)
anv: turn off non zero fast clears for CCS_Estaging/23.2
This helps fix a performance regression on games such as F1 22 and RDR2. Turning on non zero fast clears causes additional partial resolves for these games that degrades performance. Let's turn off non zero fast clears till we can elimiate the partial resolves. Signed-off-by: Rohan Garg <rohan.garg@intel.com> Reviewed-by: Nanley Chery <nanley.g.chery@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25655>
-rw-r--r--src/intel/vulkan/anv_image.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/intel/vulkan/anv_image.c b/src/intel/vulkan/anv_image.c
index 017cd6b84b2..697c74264e8 100644
--- a/src/intel/vulkan/anv_image.c
+++ b/src/intel/vulkan/anv_image.c
@@ -351,6 +351,15 @@ can_fast_clear_with_non_zero_color(const struct intel_device_info *devinfo,
if (image->planes[plane].aux_usage == ISL_AUX_USAGE_FCV_CCS_E)
return false;
+ /* Turning on non zero fast clears for CCS_E introduces a performance
+ * regression for games such as F1 22 and RDR2 by introducing additional
+ * partial resolves. Let's turn non zero fast clears back off till we can
+ * fix performance.
+ */
+ if (image->planes[plane].aux_usage == ISL_AUX_USAGE_CCS_E &&
+ devinfo->ver >= 12)
+ return false;
+
/* Non mutable image, we can fast clear with any color supported by HW.
*/
if (!(image->vk.create_flags & VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT))