radv: Enable fast clears by default.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Mon, 6 Feb 2017 23:36:41 +0000 (00:36 +0100)
committerBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Tue, 7 Feb 2017 21:58:06 +0000 (22:58 +0100)
Works for me on dota2 and talos now.

Signed-off-by: Bas Nieuwenhuizen <basni@google.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Andres Rodriguez <andresx7@gmail.com>
src/amd/vulkan/radv_device.c
src/amd/vulkan/radv_meta_clear.c
src/amd/vulkan/radv_private.h

index 16c9c0ed68407366df69812969eebafca6d94580..98d4b91ac40219c0bfec18b600176d3def3045c8 100644 (file)
@@ -294,7 +294,7 @@ static const VkAllocationCallbacks default_alloc = {
 };
 
 static const struct debug_control radv_debug_options[] = {
-       {"fastclears", RADV_DEBUG_FAST_CLEARS},
+       {"nofastclears", RADV_DEBUG_NO_FAST_CLEARS},
        {"nodcc", RADV_DEBUG_NO_DCC},
        {"shaders", RADV_DEBUG_DUMP_SHADERS},
        {"nocache", RADV_DEBUG_NO_CACHE},
@@ -2157,7 +2157,7 @@ radv_initialise_color_surface(struct radv_device *device,
                        cb->cb_color_info |= S_028C70_COMPRESSION(1);
 
        if (iview->image->cmask.size &&
-           (device->debug_flags & RADV_DEBUG_FAST_CLEARS))
+           !(device->debug_flags & RADV_DEBUG_NO_FAST_CLEARS))
                cb->cb_color_info |= S_028C70_FAST_CLEAR(1);
 
        if (iview->image->surface.dcc_size && level_info->dcc_enabled)
index a42e8345716271204c26320fc1b78b7d6777e097..6d02acc2dd1614b4a1c01d0077227d9b73ab018c 100644 (file)
@@ -841,7 +841,7 @@ emit_fast_color_clear(struct radv_cmd_buffer *cmd_buffer,
        if (!iview->image->cmask.size && !iview->image->surface.dcc_size)
                return false;
 
-       if (!(cmd_buffer->device->debug_flags & RADV_DEBUG_FAST_CLEARS))
+       if (cmd_buffer->device->debug_flags & RADV_DEBUG_NO_FAST_CLEARS)
                return false;
 
        if (!radv_layout_can_fast_clear(iview->image, image_layout, radv_image_queue_family_mask(iview->image, cmd_buffer->queue_family_index, cmd_buffer->queue_family_index)))
index 69ff3578e3411f623fb00ac2c3723674ed18c69c..25ed5dec7cfa9e09e3ef674bb2435b4e4fa25bf9 100644 (file)
@@ -102,7 +102,7 @@ enum radv_mem_type {
 
 
 enum {
-       RADV_DEBUG_FAST_CLEARS       =   0x1,
+       RADV_DEBUG_NO_FAST_CLEARS    =   0x1,
        RADV_DEBUG_NO_DCC            =   0x2,
        RADV_DEBUG_DUMP_SHADERS      =   0x4,
        RADV_DEBUG_NO_CACHE          =   0x8,