nir/passthrough_gs: Fix array size
authorAlyssa Rosenzweig <alyssa@rosenzweig.io>
Fri, 18 Aug 2023 15:58:01 +0000 (11:58 -0400)
committerMarge Bot <emma+marge@anholt.net>
Sat, 19 Aug 2023 17:13:49 +0000 (17:13 +0000)
commit558e36f64196ec734e4c7502db491f56f76118cd
tree8f44baa64a05b4d15e834f084f59eefb7283d6c7
parentfe4208ed4c9a08c7963caa287ae34e9357de68af
nir/passthrough_gs: Fix array size

Triangle strips with adjacency have 6 vertices input, so we need an array big
enough for all 6 vertices to avoid overflow. Fixes passthrough GS generated for
KHR-GLES31.core.draw_indirect.basic-mode-*-triangle*adj*.

Fixes: ea14579f3dc ("nir: handle primitives with adjacency")
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Antonino Maniscalco <antonino.maniscalco@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24780>
src/compiler/nir/nir_passthrough_gs.c