Skip to content

zink: try update fb resource refs when starting new renderpass

Mike Blumenkrantz requested to merge zmike/mesa:zink-fbref into main

in the case where a draw is triggered after a flush, zink_update_descriptor_refs will be called to set batch tracking for descriptors. this function also handles refs for fb attachments, and everything is usually fine there

the problem with this approach is that tracking is no longer set on view objects at renderpass begin, which makes them susceptible to early deletion

instead, apply batch tracking to fb attachment resources on renderpass begin if the BATCH_CHANGED flag is set (need to rename this at some point) in order to guarantee that the resource (object) lifetime will match the cmdbuf runtime [since imageviews are now only freed upon batch completion]

fixes #9059 (closed)

Fixes: f6bbd787 ("zink: remove batch tracking/usage from view types"

Merge request reports