[Piglit] [PATCH 07/12] glx_arb_create_context: Verify that the invalid attributes are rejected
Chad Versace
chad.versace at linux.intel.com
Tue Dec 20 12:06:10 PST 2011
On 12/14/2011 10:47 AM, Ian Romanick wrote:
> From: Ian Romanick <ian.d.romanick at intel.com>
>
> NVIDIA's closed-source driver fails this test because it generates the
> wrong X error (BadMatch instead of BadValue). It correctly does not
> create the context.
>
> AMD's closed-source driver fails this test becuase it creates contexts
> with invalid attributes.
>
> Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
> ---
> tests/all.tests | 1 +
> .../spec/glx_arb_create_context/CMakeLists.gl.txt | 1 +
> .../glx_arb_create_context/invalid-attribute.c | 87 ++++++++++++++++++++
> 3 files changed, 89 insertions(+), 0 deletions(-)
> create mode 100644 tests/spec/glx_arb_create_context/invalid-attribute.c
>
I think that the probing for GLX_CONTEXT_PROFILE_MASK_ARB needs to be more thorough and
check that bits {(1<<n)|n=3..31} are invalid.
Perhaps change the signature of try_attribute() to try_attribute(int attr, int value) and
loop over those invalid bits?
----
Chad Versace
chad.versace at linux.intel.com
More information about the Piglit
mailing list