aco: use correct dim for FMASK fetches

I think it somehow worked fine previously, but this is more correct.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12214>
This commit is contained in:
Rhys Perry 2021-10-06 18:10:25 +01:00 committed by Marge Bot
parent 91a5c9fdf2
commit cfb816b2a5

View file

@ -9741,7 +9741,10 @@ visit_tex(isel_context* ctx, nir_tex_instr* instr)
Operand vdata = instr->is_sparse ? emit_tfe_init(bld, tmp_dst) : Operand(v1);
MIMG_instruction* tex =
emit_mimg(bld, op, Definition(tmp_dst), resource, Operand(s4), args, 0, vdata);
tex->dim = dim;
if (instr->op == nir_texop_fragment_mask_fetch_amd)
tex->dim = da ? ac_image_2darray : ac_image_2d;
else
tex->dim = dim;
tex->dmask = dmask & 0xf;
tex->unrm = true;
tex->da = da;