dlist: don't handle unmerged draws as merged
authorPierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Tue, 20 Jul 2021 12:31:19 +0000 (14:31 +0200)
committerMarge Bot <eric+marge@anholt.net>
Tue, 27 Jul 2021 08:19:16 +0000 (08:19 +0000)
commit11d6441b94c7bf59ee32c8bcb0e30d370f3bd42c
treef1549ab1f2561110431e3541f90cb50253640471
parent0b36c2916dcdf4785c46194a1ef83e64b52b0430
dlist: don't handle unmerged draws as merged

The comment was incorrect: we can have N draws using the
same mode with N > 1 (eg: GL_QUAD_STRIP draws
cannot be merged).

This commit fixes the drawing code to use the correct draw
function.

This fixes a hang in Starsector (see issue #5086).

Fixes: b328d8e9bc9 ("dlist: use an union instead of allocating a 1-sized array")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11978>
src/mesa/vbo/vbo_save_draw.c