Mesa (main): zink: assert precise queries are occlusion queries
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Aug 27 02:38:36 UTC 2021
Module: Mesa
Branch: main
Commit: 960e776f24cdd336b16d938448e5b5a4ffc1f781
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=960e776f24cdd336b16d938448e5b5a4ffc1f781
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Tue Aug 10 10:17:39 2021 -0400
zink: assert precise queries are occlusion queries
this should always be the case
Reviewed-by: Dave Airlie <airlied at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12583>
---
src/gallium/drivers/zink/zink_query.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/gallium/drivers/zink/zink_query.c b/src/gallium/drivers/zink/zink_query.c
index 4f1e9ddec37..8f9b1236dab 100644
--- a/src/gallium/drivers/zink/zink_query.c
+++ b/src/gallium/drivers/zink/zink_query.c
@@ -289,6 +289,8 @@ zink_create_query(struct pipe_context *pctx,
if (query->vkqtype == -1)
return NULL;
+ assert(!query->precise || query->vkqtype == VK_QUERY_TYPE_OCCLUSION);
+
query->curr_query = 0;
pool_create.sType = VK_STRUCTURE_TYPE_QUERY_POOL_CREATE_INFO;
More information about the mesa-commit
mailing list