nir/from_ssa: adapt to different bit sizes
authorConnor Abbott <connor.w.abbott@intel.com>
Tue, 17 Nov 2015 14:49:29 +0000 (15:49 +0100)
committerSamuel Iglesias Gonsálvez <siglesias@igalia.com>
Mon, 11 Apr 2016 06:27:04 +0000 (08:27 +0200)
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/compiler/nir/nir_from_ssa.c

index 82317c21b62dabd28dad6ccaebce5ffd7ee6c048..7bbc2c0f299a37975be7f773dede9be460e34be1 100644 (file)
@@ -474,6 +474,7 @@ rewrite_ssa_def(nir_ssa_def *def, void *void_state)
          node->set->reg = nir_local_reg_create(state->impl);
          node->set->reg->name = def->name;
          node->set->reg->num_components = def->num_components;
+         node->set->reg->bit_size = def->bit_size;
          node->set->reg->num_array_elems = 0;
       }
 
@@ -491,6 +492,7 @@ rewrite_ssa_def(nir_ssa_def *def, void *void_state)
       reg = nir_local_reg_create(state->impl);
       reg->name = def->name;
       reg->num_components = def->num_components;
+      reg->bit_size = def->bit_size;
       reg->num_array_elems = 0;
    }