nak: Fix cbuf textures

Somewhere between writing c1510ad72e ("nak: Optimize bindless to cbuf
textures on Volta+") and me rebasing it a year later, we switched to
using the NV-specific ldc_nv intrinsic for cbuf loads.  It's basically
the same as load_ubo but we're detecting the wrong intrinsic so the
optimization does nothing.

Fixes: c1510ad72e ("nak: Optimize bindless to cbuf textures on Volta+")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33398>
This commit is contained in:
Faith Ekstrand 2025-02-05 04:22:13 -06:00 committed by Marge Bot
parent 4d86a1c928
commit 555b8580ae

View file

@ -16,7 +16,7 @@ tex_handle_as_cbuf(nir_def *tex_h, uint32_t *cbuf_out)
return false;
nir_intrinsic_instr *intrin = nir_instr_as_intrinsic(tex_h->parent_instr);
if (intrin->intrinsic != nir_intrinsic_load_ubo)
if (intrin->intrinsic != nir_intrinsic_ldc_nv)
return false;
if (!nir_src_is_const(intrin->src[1]))