radeonsi: support mesh shader per vertex output
mesh shader uses per vertex output store, and si_nir_assign_param_offsets assert output store to be scalar. Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37932>
This commit is contained in:
@@ -1226,7 +1226,8 @@ static void si_nir_assign_param_offsets(nir_shader *nir, struct si_shader *shade
|
||||
continue;
|
||||
|
||||
nir_intrinsic_instr *intr = nir_instr_as_intrinsic(instr);
|
||||
if (intr->intrinsic != nir_intrinsic_store_output)
|
||||
if (intr->intrinsic != nir_intrinsic_store_output &&
|
||||
intr->intrinsic != nir_intrinsic_store_per_vertex_output)
|
||||
continue;
|
||||
|
||||
/* No indirect indexing allowed. */
|
||||
|
||||
@@ -324,7 +324,8 @@ static void si_lower_nir(struct si_screen *sscreen, struct nir_shader *nir)
|
||||
/* si_nir_kill_outputs and ac_nir_optimize_outputs require outputs to be scalar. */
|
||||
if (nir->info.stage == MESA_SHADER_VERTEX ||
|
||||
nir->info.stage == MESA_SHADER_TESS_EVAL ||
|
||||
nir->info.stage == MESA_SHADER_GEOMETRY)
|
||||
nir->info.stage == MESA_SHADER_GEOMETRY ||
|
||||
nir->info.stage == MESA_SHADER_MESH)
|
||||
NIR_PASS(_, nir, nir_lower_io_to_scalar, nir_var_shader_out, NULL, NULL);
|
||||
|
||||
if (nir->info.stage == MESA_SHADER_GEOMETRY) {
|
||||
|
||||
Reference in New Issue
Block a user