[Mesa-dev] [PATCH 05/29] nir/clone: clone bit_size in clone_load_const

Jason Ekstrand jason at jlekstrand.net
Mon Mar 21 22:33:30 UTC 2016


On Mon, Mar 21, 2016 at 5:05 AM, Samuel Iglesias Gonsálvez <
siglesias at igalia.com> wrote:

> From: Iago Toral Quiroga <itoral at igalia.com>
>
> ---
>  src/compiler/nir/nir_clone.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/src/compiler/nir/nir_clone.c b/src/compiler/nir/nir_clone.c
> index 7444dfe..b1da332 100644
> --- a/src/compiler/nir/nir_clone.c
> +++ b/src/compiler/nir/nir_clone.c
> @@ -354,6 +354,7 @@ clone_load_const(clone_state *state, const
> nir_load_const_instr *lc)
>
>     memcpy(&nlc->value, &lc->value, sizeof(nlc->value));
>
> +   nlc->def.bit_size = lc->def.bit_size;
>

Why not make nir_load_const_instr_create take a bit size?  That seems like
the better thing to do.  It would also guarantee that we got everything.


>     add_remap(state, &nlc->def, &lc->def);
>
>     return nlc;
> --
> 2.5.0
>
> _______________________________________________
> 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/20160321/de0ef3a5/attachment-0001.html>


More information about the mesa-dev mailing list