From 2e8b1f6d1c82077c2744ef2009318ab056da6f49 Mon Sep 17 00:00:00 2001 From: Rohan Garg Date: Thu, 27 Apr 2023 16:45:39 +0200 Subject: [PATCH] anv: drop duplicate checks when setting the compressed bit We need compression tracking for full resolves and at the moment only CCS_E has full resolves. Signed-off-by: Rohan Garg Reviewed-by: Nanley Chery Part-of: --- src/intel/vulkan/genX_cmd_buffer.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/src/intel/vulkan/genX_cmd_buffer.c b/src/intel/vulkan/genX_cmd_buffer.c index 10c6c975ead..44441e1f30d 100644 --- a/src/intel/vulkan/genX_cmd_buffer.c +++ b/src/intel/vulkan/genX_cmd_buffer.c @@ -738,16 +738,6 @@ genX(cmd_buffer_mark_image_written)(struct anv_cmd_buffer *cmd_buffer, { /* The aspect must be exactly one of the image aspects. */ assert(util_bitcount(aspect) == 1 && (aspect & image->vk.aspects)); - - /* The only compression types with more than just fast-clears are MCS, - * CCS_E, and HiZ. With HiZ we just trust the layout and don't actually - * track the current fast-clear and compression state. This leaves us - * with just MCS and CCS_E. - */ - if (aux_usage != ISL_AUX_USAGE_CCS_E && - aux_usage != ISL_AUX_USAGE_MCS) - return; - set_image_compressed_bit(cmd_buffer, image, aspect, level, base_layer, layer_count, true); } @@ -1127,11 +1117,8 @@ transition_color_buffer(struct anv_cmd_buffer *cmd_buffer, aspect, level, base_layer, level_layer_count, ISL_AUX_OP_AMBIGUATE, NULL, false); - if (image->planes[plane].aux_usage == ISL_AUX_USAGE_CCS_E) { - set_image_compressed_bit(cmd_buffer, image, aspect, - level, base_layer, level_layer_count, - false); - } + set_image_compressed_bit(cmd_buffer, image, aspect, level, + base_layer, level_layer_count, false); } } else { /* If will_full_fast_clear is set, the caller promises to fast-clear