Bug 94485 - dEQP-GLES3.functional.negative_api.shader.compile_shader and delete_shader broken by Meta
Summary: dEQP-GLES3.functional.negative_api.shader.compile_shader and delete_shader br...
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: Kenneth Graunke
QA Contact: Intel 3D Bugs Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: i965-deqp
  Show dependency treegraph
 
Reported: 2016-03-11 00:35 UTC by Kenneth Graunke
Modified: 2019-03-14 08:40 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Kenneth Graunke 2016-03-11 00:35:00 UTC
Running the following case list:
dEQP-GLES3.functional.negative_api.buffer.clear
dEQP-GLES3.functional.negative_api.shader.compile_shader
dEQP-GLES3.functional.negative_api.shader.delete_shader

causes compile_shader and delete_shader to fail.  The problem is that buffer.clear produces Meta shaders, and compile_shader/delete_shader see those.  We correctly identify them as internal shaders, but always return INVALID_OPERATION, while the test expects INVALID_OPERATION or INVALID_ENUM.
Comment 1 Kenneth Graunke 2016-03-11 01:21:42 UTC
Actually, the problem is that compile_shader's first subtest assumes that no shaders exist, i.e.

glCompileShader(9)

should return GL_INVALID_VALUE because 9 simply does not exist.

But because of Meta, it does exist - and the real bug is that applications can observe and even alter these shaders.  In the dEQP test sequence, it happens to be a gl_shader_program, so we return GL_INVALID_OPERATION.  But it could be a shader, at which point we would return it.
Comment 2 Kenneth Graunke 2016-03-16 01:34:23 UTC
I have patches to fix this.
Comment 3 Kenneth Graunke 2016-03-17 07:09:30 UTC
commit 9c1e01c4a883ac4a738f6f8c17c0236621101e28
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Tue Mar 15 10:51:55 2016 -0700

    meta: Don't use integer handles for shaders or programs.

and the previous patches.


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.