summaryrefslogtreecommitdiffstats
path: root/src/amd
diff options
context:
space:
mode:
authorBas Nieuwenhuizen <[email protected]>2018-01-03 21:58:49 +0100
committerBas Nieuwenhuizen <[email protected]>2018-01-04 00:14:03 +0100
commit5158603182fe7435bc825b09890d77eea49d2074 (patch)
tree19d7dd0447bf35a7567165966d61d8e3f5dc271c /src/amd
parent4f19cc82f9a6113a76a3bc7a848c98d0eb693991 (diff)
radv: Use correct HTILE expanded words.
Seems like users are actually hitting 0xFFFFFFFF actually making things broken for them, and the mad max regression is fixed, so lets put this in once more. v2: Use 0xf for depth-only htile. (Dave) Fixes: af2844116fd "radv: Revert HTILE reset word to 0xFFFFFFFF." Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/amd')
-rw-r--r--src/amd/vulkan/radv_cmd_buffer.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c
index 261344e939b..6dc80acef07 100644
--- a/src/amd/vulkan/radv_cmd_buffer.c
+++ b/src/amd/vulkan/radv_cmd_buffer.c
@@ -3781,7 +3781,8 @@ void radv_CmdEndRenderPass(
/*
* For HTILE we have the following interesting clear words:
- * 0x0000030f: Uncompressed.
+ * 0x0000030f: Uncompressed for depth+stencil HTILE.
+ * 0x0000000f: Uncompressed for depth only HTILE.
* 0xfffffff0: Clear depth to 1.0
* 0x00000000: Clear depth to 0.0
*/
@@ -3829,7 +3830,8 @@ static void radv_handle_depth_image_transition(struct radv_cmd_buffer *cmd_buffe
radv_initialize_htile(cmd_buffer, image, range, 0);
} else if (!radv_layout_is_htile_compressed(image, src_layout, src_queue_mask) &&
radv_layout_is_htile_compressed(image, dst_layout, dst_queue_mask)) {
- radv_initialize_htile(cmd_buffer, image, range, 0xffffffff);
+ uint32_t clear_value = vk_format_is_stencil(image->vk_format) ? 0x30f : 0xf;
+ radv_initialize_htile(cmd_buffer, image, range, clear_value);
} else if (radv_layout_is_htile_compressed(image, src_layout, src_queue_mask) &&
!radv_layout_is_htile_compressed(image, dst_layout, dst_queue_mask)) {
VkImageSubresourceRange local_range = *range;