pan/bi: Add documentation for bifrost_nir_lower_store_component

Taken from the commit that introduced the function,
95458c4033 ("pan/bi: Lower stores with component != 0").

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15250>
This commit is contained in:
Icecream95 2022-02-23 23:16:35 +13:00 committed by Alyssa Rosenzweig
parent 42caddcf6b
commit 24101d944b

View file

@ -3742,6 +3742,10 @@ bi_opt_post_ra(bi_context *ctx)
}
}
/* If the shader packs multiple varyings into the same location with different
* location_frac, we'll need to lower to a single varying store that collects
* all of the channels together.
*/
static bool
bifrost_nir_lower_store_component(struct nir_builder *b,
nir_instr *instr, void *data)
@ -3785,7 +3789,7 @@ bifrost_nir_lower_store_component(struct nir_builder *b,
}
intr->num_components = util_last_bit(mask);
nir_instr_rewrite_src_ssa(instr, &intr->src[0],
nir_instr_rewrite_src_ssa(instr, &intr->src[0],
nir_vec(b, channels, intr->num_components));
nir_intrinsic_set_component(intr, 0);