pan/bi: Use texture index instead of sampler for message preloading
authorIcecream95 <ixn@disroot.org>
Fri, 29 Apr 2022 20:36:40 +0000 (08:36 +1200)
committerMarge Bot <emma+marge@anholt.net>
Mon, 2 May 2022 12:50:44 +0000 (12:50 +0000)
commit2864094f69db38f1948bad738256db4699653fad
treeb675b32b13a75037ec953019549f2e4b3ea717d3
parent4a2ff9eb86acdc0b5cc35ca2c2f6ec5cfe9671a9
pan/bi: Use texture index instead of sampler for message preloading

The VAR_TEX definition in ISA.xml only has a field for texture_index,
so trying to read sampler_index will return zero; read from
texture_index instead, and rename other fields for consistency.

The texture and sampler indices must be equal for VAR_TEX to be used,
so either name could be used for the field.

Fixes the wrong textures being used in Thief.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6219
Fixes: eb1479bda22 ("pan/bi: Support message preloading")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16255>
src/panfrost/bifrost/bi_opt_message_preload.c
src/panfrost/lib/genxml/v7.xml
src/panfrost/lib/pan_shader.h
src/panfrost/util/pan_ir.h