mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-04-19 18:50:43 +02:00
zink: check ctx batch states first when finding a usable one
this ensures the completed ones get queued for recycling faster Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37068>
This commit is contained in:
parent
067873d4a4
commit
d1f8cd54f4
1 changed files with 4 additions and 4 deletions
|
|
@ -481,13 +481,13 @@ get_batch_state(struct zink_context *ctx)
|
|||
if (bs == ctx->last_free_batch_state)
|
||||
ctx->last_free_batch_state = NULL;
|
||||
}
|
||||
/* try from the ones that are given back to the screen next */
|
||||
if (!bs)
|
||||
bs = find_screen_state(screen, ctx);
|
||||
|
||||
/* always try to recycle ctx states first */
|
||||
if (!bs)
|
||||
bs = find_completed_batch_state(ctx);
|
||||
|
||||
if (!bs)
|
||||
bs = find_screen_state(screen, ctx);
|
||||
|
||||
if (bs) {
|
||||
bs->next = NULL;
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue