[Piglit] [PATCH] sso: fix issues in ValidateProgramPipeline

Tapani Pälli tapani.palli at intel.com
Mon Sep 14 02:18:18 PDT 2015



On 09/14/2015 11:39 AM, Ilia Mirkin wrote:
> On Mon, Sep 14, 2015 at 4:34 AM, Tapani Pälli <tapani.palli at intel.com> wrote:
>> When fixing some ES 3.1 conformance issues I noticed several subtests
>> started to fail. Patch fixes 2 issues in the test:
>>
>> - pipeline has to be bound for validation to return expected results
>> - validate_pipe needs to set global value 'pass' to true when validation
>>    passes.
>
> Why? Shouldn't pass be initialized to true once at the start, and then
> only ever set to false? That way if any subtest fails, the whole test
> is marked as failed. This is how most of these piglits work...

Because some of the failures throw errors (when expected to fail) and 
then "pass = piglit_check_gl_error(GL_NO_ERROR)" turns even passing 
cases as failed.

But yep, I see what you mean, it should fail if even once there was a 
failure. I'll dig a bit more to see if these errors are expected and why 
error is not cleared.


>>
>> This makes subtests to pass with planned Mesa changes.
>>
>> Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
>> ---
>>   tests/spec/arb_separate_shader_objects/ValidateProgramPipeline.c | 2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/tests/spec/arb_separate_shader_objects/ValidateProgramPipeline.c b/tests/spec/arb_separate_shader_objects/ValidateProgramPipeline.c
>> index a2741aa..5c9230ce 100644
>> --- a/tests/spec/arb_separate_shader_objects/ValidateProgramPipeline.c
>> +++ b/tests/spec/arb_separate_shader_objects/ValidateProgramPipeline.c
>> @@ -174,6 +174,7 @@ validate_pipe(GLuint pipe, bool expected, const char *test_name)
>>                  pass = false;
>>          } else {
>>                  piglit_report_subtest_result(PIGLIT_PASS, "%s", test_name);
>> +               pass = true;
>>          }
>>   }
>>
>> @@ -323,6 +324,7 @@ piglit_init(int argc, char **argv)
>>
>>          /* Create the pipeline */
>>          glGenProgramPipelines(1, &pipe);
>> +       glBindProgramPipeline(pipe);
>>
>>          build_and_validate_pipe(pipe, true,
>>                                  "VS/FS program, single glUseProgramStages "
>> --
>> 2.4.3
>>
>> _______________________________________________
>> Piglit mailing list
>> Piglit at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/piglit


More information about the Piglit mailing list