nir/lower_subgroups: Pad ballot values before bitcasting
authorJason Ekstrand <jason@jlekstrand.net>
Thu, 8 Jul 2021 19:36:15 +0000 (14:36 -0500)
committerMarge Bot <eric+marge@anholt.net>
Fri, 9 Jul 2021 14:21:26 +0000 (14:21 +0000)
commita195ef123ea31ea89a0994d95b5c1f20462bfb6f
tree9313394d6efcc27c7c562948edf4ddb8cd2a7d89
parent439322ad4c03b135bb2570b3bbdfd7fa5fc8a06d
nir/lower_subgroups: Pad ballot values before bitcasting

Otherwise, if we cast from a uint32_t to a uint64_t, the bitcast will
fail before we pad.  This happens on Intel.

Fixes: e4e79de2a420 "nir/subgroups: Support > 1 ballot components"
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5045
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11786>
src/compiler/nir/nir_lower_subgroups.c