nir/lower_tex: skip lower_tex_packing for the texture samples query
authorIago Toral Quiroga <itoral@igalia.com>
Tue, 4 Aug 2020 09:18:46 +0000 (11:18 +0200)
committerIago Toral Quiroga <itoral@igalia.com>
Wed, 5 Aug 2020 06:39:52 +0000 (08:39 +0200)
commit71572ebb32e5a460e5039fb27903f60b3b89e037
tree2964d368632a23a2e6e9f067388793bbef7396b4
parent1938e2596f5110c81920a1ad5e5933ef3a007a99
nir/lower_tex: skip lower_tex_packing for the texture samples query

Similar to other skips for texture queries that don't actually sample
the texture and which results are not packed.

We can't use nir_tex_instr_is_query() here to skip the lowering for all
queries since that causes regressions in Piglit. Apparently, we do want
to lower some of the query results. In particularly, the LOD query.

Reviewed-by: Alejandro PiƱeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6169>
src/compiler/nir/nir_lower_tex.c