[Mesa-dev] [PATCH 3/3] radv: always initialize DCC metadata to 0xFFFFFFFF

Samuel Pitoiset samuel.pitoiset at gmail.com
Wed Apr 11 12:09:17 UTC 2018


Not sure where the magic 0x20202020 value comes from but
it's used since a while. AMDVLK also always initializes to
0xFFFFFFFF.

When DCC for MSAA textures is enabled in my experimental
branch, this appears to fix some CTS tests.

No regressions on Polaris.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
---
 src/amd/vulkan/radv_cmd_buffer.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c
index f73526b5fc8..002e911a574 100644
--- a/src/amd/vulkan/radv_cmd_buffer.c
+++ b/src/amd/vulkan/radv_cmd_buffer.c
@@ -3807,9 +3807,7 @@ static void radv_handle_dcc_image_transition(struct radv_cmd_buffer *cmd_buffer,
 	if (src_layout == VK_IMAGE_LAYOUT_PREINITIALIZED) {
 		radv_initialize_dcc(cmd_buffer, image, 0xffffffffu);
 	} else if (src_layout == VK_IMAGE_LAYOUT_UNDEFINED) {
-		radv_initialize_dcc(cmd_buffer, image,
-		                    radv_layout_dcc_compressed(image, dst_layout, dst_queue_mask) ?
-		                         0x20202020u : 0xffffffffu);
+		radv_initialize_dcc(cmd_buffer, image, 0xffffffffu);
 	} else if (radv_layout_dcc_compressed(image, src_layout, src_queue_mask) &&
 	           !radv_layout_dcc_compressed(image, dst_layout, dst_queue_mask)) {
 		radv_decompress_dcc(cmd_buffer, image, range);
-- 
2.17.0



More information about the mesa-dev mailing list