Mesa (main): panfrost: Don't set dirty_mask for constant buffers

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Sat Jul 3 13:36:07 UTC 2021


Module: Mesa
Branch: main
Commit: d0e90c336db7d4d0c2bed15e927ed401956b49e3
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=d0e90c336db7d4d0c2bed15e927ed401956b49e3

Author: Icecream95 <ixn at disroot.org>
Date:   Sat Jul  3 19:52:21 2021 +1200

panfrost: Don't set dirty_mask for constant buffers

It is unused.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11700>

---

 src/gallium/drivers/panfrost/pan_cmdstream.c | 2 --
 src/gallium/drivers/panfrost/pan_context.c   | 2 --
 src/gallium/drivers/panfrost/pan_context.h   | 1 -
 3 files changed, 5 deletions(-)

diff --git a/src/gallium/drivers/panfrost/pan_cmdstream.c b/src/gallium/drivers/panfrost/pan_cmdstream.c
index 51ce6ff91c8..e5af9959985 100644
--- a/src/gallium/drivers/panfrost/pan_cmdstream.c
+++ b/src/gallium/drivers/panfrost/pan_cmdstream.c
@@ -1242,8 +1242,6 @@ panfrost_emit_const_buf(struct panfrost_batch *batch,
                 }
         }
 
-        buf->dirty_mask = 0;
-
         if (ss->info.push.count == 0)
                 return ubos.gpu;
 
diff --git a/src/gallium/drivers/panfrost/pan_context.c b/src/gallium/drivers/panfrost/pan_context.c
index 33993cb8212..def311a0c77 100644
--- a/src/gallium/drivers/panfrost/pan_context.c
+++ b/src/gallium/drivers/panfrost/pan_context.c
@@ -1282,12 +1282,10 @@ panfrost_set_constant_buffer(
 
         if (unlikely(!buf)) {
                 pbuf->enabled_mask &= ~mask;
-                pbuf->dirty_mask &= ~mask;
                 return;
         }
 
         pbuf->enabled_mask |= mask;
-        pbuf->dirty_mask |= mask;
         ctx->dirty_shader[shader] |= PAN_DIRTY_STAGE_CONST;
 }
 
diff --git a/src/gallium/drivers/panfrost/pan_context.h b/src/gallium/drivers/panfrost/pan_context.h
index dcc970db984..c5b0f271f2e 100644
--- a/src/gallium/drivers/panfrost/pan_context.h
+++ b/src/gallium/drivers/panfrost/pan_context.h
@@ -83,7 +83,6 @@ enum pan_dirty_shader {
 struct panfrost_constant_buffer {
         struct pipe_constant_buffer cb[PIPE_MAX_CONSTANT_BUFFERS];
         uint32_t enabled_mask;
-        uint32_t dirty_mask;
 };
 
 struct panfrost_query {



More information about the mesa-commit mailing list