ARB_gl_spirv: per-member qualifiers on arrays of input/output blocks not supported
Right now in order to support per-member layout information (like flat, smooth, noperspective) on input/output blocks, spirv_to_nir does a split of the structure. So for example, the following:
out block {
flat float float_var;
smooth float smooth_var;
};
Is splitted on two NIR variables, each one with the layout data.
But right now arrays of input/outputs blocks are not being split. So the following:
out block {
flat float float_var;
smooth float smooth_var;
}ifc[2];
Is not being splitted.
The reason of not being split is that it makes a lot of other features, like xfb, geometry shaders built-in array of blocks, etc more complex. So the agreement was getting something sensible for everything else, and tackle this specific corner case later. Additionally, this issue would also affect Vulkan. It was not detected before because it seems that there isn't any vulkan test for this specific case.
On OpenGL we have just one test failing due this: tests/spec/glsl-1.50/execution/interface-block-interpolation-array.shader_test
when converted to spirv using the piglit script. This passes using GLSL because IR can handle this issue.