i965: Disable fast clears when running with INTEL_DEBUG=nofc
authorCaio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Tue, 8 Oct 2019 00:15:26 +0000 (17:15 -0700)
committerCaio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Wed, 9 Oct 2019 20:29:26 +0000 (13:29 -0700)
Reviewed-by: Rafael Antognolli <rafael.antognolli@intel.com>
src/mesa/drivers/dri/i965/brw_blorp.c
src/mesa/drivers/dri/i965/brw_clear.c

index dc7862b407d659c2b50ab37d28660dbc8a74bb87..0cc7922e6e51b0d3aaa14335dd93be2ea32ec893 100644 (file)
@@ -1211,6 +1211,9 @@ do_single_blorp_clear(struct brw_context *brw, struct gl_framebuffer *fb,
 
    bool can_fast_clear = !partial_clear;
 
+   if (INTEL_DEBUG & DEBUG_NO_FAST_CLEAR)
+      can_fast_clear = false;
+
    bool color_write_disable[4] = { false, false, false, false };
    if (set_write_disables(irb, GET_COLORMASK(ctx->Color.ColorMask, buf),
                           color_write_disable))
index 1508171da1070d1da223376f778c7d9a41e9575a..85f27e717b099f9866c599838c3d4d94b9b5bcc6 100644 (file)
@@ -108,6 +108,9 @@ brw_fast_clear_depth(struct gl_context *ctx)
    struct gl_renderbuffer_attachment *depth_att = &fb->Attachment[BUFFER_DEPTH];
    const struct gen_device_info *devinfo = &brw->screen->devinfo;
 
+   if (INTEL_DEBUG & DEBUG_NO_FAST_CLEAR)
+      return false;
+
    if (devinfo->gen < 6)
       return false;