Lines Matching defs:match
36 * This allows for fast indexing into arrays. This file tries to pattern match the offset in NIR with this form to reduce pressure on the ALU pipe.
200 /* Tries to pattern match into mir_address */
256 struct mir_address match = mir_match_offset(offset->ssa, first_free, true);
258 if (match.A.def) {
259 unsigned bitsize = match.A.def->bit_size;
262 ins->src[1] = nir_ssa_index(match.A.def);
263 ins->swizzle[1][0] = match.A.comp;
272 if (match.B.def) {
273 ins->src[2] = nir_ssa_index(match.B.def);
274 ins->swizzle[2][0] = match.B.comp;
275 ins->src_types[2] = nir_type_uint | match.B.def->bit_size;
280 match.type = midgard_index_address_s32;
282 ins->load_store.index_format = match.type;
284 assert(match.shift <= 7);
285 ins->load_store.index_shift = match.shift;
287 ins->constants.u32[0] = match.bias;
295 struct mir_address match = mir_match_offset(src->ssa, false, false);
297 if (match.B.def) {
298 ins->src[2] = nir_ssa_index(match.B.def);
301 ins->swizzle[2][i] = match.B.comp;
304 ins->load_store.index_shift = match.shift;
305 ins->constants.u32[0] = match.bias + bias;