NVIDIA Update Breaks Shader

Greetings!

I recently updated my NVIDIA GeForce driver to version 364.72, and a shader program that worked perfectly fine before does not seem to compile anymore. I haven’t changed a thing to the script itself after the update, however now I get the following error:

error: Type mismatch between variable "i_Color" matched by location "1"

The vertex shader has a variable ‘out vec4 o_Data1’ bound to location 1, while the fragment shader has a variable ‘in vec4 i_Color’ bound there as well. I’ll post my shaders below, but as you’ll see, they’re quite straightforward. I’m using it for font rendering from a single texture, allowing the font to change color in the fragment shader. I’m not sure what could possibly be going wrong. I’ve got other programs with a similar structure, that still work after the update. Note that these scripts were code-generated. That’s why I use layout location on all of my data, it made the scripts much easier to mix and match.

My vertex shader:

#version 450 core
 
layout(location = 0)
uniform mat4 u_Matrix;
 
layout(location = 0)
in vec4 i_Vertex;
 
layout(location = 3)
in mat4 i_Matrix;
 
layout(location = 2)
in vec4 i_Data1;
 
layout(location = 1)
out vec4 o_Data1;
 
layout(location = 1)
in vec2 i_Data0;
 
layout(location = 0)
out vec2 o_Data0;
 
void main()
{
    o_Data1 = i_Data1;
    o_Data0 = i_Data0;
 
    gl_Position = u_Matrix * i_Matrix * vec4(i_Vertex.x + 0.0, i_Vertex.y - 0.0, i_Vertex.z, 1.0);
}

My fragment shader:

#version 450 core
 
layout(location = 1)
uniform sampler2D u_Texture;
 
layout(location = 1)
in vec4 i_Color;
 
layout(location = 0)
in vec2 i_Coord;
 
out vec4 o_Color;
 
void main()
{
    o_Color = texelFetch(u_Texture, ivec2(i_Coord), 0);
    if(o_Color.a > 0.0)
    {
        o_Color.rgb = i_Color.rgb * (1.0 - o_Color.rgb);
    }
 
    if(o_Color.a == 0.0)
    {
        discard;
    }
}

Does anyone have an idea what’s going wrong here? Thanks in advance!

This issue ‘sort of’ got fixed, so I’m posting a solution here in case anyone else runs into this problem. It would seem there is an issue with how the driver is handling its interfaces. Once I changed the vec2 into a vec4, both the ‘out o_Data0’ in the vertex shader, and ‘in i_Coord’ in the fragment shader, the problem was fixed. Ofcourse I had to add two additional zeros in the vertex shader to fill the vec4. This seems to be a bug with the driver, so I’ll see if I can file a bug report. Props to Kai from the LWJGL forums for helping with this issue.

Following the bug report I got a message saying I should wait for a response on this forum post. If at all possible, I’d love to hear more about if or when this issue could get fixed, so I can make a ticket for our own project task list. If I haven’t provided enough information I’ll be happy to do so. Thanks in advance

Just want to mention that I am seeing the same problem after upgrading to a newer driver (linux 364.19). I would also like to see that fixed.