unsigned num_components, unsigned bit_size);
static inline void
nir_ssa_dest_init_for_type(nir_instr *instr, nir_dest *dest,
- const struct glsl_type *type,
- const char *name)
+ const struct glsl_type *type)
{
assert(glsl_type_is_vector_or_scalar(type));
nir_ssa_dest_init(instr, dest, glsl_get_components(type),
nir_intrinsic_op op =
nir_intrinsic_from_system_value(var->data.location);
nir_intrinsic_instr *load = nir_intrinsic_instr_create(b->shader, op);
- nir_ssa_dest_init_for_type(&load->instr, &load->dest,
- var->type, NULL);
+ nir_ssa_dest_init_for_type(&load->instr, &load->dest, var->type);
load->num_components = load->dest.ssa.num_components;
nir_builder_instr_insert(b, &load->instr);
return &load->dest.ssa;
const struct glsl_type *dest_type = vtn_get_type(b, w[1])->type;
nir_intrinsic_instr *intrin = nir_intrinsic_instr_create(b->nb.shader, op);
- nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest, dest_type, NULL);
+ nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest, dest_type);
if (nir_intrinsic_infos[op].src_components[0] == 0)
intrin->num_components = intrin->dest.ssa.num_components;
nir_intrinsic_instr *intrin =
nir_intrinsic_instr_create(b->nb.shader, nir_op);
- nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest,
- dst->type, NULL);
+ nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest, dst->type);
intrin->num_components = intrin->dest.ssa.num_components;
intrin->src[0] = nir_src_for_ssa(src0->def);
"OpGroupNonUniformElect must return a Bool");
nir_intrinsic_instr *elect =
nir_intrinsic_instr_create(b->nb.shader, nir_intrinsic_elect);
- nir_ssa_dest_init_for_type(&elect->instr, &elect->dest,
- dest_type->type, NULL);
+ nir_ssa_dest_init_for_type(&elect->instr, &elect->dest, dest_type->type);
nir_builder_instr_insert(&b->nb, &elect->instr);
vtn_push_nir_ssa(b, w[2], &elect->dest.ssa);
break;
intrin->src[1] = nir_src_for_ssa(nir_load_subgroup_invocation(&b->nb));
nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest,
- dest_type->type, NULL);
+ dest_type->type);
nir_builder_instr_insert(&b->nb, &intrin->instr);
vtn_push_nir_ssa(b, w[2], &intrin->dest.ssa);
intrin->src[1] = nir_src_for_ssa(src1);
nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest,
- dest_type->type, NULL);
+ dest_type->type);
nir_builder_instr_insert(&b->nb, &intrin->instr);
vtn_push_nir_ssa(b, w[2], &intrin->dest.ssa);
intrin->num_components = src0->num_components;
intrin->src[0] = nir_src_for_ssa(src0);
nir_ssa_dest_init_for_type(&intrin->instr, &intrin->dest,
- dest_type->type, NULL);
+ dest_type->type);
nir_builder_instr_insert(&b->nb, &intrin->instr);
vtn_push_nir_ssa(b, w[2], &intrin->dest.ssa);
nir_intrinsic_instr_create(b->nb.shader,
nir_intrinsic_load_deref_block_intel);
load->src[0] = nir_src_for_ssa(&src->dest.ssa);
- nir_ssa_dest_init_for_type(&load->instr, &load->dest,
- res_type->type, NULL);
+ nir_ssa_dest_init_for_type(&load->instr, &load->dest, res_type->type);
load->num_components = load->dest.ssa.num_components;
nir_builder_instr_insert(&b->nb, &load->instr);