nir/lower_system_values: Add shortcut for 1D workgroups to lower_cs_local_id_to_index
When the workgroup is 1 dimensional, simply use a vec3 filled with zeroes and the local invocation index. This results in better code than what lower_id_to_index would otherwise generate.
The motivation here is to make it more likely for src_is_local_invocation_index
in nir_gather_info
to recognize same-invocation output writes in mesh shaders. Apparently this wasn't happening without this patch.
Edited by Timur Kristóf