Skip to content

Metal: Track resource residency at the device level#101

Merged
squidbus merged 1 commit into
renderbag:mainfrom
squidbus:res-sets
May 25, 2026
Merged

Metal: Track resource residency at the device level#101
squidbus merged 1 commit into
renderbag:mainfrom
squidbus:res-sets

Conversation

@squidbus
Copy link
Copy Markdown
Contributor

@squidbus squidbus commented May 23, 2026

plume currently faces resource corruption issues in some workloads, like N64 recompiles using RT64, when residency sets are enabled. This PR takes the heavy-handed approach of tracking all resources in a device-level residency set that we can bind to each queue. We were already doing this for GPU addressable resources, this just expands it to cover all resources.

This is the approach currently taken by Vulkan-on-Metal implementations, since the Vulkan memory model seems to assume that all resources are always GPU-resident, so it's a strategy that's proven to work fine. This also avoids issues where using more than 32 descriptor sets large enough to trigger the use of residency sets would exceed Metal's limit of residency sets per command buffer.

Copy link
Copy Markdown
Contributor

@dcvz dcvz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@squidbus squidbus merged commit 4f556be into renderbag:main May 25, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants