diff --git a/src/gallium/drivers/zink/zink_kopper.c b/src/gallium/drivers/zink/zink_kopper.c index 992686cd31e..3156fc25fbb 100644 --- a/src/gallium/drivers/zink/zink_kopper.c +++ b/src/gallium/drivers/zink/zink_kopper.c @@ -745,6 +745,11 @@ zink_kopper_present_queue(struct zink_screen *screen, struct zink_resource *res) struct kopper_displaytarget *cdt = res->obj->dt; assert(zink_kopper_acquired(res->obj->dt, res->obj->dt_idx)); assert(res->obj->present); + + /* always try to prune if the current swapchain has seen presents */ + if (cdt->swapchain->last_present != UINT32_MAX) + prune_old_swapchains(screen, cdt, false); + struct kopper_present_info *cpi = malloc(sizeof(struct kopper_present_info)); cpi->sem = res->obj->present; cpi->res = res;