i965: Assert that blorp always handles color blits
authorIan Romanick <ian.d.romanick@intel.com>
Mon, 19 Jun 2017 18:10:38 +0000 (11:10 -0700)
committerMarge Bot <eric+marge@anholt.net>
Thu, 14 May 2020 15:35:43 +0000 (15:35 +0000)
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/856>

src/mesa/drivers/dri/i965/brw_blorp.c
src/mesa/drivers/dri/i965/intel_fbo.c

index 00c34f72cfda0d880287af5b965099d411cf813a..c2225b390fd3cf4a516c9b1eb6793afeb4b6183f 100644 (file)
@@ -831,6 +831,8 @@ brw_blorp_framebuffer(struct brw_context *brw,
       }
    }
 
+   /* try_blorp_blit should always be successful for color blits. */
+   assert(!(mask & GL_COLOR_BUFFER_BIT));
    return mask;
 }
 
index 9f8fee9879ce3371b0980d4b6307b50a3c471469..b1f24d4d1d379d5ab9c9d267b7ccd05462ce05ea 100644 (file)
@@ -929,6 +929,9 @@ intel_blit_framebuffer(struct gl_context *ctx,
    if (mask == 0x0)
       return;
 
+   /* brw_blorp_framebuffer should always be successful for color blits. */
+   assert(!(mask & GL_COLOR_BUFFER_BIT));
+
    mask = _mesa_meta_BlitFramebuffer(ctx, readFb, drawFb,
                                      srcX0, srcY0, srcX1, srcY1,
                                      dstX0, dstY0, dstX1, dstY1,