summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/intel/vulkan/anv_blorp.c6
-rw-r--r--src/intel/vulkan/anv_image.c6
2 files changed, 12 insertions, 0 deletions
diff --git a/src/intel/vulkan/anv_blorp.c b/src/intel/vulkan/anv_blorp.c
index c5833001f48..8553327626a 100644
--- a/src/intel/vulkan/anv_blorp.c
+++ b/src/intel/vulkan/anv_blorp.c
@@ -1148,6 +1148,9 @@ can_fast_clear_color_att(struct anv_cmd_buffer *cmd_buffer,
const VkClearAttachment *attachment,
uint32_t rectCount, const VkClearRect *pRects)
{
+ if (INTEL_DEBUG(DEBUG_NO_FAST_CLEAR))
+ return false;
+
/* We don't support fast clearing with conditional rendering at the
* moment. All the tracking done around fast clears (clear color updates
* and fast-clear type updates) happens unconditionally.
@@ -1696,6 +1699,9 @@ can_hiz_clear_att(struct anv_cmd_buffer *cmd_buffer,
const VkClearAttachment *attachment,
uint32_t rectCount, const VkClearRect *pRects)
{
+ if (INTEL_DEBUG(DEBUG_NO_FAST_CLEAR))
+ return false;
+
/* From Bspec's section MI_PREDICATE:
*
* "The MI_PREDICATE command is used to control the Predicate state bit,
diff --git a/src/intel/vulkan/anv_image.c b/src/intel/vulkan/anv_image.c
index c7ba03cf5fd..a4f9a31063d 100644
--- a/src/intel/vulkan/anv_image.c
+++ b/src/intel/vulkan/anv_image.c
@@ -2608,6 +2608,9 @@ anv_can_hiz_clear_ds_view(struct anv_device *device,
float depth_clear_value,
VkRect2D render_area)
{
+ if (INTEL_DEBUG(DEBUG_NO_FAST_CLEAR))
+ return false;
+
/* If we're just clearing stencil, we can always HiZ clear */
if (!(clear_aspects & VK_IMAGE_ASPECT_DEPTH_BIT))
return true;
@@ -2668,6 +2671,9 @@ anv_can_fast_clear_color_view(struct anv_device *device,
uint32_t num_layers,
VkRect2D render_area)
{
+ if (INTEL_DEBUG(DEBUG_NO_FAST_CLEAR))
+ return false;
+
if (iview->planes[0].isl.base_array_layer >=
anv_image_aux_layers(iview->image, VK_IMAGE_ASPECT_COLOR_BIT,
iview->planes[0].isl.base_level))