[Piglit] [PATCH] framework/shader_test: Assume the api is GL if no requirements are found
Tom Gall
tom.gall at linaro.org
Wed Dec 12 08:35:26 PST 2012
Patch looks good. Will in the not too distant future want to consider
the gles2 case but that's a problem for a different day.
I performed a full test run and things look reasonable.
Reviewed-by: Tom Gall <tom.gall at linaro.org>
Tested-by: Tom Gall <tom.gall at linaro.org>
On Tue, Dec 11, 2012 at 6:24 PM, Chad Versace
<chad.versace at linux.intel.com> wrote:
> Commit 260f211 caused some shader tests to regress with the message:
> "Failed to find [require] block".
>
> This patch changes the python script that drives shader_runner to assume
> that the test's API is GL if no GL requirement is found in the test file.
> This behavior matches the behavior of the shader_runner executable, whose
> default requirements are GL >= 1.0 and GLSL >= 1.10.
>
> I tested this patch by running `piglit-run.py -t glsl -t shader` and then
> grepping the result file for "Failed to find".
>
> CC: Tom Gall <tom.gall at linaro.org>
> CC: Ian Romanick <idr at freedesktop.org>
> Reported-by: Ian Romanick <idr at freedesktop.org>
> Signed-off-by: Chad Versace <chad.versace at linux.intel.com>
> ---
> framework/shader_test.py | 14 +++++++-------
> 1 file changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/framework/shader_test.py b/framework/shader_test.py
> index a587f37..ea637cf 100755
> --- a/framework/shader_test.py
> +++ b/framework/shader_test.py
> @@ -196,13 +196,13 @@ class ShaderTest(PlainExecTest):
> else:
> assert(False)
>
> - # Failed to parse the GL requirement.
> - self.__gl_api = ShaderTest.API_ERROR
> -
> - if parse_state == PARSE_FIND_REQUIRE_HEADER:
> - self.__report_failure("Failed to find [require] block")
> - elif parse_state == PARSE_FIND_GL_REQUIREMENT:
> - self.__report_failure("Failed to find end of [require] block")
> + if parse_state == PARSE_FIND_REQUIRE_HEADER or \
> + parse_state == PARSE_FIND_GL_REQUIREMENT:
> + # If no requirements are found, then assume the required
> + # API is GL. This matches the behavior of the
> + # shader_runner executable, whose default requirements are
> + # GL >= 1.0 and GLSL >= 1.10.
> + self.__gl_api = ShaderTest.API_GL
> else:
> assert(False)
>
> --
> 1.7.11.7
>
--
Regards,
Tom
"Where's the kaboom!? There was supposed to be an earth-shattering
kaboom!" Marvin Martian
Graphics Working Group | Linaro.org │ Open source software for ARM SoCs
w) tom.gall att linaro.org
h) tom_gall att mac.com
More information about the Piglit
mailing list