mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-03 01:18:06 +02:00
zink: fix clip/cull dist xfb inlining
these are compact arrays which don't take up slots according to normal array i/o sizing rules Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24634>
This commit is contained in:
parent
235ae7c3c6
commit
01d3c691a5
1 changed files with 3 additions and 1 deletions
|
|
@ -1908,7 +1908,9 @@ update_so_info(struct zink_shader *zs, nir_shader *nir, const struct pipe_stream
|
|||
if (var->data.is_xfb)
|
||||
goto out;
|
||||
|
||||
unsigned num_slots = glsl_count_vec4_slots(var->type, false, false);
|
||||
unsigned num_slots = var->data.location >= VARYING_SLOT_CLIP_DIST0 && var->data.location <= VARYING_SLOT_CULL_DIST1 ?
|
||||
glsl_array_size(var->type) / 4 :
|
||||
glsl_count_vec4_slots(var->type, false, false);
|
||||
/* for each variable, iterate over all the variable's slots and inline the outputs */
|
||||
for (unsigned j = 0; j < num_slots; j++) {
|
||||
slot = var->data.location + j;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue