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: 32529e6084 ("r600/eg: rework atomic counter emission with flushes")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7417>
This commit is contained in:
Igor V. Kovalenko 2020-11-03 09:19:06 +03:00 committed by Marge Bot
parent 902b318213
commit 7ae81d65a4

View file

@ -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;