[Piglit] GL_ARB_explicit_attrib_location requirements

Ian Romanick idr at freedesktop.org
Tue Jul 8 18:14:56 PDT 2014

On 07/08/2014 08:54 AM, Brian Paul wrote:
> The spec for GL_ARB_explicit_attrib_location says it requires OpenGL 2.0
> or GL_ARB_vertex_shader and it's written against the OpenGL 3.2 core
> spec / GLSL 1.50.  The extension spec says nothing about how the
> extension would work in GLSL before 1.50.
> Note that this extension adds a new layout qualifier, but the "layout"
> keyword/qualifiers were only introduced in GLSL 1.40.
> nvidia's failing quite a few of the tests for this extension because
> they only support it in GLSL 1.50 and later.  Many of the tests pass w/
> nvidia's driver if I add "#version 150" to the top of the shaders.
> But other tests like
> tests/spec/arb_explicit_attrib_location/1.10/compiler/* seem bogus since
> they're adding "layout" and "out" language to GLSL 1.10 which seems like
> a stretch.

There was a Khronos bug about this, and my recollection is that's
exactly what was decided.  The spec does say that layout(location=) can
only be used with "in" and "out", and the implication was that the
extension had to add those in 1.10 and 1.20.

I recall NVIDIA saying that they would fix their driver, but I guess
that never happened...

I'll see if I can find a link to the Khronos bug and send it to you

> I think that there's 3 options here:
> 1. The spec for GL_ARB_explicit_attrib_location should clearly explain
> how things should work with GLSL 1.10, 1.20, 1.30.
> 2. Some of the piglit tests are invalid.
> 3. nvidia's driver is incorrect.
> I'm leaning toward option 2.
> Comments?
> -Brian

More information about the Piglit mailing list