Module: Mesa
Branch: master
Commit: 32dd75b927956a60c285844251c3c7be56c6e651
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=32dd75b927956a60c285844251c3c7be56c6e651

Author: Rob Clark <[email protected]>
Date:   Sat Oct 27 14:20:22 2018 -0400

freedreno: dependency tracking for z/s depends on ZSA state

ZSA state can change whether depth or stencil is enabled

This plus previous patch fix stk, and various things w/
FD_MESA_DEBUG=inorder

Fixes: ec717fc629 freedreno: reduce resource dependency tracking overhead
Signed-off-by: Rob Clark <[email protected]>

---

 src/gallium/drivers/freedreno/freedreno_draw.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/gallium/drivers/freedreno/freedreno_draw.c 
b/src/gallium/drivers/freedreno/freedreno_draw.c
index 2b5119e6f9..90d0e44036 100644
--- a/src/gallium/drivers/freedreno/freedreno_draw.c
+++ b/src/gallium/drivers/freedreno/freedreno_draw.c
@@ -137,7 +137,7 @@ fd_draw_vbo(struct pipe_context *pctx, const struct 
pipe_draw_info *info)
 
        mtx_lock(&ctx->screen->lock);
 
-       if (ctx->dirty & FD_DIRTY_FRAMEBUFFER) {
+       if (ctx->dirty & (FD_DIRTY_FRAMEBUFFER | FD_DIRTY_ZSA)) {
                if (fd_depth_enabled(ctx)) {
                        if (fd_resource(pfb->zsbuf->texture)->valid) {
                                restore_buffers |= FD_BUFFER_DEPTH;
@@ -159,7 +159,9 @@ fd_draw_vbo(struct pipe_context *pctx, const struct 
pipe_draw_info *info)
                        resource_written(batch, pfb->zsbuf->texture);
                        batch->gmem_reason |= FD_GMEM_STENCIL_ENABLED;
                }
+       }
 
+       if (ctx->dirty & FD_DIRTY_FRAMEBUFFER) {
                for (i = 0; i < pfb->nr_cbufs; i++) {
                        if (!pfb->cbufs[i])
                                continue;

_______________________________________________
mesa-commit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to