radeonsi: get the value for load_tcs_primitive_mode_amd from shader info

This is possible thanks to the commit:
    "st/mesa: copy some TES shader info fields to TCS".

Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32171>
This commit is contained in:
Marek Olšák 2024-09-29 22:40:07 -04:00
parent e28e05ffe4
commit 702982d399

View file

@ -738,7 +738,10 @@ static bool lower_intrinsic(nir_builder *b, nir_instr *instr, struct lower_abi_s
if (shader->is_monolithic) {
replacement = nir_imm_int(b, key->ge.opt.tes_prim_mode);
} else {
replacement = ac_nir_unpack_arg(b, &args->ac, args->tcs_offchip_layout, 29, 2);
if (b->shader->info.tess._primitive_mode != TESS_PRIMITIVE_UNSPECIFIED)
replacement = nir_imm_int(b, b->shader->info.tess._primitive_mode);
else
replacement = ac_nir_unpack_arg(b, &args->ac, args->tcs_offchip_layout, 29, 2);
}
break;
case nir_intrinsic_load_ring_gsvs_amd: {