anv: Limit slow clear heuristic to ACM and prior

It hasn't been tuned for Xe2.

Fixes: 052d7e1a9c ("anv: Slow clear if fast-clear cost is not mitigated")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33035>
This commit is contained in:
Nanley Chery 2025-01-15 07:37:59 -05:00 committed by Marge Bot
parent caf007ff27
commit 15e23f3781

View file

@ -3515,7 +3515,14 @@ anv_can_fast_clear_color(const struct anv_cmd_buffer *cmd_buffer,
return false;
}
if (cmd_buffer->num_independent_clears >= 16 &&
/* The fast-clear preamble and/or postamble flushes are more expensive than
* the flushes performed by BLORP during slow clears. Use a heuristic to
* determine if the cost of the flushes are worth fast-clearing. See
* genX(cmd_buffer_update_color_aux_op)() and blorp_exec_on_render().
* TODO: Tune for Xe2
*/
if (cmd_buffer->device->info->verx10 <= 125 &&
cmd_buffer->num_independent_clears >= 16 &&
cmd_buffer->num_independent_clears >
cmd_buffer->num_dependent_clears * 2) {
anv_perf_warn(VK_LOG_OBJS(&image->vk.base),