mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-26 17:10:11 +01:00
zink: don't finish barriers cmd buffer if not used.
finishing has some cpu overhead, which if the cmd buffer isn't going to be used is pointless. just let it get reset next time. Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16393>
This commit is contained in:
parent
57df27be5f
commit
87f4252a51
1 changed files with 6 additions and 4 deletions
|
|
@ -403,10 +403,12 @@ submit_queue(void *data, void *gdata, int thread_index)
|
|||
bs->is_device_lost = true;
|
||||
goto end;
|
||||
}
|
||||
if (VKSCR(EndCommandBuffer)(bs->barrier_cmdbuf) != VK_SUCCESS) {
|
||||
mesa_loge("ZINK: vkEndCommandBuffer failed");
|
||||
bs->is_device_lost = true;
|
||||
goto end;
|
||||
if (bs->has_barriers) {
|
||||
if (VKSCR(EndCommandBuffer)(bs->barrier_cmdbuf) != VK_SUCCESS) {
|
||||
mesa_loge("ZINK: vkEndCommandBuffer failed");
|
||||
bs->is_device_lost = true;
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
|
||||
while (util_dynarray_contains(&bs->persistent_resources, struct zink_resource_object*)) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue