nir, spirv: Mesh Shader I/O fixes
Fixes for Mesh Shader I/O mainly around per-primitive outputs.
Quirks of the NVidia vendor-specific Mesh Shader extension:
- Primitive indices are currently treated as a flat array, and this is how both the ANV and RADV initial implementations work. It may be switched over to be a real per-primitive output later.
- Primitive count is a single unsigned integer output for the entire workgroup (both readable and writable by any invocation). Later we may move to a more D3D12 like semantic, for which we won't need this output and can use set_vertex_and_primitive_count instead.