nir: add bit_size info to nir_load_const_instr_create()

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
This commit is contained in:
Samuel Iglesias Gonsálvez
2016-03-23 08:04:18 +01:00
parent a5b17ae745
commit 3663a2397e
10 changed files with 21 additions and 16 deletions

View File

@@ -477,7 +477,8 @@ construct_value(const nir_search_value *value,
case nir_search_value_constant: {
const nir_search_constant *c = nir_search_value_as_constant(value);
nir_load_const_instr *load = nir_load_const_instr_create(mem_ctx, 1);
nir_load_const_instr *load =
nir_load_const_instr_create(mem_ctx, 1, bitsize->dest_size);
switch (c->type) {
case nir_type_float:
@@ -528,8 +529,6 @@ construct_value(const nir_search_value *value,
unreachable("Invalid alu source type");
}
load->def.bit_size = bitsize->dest_size;
nir_instr_insert_before(instr, &load->instr);
nir_alu_src val;