[Mesa-dev] [PATCH] ac/nir_to_llvm: add missing parentheses in get_inst_tessfactor_writemask()

Bas Nieuwenhuizen bas at basnieuwenhuizen.nl
Mon Jan 7 23:50:56 UTC 2019


I think this got fixed by
https://gitlab.freedesktop.org/mesa/mesa/commit/be6cee51c06dc72ac159bd75b4201c61952515bd
already?

On Tue, Jan 8, 2019 at 12:28 AM Timothy Arceri <tarceri at itsqueeze.com> wrote:
>
> Cc: Marek Olšák <maraeo at gmail.com>
> ---
>  src/amd/common/ac_nir_to_llvm.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c
> index 84dbe17457..c9e11142eb 100644
> --- a/src/amd/common/ac_nir_to_llvm.c
> +++ b/src/amd/common/ac_nir_to_llvm.c
> @@ -4086,9 +4086,9 @@ get_inst_tessfactor_writemask(nir_intrinsic_instr *intrin)
>         unsigned num_comps = intrin->dest.ssa.num_components;
>
>         if (location == VARYING_SLOT_TESS_LEVEL_INNER)
> -               writemask = ((1 << num_comps + 1) - 1) << first_component;
> +               writemask = ((1 << (num_comps + 1)) - 1) << first_component;
>         else if (location == VARYING_SLOT_TESS_LEVEL_OUTER)
> -               writemask = (((1 << num_comps + 1) - 1) << first_component) << 4;
> +               writemask = (((1 << (num_comps + 1)) - 1) << first_component) << 4;
>
>         return writemask;
>  }
> --
> 2.20.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list