[Piglit] [PATCH 33/50] arb_occlusion_query2: set KHR_no_error status

Samuel Pitoiset samuel.pitoiset at gmail.com
Mon Aug 21 12:29:18 UTC 2017



On 08/21/2017 09:38 AM, Timothy Arceri wrote:
> 
> 
> On 11/08/17 01:22, Samuel Pitoiset wrote:
>> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
>> ---
>>   tests/spec/arb_occlusion_query2/api.c    | 34 
>> +++++++++++++++++++++-----------
>>   tests/spec/arb_occlusion_query2/render.c |  1 +
>>   2 files changed, 24 insertions(+), 11 deletions(-)
>>
>> diff --git a/tests/spec/arb_occlusion_query2/api.c 
>> b/tests/spec/arb_occlusion_query2/api.c
>> index 429b6b3f8..2ba6877a3 100644
>> --- a/tests/spec/arb_occlusion_query2/api.c
>> +++ b/tests/spec/arb_occlusion_query2/api.c
>> @@ -35,6 +35,7 @@ PIGLIT_GL_TEST_CONFIG_BEGIN
>>       config.window_visual = (PIGLIT_GL_VISUAL_RGB |
>>                   PIGLIT_GL_VISUAL_DOUBLE |
>>                   PIGLIT_GL_VISUAL_DEPTH);
>> +    config.khr_no_error_support = PIGLIT_NO_ERRORS;
>>   PIGLIT_GL_TEST_CONFIG_END
>> @@ -52,10 +53,14 @@ test_error_begin_while_other_active(void)
>>       glBeginQuery(GL_SAMPLES_PASSED, oq[0]);
>>       if (!piglit_check_gl_error(0))
>>           pass = false;
>> -    glBeginQuery(GL_ANY_SAMPLES_PASSED, oq[1]);
>> -    if (!piglit_check_gl_error(GL_INVALID_OPERATION))
>> -        pass = false;
>> -    glEndQuery(GL_ANY_SAMPLES_PASSED);
>> +
>> +    if (!piglit_khr_no_error) {
>> +        glBeginQuery(GL_ANY_SAMPLES_PASSED, oq[1]);
>> +        if (!piglit_check_gl_error(GL_INVALID_OPERATION))
>> +            pass = false;
>> +        glEndQuery(GL_ANY_SAMPLES_PASSED);
>> +    }
>> +
> 
> You can drop this change.
> 
>>       glEndQuery(GL_SAMPLES_PASSED);
>>       piglit_reset_gl_error();
>> @@ -66,10 +71,14 @@ test_error_begin_while_other_active(void)
>>       glBeginQuery(GL_ANY_SAMPLES_PASSED, oq[0]);
>>       if (!piglit_check_gl_error(0))
>>           pass = false;
>> -    glBeginQuery(GL_SAMPLES_PASSED, oq[1]);
>> -    if (!piglit_check_gl_error(GL_INVALID_OPERATION))
>> -        pass = false;
>> -    glEndQuery(GL_SAMPLES_PASSED);
>> +
>> +    if (!piglit_khr_no_error) {
>> +        glBeginQuery(GL_SAMPLES_PASSED, oq[1]);
>> +        if (!piglit_check_gl_error(GL_INVALID_OPERATION))
>> +            pass = false;
>> +        glEndQuery(GL_SAMPLES_PASSED);
>> +    }
>> +
> 
> And this change.
> 
>>       glEndQuery(GL_ANY_SAMPLES_PASSED);
>>       piglit_reset_gl_error();
>> @@ -269,9 +278,12 @@ piglit_display(void)
>>       pass = test_counter_bits() && pass;
>>       pass = test_current_query() && pass;
>> -    pass = test_error_begin_wrong_target() && pass;
>> -    pass = test_error_end_wrong_target() && pass;
>> -    pass = test_error_begin_while_other_active() && pass;
>> +
>> +    if (!piglit_khr_no_error) {
>> +        pass = test_error_begin_wrong_target() && pass;
>> +        pass = test_error_end_wrong_target() && pass;
>> +        pass = test_error_begin_while_other_active() && pass;
> 
> Because you are skipping calling the function here.
> 
> With that change:
> 
> Reviewed-by: Timothy Arceri <tarceri at itsqueeze.com>

Right, fixed locally.

Thanks!

> 
>> +    }
>>       piglit_report_result(pass ? PIGLIT_PASS : PIGLIT_FAIL);
>> diff --git a/tests/spec/arb_occlusion_query2/render.c 
>> b/tests/spec/arb_occlusion_query2/render.c
>> index 2d593fbfe..14eabdd44 100644
>> --- a/tests/spec/arb_occlusion_query2/render.c
>> +++ b/tests/spec/arb_occlusion_query2/render.c
>> @@ -33,6 +33,7 @@ PIGLIT_GL_TEST_CONFIG_BEGIN
>>       config.supports_gl_compat_version = 10;
>>       config.window_visual = PIGLIT_GL_VISUAL_RGB | 
>> PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH;
>> +    config.khr_no_error_support = PIGLIT_NO_ERRORS;
>>   PIGLIT_GL_TEST_CONFIG_END
>>


More information about the Piglit mailing list