- uint64_t output_mask = 0;
- nir_foreach_variable(variable, &nir->outputs) {
- const glsl_type *type = variable->type;
- if (nir_is_per_vertex_io(variable, nir->info.stage))
- type = type->fields.array;
- unsigned slots = type->count_attribute_slots(false);
- if (variable->data.compact) {
- unsigned component_count = variable->data.location_frac + type->length;
- slots = (component_count + 3) / 4;
- }
- output_mask |= ((1ull << slots) - 1) << variable->data.location;
- }
+ unsigned bit_size = alu->dest.dest.ssa.bit_size;
+ if (nir_alu_instr_is_comparison(alu))
+ bit_size = nir_src_bit_size(alu->src[0].src);