From 55448cf43a6eca20b75f11177a86222abb8103ef Mon Sep 17 00:00:00 2001 From: Ian Romanick Date: Tue, 3 Sep 2024 13:47:02 -0700 Subject: [PATCH] radeonsi: Use nir_opt_generate_bfi to generate bitfield_select Not tested. v2: Move after nir_opt_algebraic. Suggested by Georg. v3: has_bitfield_select is always enabled on GCN+. Suggested by Georg. Reviewed-by: Georg Lehmann Part-of: --- src/gallium/drivers/radeonsi/si_shader_nir.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/radeonsi/si_shader_nir.c b/src/gallium/drivers/radeonsi/si_shader_nir.c index 7834eff1039..8581f0b7262 100644 --- a/src/gallium/drivers/radeonsi/si_shader_nir.c +++ b/src/gallium/drivers/radeonsi/si_shader_nir.c @@ -122,6 +122,7 @@ void si_nir_opts(struct si_screen *sscreen, struct nir_shader *nir, bool first) /* Needed for algebraic lowering */ NIR_PASS(progress, nir, nir_lower_bit_size, si_lower_bit_size_callback, NULL); NIR_PASS(progress, nir, nir_opt_algebraic); + NIR_PASS(progress, nir, nir_opt_generate_bfi); NIR_PASS(progress, nir, nir_opt_constant_folding); if (!nir->info.flrp_lowered) {