Mesa (master): r600: amend space check for chips older than EVERGREEN
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Tue Nov 3 21:33:35 UTC 2020
Module: Mesa
Branch: master
Commit: 7ae81d65a495a6ba6da6dda6bcbd91a30cc2a8dc
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=7ae81d65a495a6ba6da6dda6bcbd91a30cc2a8dc
Author: Igor V. Kovalenko <igor.v.kovalenko at gmail.com>
Date: Tue Nov 3 09:19:06 2020 +0300
r600: amend space check for chips older than EVERGREEN
evergreen_emit_atomic_buffer_setup_count is only called if chip >= EVERGREEN
otherwise atomic_used_mask is left uninitialized when unconditionally used by
r600_need_cs_space so it might want more space than needed
fix this by always initializing atomic_used_mask
Fixes: 32529e60849 ("r600/eg: rework atomic counter emission with flushes")
Reviewed-by: Dave Airlie <airlied at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7417>
---
src/gallium/drivers/r600/r600_state_common.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gallium/drivers/r600/r600_state_common.c b/src/gallium/drivers/r600/r600_state_common.c
index eae6ca1ac2b..32cc7441ff1 100644
--- a/src/gallium/drivers/r600/r600_state_common.c
+++ b/src/gallium/drivers/r600/r600_state_common.c
@@ -2064,7 +2064,7 @@ static void r600_draw_vbo(struct pipe_context *ctx, const struct pipe_draw_info
unsigned index_size = info->index_size;
int index_bias;
struct r600_shader_atomic combined_atomics[8];
- uint8_t atomic_used_mask;
+ uint8_t atomic_used_mask = 0;
if (!info->indirect && !info->count && (index_size || !info->count_from_stream_output)) {
return;
More information about the mesa-commit
mailing list