vrend: move program only into front of queue of it is not already there

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
macos/master
Gert Wollny 4 years ago
parent 4a5c238d53
commit 9fbc538ac6
  1. 7
      src/vrend_renderer.c

@ -1733,9 +1733,10 @@ static struct vrend_linked_shader_program *lookup_shader_program(struct vrend_su
ent->ss[PIPE_SHADER_TESS_EVAL]->id != tes_id)
continue;
/* put the entry in front */
list_del(&ent->head);
list_add(&ent->head, programs);
if (programs->next != &ent->head) {
list_del(&ent->head);
list_add(&ent->head, programs);
}
return ent;
}

Loading…
Cancel
Save