[Mesa-dev] [PATCH 02/16] st/nine: Fix wrong assert in nine_shader

Ilia Mirkin imirkin at alum.mit.edu
Fri Apr 24 14:06:33 PDT 2015


Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu>

On Fri, Apr 24, 2015 at 4:09 PM, Axel Davy <axel.davy at ens.fr> wrote:
> The sampler src index was wrong for texldl and texldd
>
> Signed-off-by: Axel Davy <axel.davy at ens.fr>
> ---
>  src/gallium/state_trackers/nine/nine_shader.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/src/gallium/state_trackers/nine/nine_shader.c b/src/gallium/state_trackers/nine/nine_shader.c
> index 0fd3d37..1f1f7c8 100644
> --- a/src/gallium/state_trackers/nine/nine_shader.c
> +++ b/src/gallium/state_trackers/nine/nine_shader.c
> @@ -2493,8 +2493,8 @@ DECL_SPECIAL(TEXLDD)
>          tx_src_param(tx, &tx->insn.src[2]),
>          tx_src_param(tx, &tx->insn.src[3])
>      };
> -    assert(tx->insn.src[3].idx >= 0 &&
> -           tx->insn.src[3].idx < Elements(tx->sampler_targets));
> +    assert(tx->insn.src[1].idx >= 0 &&
> +           tx->insn.src[1].idx < Elements(tx->sampler_targets));
>      target = tx->sampler_targets[tx->insn.src[1].idx];
>
>      ureg_TXD(tx->ureg, dst, target, src[0], src[2], src[3], src[1]);
> @@ -2509,8 +2509,8 @@ DECL_SPECIAL(TEXLDL)
>         tx_src_param(tx, &tx->insn.src[0]),
>         tx_src_param(tx, &tx->insn.src[1])
>      };
> -    assert(tx->insn.src[3].idx >= 0 &&
> -           tx->insn.src[3].idx < Elements(tx->sampler_targets));
> +    assert(tx->insn.src[1].idx >= 0 &&
> +           tx->insn.src[1].idx < Elements(tx->sampler_targets));
>      target = tx->sampler_targets[tx->insn.src[1].idx];
>
>      ureg_TXL(tx->ureg, dst, target, src[0], src[1]);
> --
> 2.1.0
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list