nir/lower_point_size_mov: zero nir_state_slot::swizzle in new variable

this is otherwise uninitialized during nir_serialize calls

Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11932>
This commit is contained in:
Mike Blumenkrantz 2021-07-16 16:27:49 -04:00 committed by Marge Bot
parent 1132df843c
commit 50f9519ea5
1 changed files with 1 additions and 0 deletions

View File

@ -47,6 +47,7 @@ lower_impl(nir_function_impl *impl,
glsl_float_type(), "gl_PointSizeClampedMESA");
in->num_state_slots = 1;
in->state_slots = ralloc_array(in, nir_state_slot, 1);
in->state_slots[0].swizzle = 0;
memcpy(in->state_slots[0].tokens,
pointsize_state_tokens,
sizeof(in->state_slots[0].tokens));