Skip to content

feat: support explicit resource ownership while preserving existing defaults - #4193

Draft
ibgreen wants to merge 18 commits into
masterfrom
codex/resource-ownership-poc
Draft

ibgreen wants to merge 18 commits into
masterfrom
codex/resource-ownership-poc

Conversation

@ibgreen

@ibgreen ibgreen commented Dec 3, 2026 •

Copy link
Copy Markdown
Collaborator

Goals

Introduce explicit resource ownership in a backwards-compatible release. Applications can migrate one binding at a time before bare geometry inputs start borrowing.

Changes

  • Support checked {own: resource} and explicit {borrow: resource} in texture and framebuffer factories, Model geometry, and vertex and index buffer slots on GPUGeometry. A bare Model geometry or geometry buffer retains its existing teardown behavior.
  • Add creation-time owner and owner-side transfer and release methods. Preserve the single public TextureProps and FramebufferProps types.
  • Document async publication, cloning, failure cleanup, mixed buffer ownership and explicit sharing. Preserve existing bare sampler defaults, including the null backend.
  • Include the RFC and Resource ownership guide.

Review scope

This is the additive half of the rollout. The breaking default switch and first-party caller migration are reviewed separately.

Follow-up: #4198 switches the bare defaults and migrates callers.

@ibgreen ibgreen left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

One teardown issue behind the failing browser shards.

@ibgreen
ibgreen force-pushed the codex/resource-ownership-poc branch from cd27d50 to 0963cfe Compare December 4, 2026 11:01
@ibgreen
ibgreen changed the base branch from master to codex/resource-ownership-type-prep December 4, 2026 12:49
@ibgreen
ibgreen changed the base branch from codex/resource-ownership-type-prep to master December 4, 2026 12:55
@ibgreen ibgreen changed the title RFC/POC: borrow supplied GPU resources by default feat: support explicit resource ownership while preserving existing defaults Dec 4, 2026

This branch has not been deployed

No deployments
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.

1 participant