[Mesa-dev] [PATCH] glsl_to_tgsi: try harder to lower unsupported ir_binop_vector_extract

Marek Olšák maraeo at gmail.com
Wed Apr 18 19:36:00 UTC 2018


Well, it fixes some piglits, but I don't remember which ones.

Marek

On Wed, Apr 18, 2018 at 5:31 AM, Nicolai Hähnle <nhaehnle at gmail.com> wrote:

> On 16.04.2018 23:02, Marek Olšák wrote:
>
>> From: Marek Olšák <marek.olsak at amd.com>
>>
>> Cc: 18.0 <mesa-stable at lists.freedesktop.org>
>>
>
> Would be nice to have an indication of what this fixes. Apart from that it
> looks reasonable.
>
> Reviewed-by: Nicolai Hähnle <nicolai.haehnle at amd.com>
>
>
>
> ---
>>   src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 5 +++++
>>   1 file changed, 5 insertions(+)
>>
>> diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
>> b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
>> index 01a58d7d2c6..b321112cf88 100644
>> --- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
>> +++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
>> @@ -7117,20 +7117,25 @@ st_link_shader(struct gl_context *ctx, struct
>> gl_shader_program *prog)
>>            /* Repeat it until it stops making changes. */
>>            bool progress;
>>            do {
>>               progress = do_common_optimization(ir, true, true, options,
>>
>> ctx->Const.NativeIntegers);
>>               progress |= lower_if_to_cond_assign((gl_shader_stage)i, ir,
>>                                                   options->MaxIfDepth,
>> if_threshold);
>>            } while (progress);
>>         }
>>   +      /* Do this again to lower ir_binop_vector_extract introduced
>> +       * by optimization passes.
>> +       */
>> +      do_vec_index_to_cond_assign(ir);
>> +
>>         validate_ir_tree(ir);
>>      }
>>        build_program_resource_list(ctx, prog);
>>        if (use_nir)
>>         return st_link_nir(ctx, prog);
>>        for (unsigned i = 0; i < MESA_SHADER_STAGES; i++) {
>>         struct gl_linked_shader *shader = prog->_LinkedShaders[i];
>>
>>
>
> --
> Lerne, wie die Welt wirklich ist,
> Aber vergiss niemals, wie sie sein sollte.
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180418/bedcf9b9/attachment-0001.html>


More information about the mesa-dev mailing list