[Piglit] [PATCH] arb_shader_image_size: actually run in the relevant shader stage
Martin Peres
martin.peres at linux.intel.com
Fri Jul 1 14:12:00 UTC 2016
On 01/07/16 04:29, Ilia Mirkin wrote:
> Previously GL_FRAGMENT_SHADER was being hard-coded.
>
> Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
Hmm, thanks for catching this! The original version checked only on the
fragment shader, but when I got the exec time reasonable, I added the
stage and apparently stopped midway...
Reviewed-by: Martin Peres <martin.peres at linux.intel.com>
> ---
> tests/spec/arb_shader_image_size/builtin.c | 9 +++++----
> 1 file changed, 5 insertions(+), 4 deletions(-)
>
> diff --git a/tests/spec/arb_shader_image_size/builtin.c b/tests/spec/arb_shader_image_size/builtin.c
> index c8a7724..b728529 100755
> --- a/tests/spec/arb_shader_image_size/builtin.c
> +++ b/tests/spec/arb_shader_image_size/builtin.c
> @@ -133,16 +133,17 @@ check(const struct grid_info grid, struct image_info img_src)
> static bool
> run_test(const struct image_format_info *format,
> const struct image_target_info *target,
> + const struct image_stage_info *stage,
> const struct image_extent size)
> {
> - const struct grid_info grid = grid_info(GL_FRAGMENT_SHADER, GL_RGBA32I,
> + const struct grid_info grid = grid_info(stage->stage, GL_RGBA32I,
> 16, 16);
> const struct image_info img = {
> target, format, size,
> image_format_epsilon(grid.format)
> };
> GLuint prog = generate_program(
> - grid, GL_FRAGMENT_SHADER,
> + grid, stage->stage,
> concat(hunk("#extension GL_ARB_shader_image_size : enable\n"),
> image_hunk(img, ""),
> hunk("readonly IMAGE_UNIFORM_T src_img;\n"
> @@ -261,7 +262,7 @@ test_max_dimensions(const struct image_format_info *format,
> continue;
>
> subtest(status, true,
> - run_test(format, target, size),
> + run_test(format, target, stage, size),
> "%s/%s/image%s max size test/%dx%dx%dx%d",
> format->name, stage->name, target->name,
> size.x, size.y, size.z, size.w);
> @@ -285,7 +286,7 @@ test_small_dimensions(const struct image_format_info *format,
> return;
>
> subtest(status, true,
> - run_test(format, target, size),
> + run_test(format, target, stage, size),
> "%s/%s/image%s size test/%dx%dx%dx%d",
> format->name, stage->name, target->name,
> size.x, size.y, size.z, size.w);
>
More information about the Piglit
mailing list