turnip: fix assert for max xfb outputs

this is a counter, not an index, so use <=

cc: mesa-stable

Reviewed-by: Hyunjun Ko <zzoon@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16620>
(cherry picked from commit aa32b96c51)
This commit is contained in:
Mike Blumenkrantz 2022-05-18 10:07:43 -04:00 committed by Dylan Baker
parent 8e85e7d7e9
commit a15759a568
2 changed files with 2 additions and 2 deletions

View file

@ -571,7 +571,7 @@
"description": "turnip: fix assert for max xfb outputs",
"nominated": true,
"nomination_type": 0,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null
},

View file

@ -672,7 +672,7 @@ tu_gather_xfb_info(nir_shader *nir, struct ir3_stream_output_info *info)
output_map[var->data.location + i] = var->data.driver_location + i;
}
assert(xfb->output_count < IR3_MAX_SO_OUTPUTS);
assert(xfb->output_count <= IR3_MAX_SO_OUTPUTS);
info->num_outputs = xfb->output_count;
for (int i = 0; i < IR3_MAX_SO_BUFFERS; i++) {