From 65353814a395b97a5a472d5eaea6383f4eea6fa3 Mon Sep 17 00:00:00 2001 From: Iago Toral Quiroga Date: Tue, 13 Jun 2023 10:27:57 +0200 Subject: [PATCH] nir/lower_tex: copy missing fields when creating copy of tex instruction MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This is missing both texture and sampler indices. Reviewed-by: Alejandro Piñeiro Reviewed-by: Alyssa Rosenzweig Part-of: --- src/compiler/nir/nir_lower_tex.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/compiler/nir/nir_lower_tex.c b/src/compiler/nir/nir_lower_tex.c index efe530f..8c523ba 100644 --- a/src/compiler/nir/nir_lower_tex.c +++ b/src/compiler/nir/nir_lower_tex.c @@ -1127,6 +1127,8 @@ lower_tg4_offsets(nir_builder *b, nir_tex_instr *tex) tex_copy->is_gather_implicit_lod = tex->is_gather_implicit_lod; tex_copy->component = tex->component; tex_copy->dest_type = tex->dest_type; + tex_copy->texture_index = tex->texture_index; + tex_copy->sampler_index = tex->sampler_index; for (unsigned j = 0; j < tex->num_srcs; ++j) { nir_src_copy(&tex_copy->src[j].src, &tex->src[j].src, &tex_copy->instr); -- 2.7.4