Mesa (main): llvmpipe: disable compute statistics queries if queries are disabled

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue May 3 13:17:51 UTC 2022


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

Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date:   Mon May  2 11:15:40 2022 -0400

llvmpipe: disable compute statistics queries if queries are disabled

cc: mesa-stable

Reviewed-by: Emma Anholt <emma at anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16278>

---

 src/gallium/drivers/llvmpipe/lp_state_cs.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/gallium/drivers/llvmpipe/lp_state_cs.c b/src/gallium/drivers/llvmpipe/lp_state_cs.c
index 230004d799f..01ff10deb8a 100644
--- a/src/gallium/drivers/llvmpipe/lp_state_cs.c
+++ b/src/gallium/drivers/llvmpipe/lp_state_cs.c
@@ -1419,7 +1419,8 @@ static void llvmpipe_launch_grid(struct pipe_context *pipe,
 
       lp_cs_tpool_wait_for_task(screen->cs_tpool, &task);
    }
-   llvmpipe->pipeline_statistics.cs_invocations += num_tasks * info->block[0] * info->block[1] * info->block[2];
+   if (!llvmpipe->queries_disabled)
+      llvmpipe->pipeline_statistics.cs_invocations += num_tasks * info->block[0] * info->block[1] * info->block[2];
 }
 
 static void



More information about the mesa-commit mailing list