diff --git a/.pick_status.json b/.pick_status.json index 1bd8cdaa456..f3e7637db95 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -124,7 +124,7 @@ "description": "pan/bi: Use 2D dimension with TEX_FETCH with CUBE on Valhall", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "ce52b6d35975c82077d5d2efe8430063fa2a4abc", "notes": null diff --git a/src/panfrost/compiler/bifrost_compile.c b/src/panfrost/compiler/bifrost_compile.c index d4559440e83..8f12fd9a837 100644 --- a/src/panfrost/compiler/bifrost_compile.c +++ b/src/panfrost/compiler/bifrost_compile.c @@ -4128,10 +4128,16 @@ bi_emit_tex_valhall(bi_builder *b, nir_tex_instr *instr) !narrow_indices, mask, sr_count); break; case nir_texop_txf: - case nir_texop_txf_ms: + case nir_texop_txf_ms: { + /* On Valhall, TEX_FETCH doesn't have CUBE support. This is not a problem + * as a cube is just a 2D array in any cases. */ + if (dim == BI_DIMENSION_CUBE) + dim = BI_DIMENSION_2D; + bi_tex_fetch_to(b, dest, idx, src0, src1, instr->is_array, dim, regfmt, explicit_offset, !narrow_indices, mask, sr_count); break; + } case nir_texop_tg4: bi_tex_gather_to(b, dest, idx, src0, src1, instr->is_array, dim, instr->component, false, regfmt, instr->is_shadow,