input can not be qualified with invariant
Hi @alegal-arm ,
I met a test compile fail, as the shader mismatch with spec. ogl42 language spec says: Only variables output from a shader (including those that are then input to a subsequent shader) can be candidates for invariance. This includes user-defined output variables and the built-in output variables.
the shader generated in the shader as below. could you help check, thanks a lot. #version 420
in vec4 gs_fs_result; layout (location = 0) out vec4 fs_out_result;
highp in layout (location = 1) smooth invariant vec4 gs_fs_test; highp out layout (location = 1) invariant vec4 fs_out_test;
void main() { vec4 result = vec4(0, 1, 0, 1);
vec4 diff = gs_fs_test - vec4(0, 0, 1, 1);
if (false == all(lessThan(diff, vec4(0.001, 0.001, 0.001, 0.001))))
{
result = gs_fs_test;
}
else if (vec4(0, 1, 0, 1) != gs_fs_result)
{
result = vec4(1, 0, 0, 1);
}
fs_out_result = result;
fs_out_test = gs_fs_test;
}
the test item is KHR-GL45.shading_language_420pack.qualifier_order
best regards neo
@mnetsch has taken over this repo
This is something we are already investigating internally: https://gitlab.khronos.org/Tracker/vk-gl-cts/-/issues/3404
Hi @pdaniell-nv ,
sorry to trouble, but how is the conclusion
-neo
We concluded that the test has bugs and needs to be fixed, but so far me nor anyone else has had the bandwidth to fix it. It's not a trivial fix. Would you like to try fixing it? You can submit a PR to https://github.com/KhronosGroup/VK-GL-CTS/pulls. Basically doesStageSupportQualifier() needs to be improved to know both sides of the shader interface so it can write the correct qualifiers.
I'd like to, but not familiar the code logic, waiting for your fix