Test "primitive-id-restart GL_TRIANGLE_STRIP_ADJACENCY other" is failed on the 18.2.0 mesa on Sandybridge: primitive-id-restart GL_TRIANGLE_STRIP_ADJACENCY other - fails showing following results: Expected primitive 1 to have gl_PrimitiveIDIn = 1, got 0 instead Expected primitive 2 to have gl_PrimitiveIDIn = 2, got 0 instead Expected primitive 3 to have gl_PrimitiveIDIn = 3, got 1 instead Expected primitive 4 to have gl_PrimitiveIDIn = 4, got 0 instead Expected primitive 5 to have gl_PrimitiveIDIn = 5, got 1 instead Expected primitive 6 to have gl_PrimitiveIDIn = 6, got 0 instead Expected primitive 7 to have gl_PrimitiveIDIn = 7, got 1 instead Expected primitive 8 to have gl_PrimitiveIDIn = 8, got 2 instead Expected primitive 9 to have gl_PrimitiveIDIn = 9, got 0 instead Expected primitive 10 to have gl_PrimitiveIDIn = 10, got 1 instead Expected primitive 11 to have gl_PrimitiveIDIn = 11, got 2 instead Expected primitive 12 to have gl_PrimitiveIDIn = 12, got 0 instead Expected primitive 13 to have gl_PrimitiveIDIn = 13, got 1 instead Expected primitive 14 to have gl_PrimitiveIDIn = 14, got 2 instead Expected primitive 15 to have gl_PrimitiveIDIn = 15, got 3 instead PIGLIT: {"result": "fail" } OS: Linux 4.15.0 Ubuntu x86_64
Looks like a hardware limitation. SNB doesn't support custom restart index in hardware so vbo_sw_primitive_restart is called. Thus we forced to issue separate draw after each restart which resets primitiveID counter and it always starts from zero. The test will fail with any primitive type and custom restart index.
We could fix that by uploading a primitive ID starting value via a vertex input (like we do for basevertex), and adding it in at run time in the shader... But I don't think that it's worth it, unless we have reports of this bug actually impacting an application...
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.