[Mesa-dev] [PATCH 1/7] st/mesa: flush bitmap cache before compute dispatch

Nicolai Hähnle nhaehnle at gmail.com
Wed Jun 15 08:38:30 UTC 2016


From: Nicolai Hähnle <nicolai.haehnle at amd.com>

In the unlikely case that a program uses glBitmap to render to a framebuffer
whose texture is bound in a compute shader.

Found by inspection.

Cc: 11.2 12.0 <mesa-stable at lists.freedesktop.org>
---
 src/mesa/state_tracker/st_cb_compute.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/mesa/state_tracker/st_cb_compute.c b/src/mesa/state_tracker/st_cb_compute.c
index bfc6d96..063d750 100644
--- a/src/mesa/state_tracker/st_cb_compute.c
+++ b/src/mesa/state_tracker/st_cb_compute.c
@@ -28,6 +28,7 @@
 #include "main/state.h"
 #include "st_atom.h"
 #include "st_context.h"
+#include "st_cb_bitmap.h"
 #include "st_cb_bufferobjects.h"
 #include "st_cb_compute.h"
 
@@ -44,6 +45,8 @@ static void st_dispatch_compute_common(struct gl_context *ctx,
    struct pipe_context *pipe = st->pipe;
    struct pipe_grid_info info = { 0 };
 
+   st_flush_bitmap_cache(st);
+
    if (ctx->NewState)
       _mesa_update_state(ctx);
 
-- 
2.7.4



More information about the mesa-dev mailing list