Is that correct in the case where I have something like

dvec4 foo = ...
bool x = (foo == dvec4(0, 1, 2, 3));

?

Can you elaborate a little bit more as to why this is right? Shouldn't
this be based on the swizzle of the src[j] argument? [Note, I haven't
carefully read all the surrounding code.]

On Tue, Jun 21, 2016 at 9:00 PM, Dave Airlie <airl...@gmail.com> wrote:
> From: Dave Airlie <airl...@redhat.com>
>
> Signed-off-by: Dave Airlie <airl...@redhat.com>
> ---
>  src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp 
> b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
> index 9de603c..3d8ddc3 100644
> --- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
> +++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
> @@ -816,7 +816,7 @@ glsl_to_tgsi_visitor::emit_asm(ir_instruction *ir, 
> unsigned op,
>
>              if (glsl_base_type_is_64bit(dinst->src[j].type)) {
>                 dinst->src[j].index = initial_src_idx[j];
> -               if (swz > 1) {
> +               if (swz > 1 && dinst->src[j].file != PROGRAM_IMMEDIATE) {
>                    dinst->src[j].double_reg2 = true;
>                    dinst->src[j].index++;
>                }
> --
> 2.5.5
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to