mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-27 04:00:10 +01:00
zink: skip readback of qbos with no results
this is a no-op and also crashes
Fixes: 93190be1b9 ("zink: rewrite query internals")
Reviewed-by: Hoe Hao Cheng <haochengho12907@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14397>
This commit is contained in:
parent
f8d2770737
commit
b7a4faea9b
1 changed files with 2 additions and 0 deletions
|
|
@ -459,6 +459,8 @@ get_query_result(struct pipe_context *pctx,
|
|||
uint64_t *xfb_results = NULL;
|
||||
uint64_t *results;
|
||||
bool is_timestamp = query->type == PIPE_QUERY_TIMESTAMP || query->type == PIPE_QUERY_TIMESTAMP_DISJOINT;
|
||||
if (!qbo->num_results)
|
||||
continue;
|
||||
results = pipe_buffer_map_range(pctx, qbo->buffer, 0,
|
||||
(is_timestamp ? 1 : qbo->num_results) * result_size, flags, &xfer);
|
||||
if (!results) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue