mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 13:38:06 +02:00
gallium/draw: Fix intermittent failure to bind new geometry shaders.
If you deleted your old GS and created a new one, then it would
occasionally skip binding the new GS because the token pointers were
equal. Clear the current token pointer in the machine when we're deleting
its token.
Cc: mesa-stable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8277>
(cherry picked from commit 969f50ddcf)
This commit is contained in:
parent
2f6f5b3ba2
commit
2b66910037
2 changed files with 4 additions and 1 deletions
|
|
@ -1120,7 +1120,7 @@
|
|||
"description": "gallium/draw: Fix intermittent failure to bind new geometry shaders.",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"master_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -964,6 +964,9 @@ void draw_delete_geometry_shader(struct draw_context *draw,
|
|||
}
|
||||
#endif
|
||||
|
||||
if (draw->gs.tgsi.machine && draw->gs.tgsi.machine->Tokens == dgs->state.tokens)
|
||||
draw->gs.tgsi.machine->Tokens = NULL;
|
||||
|
||||
for (i = 0; i < TGSI_MAX_VERTEX_STREAMS; i++)
|
||||
FREE(dgs->stream[i].primitive_lengths);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue