Interaction v2: zero-copy GPU surface transfer bridge (Skyline.Interaction.Gpu)#35
Open
codymullins wants to merge 1 commit into
Open
Interaction v2: zero-copy GPU surface transfer bridge (Skyline.Interaction.Gpu)#35codymullins wants to merge 1 commit into
codymullins wants to merge 1 commit into
Conversation
Add Skyline.Interaction.Gpu: a wgpu-handle transfer representation so a surface copy moves by reference and never round-trips through the processor. - GpuSurfaceHandle (texture handle + format + size), GpuTransferOffer, and IGpuTransferBroker / InProcessGpuTransferBroker. - Reuses the interaction tier's Provenance, TransferPolicy, and local/remote rules, so a surface transfer answers the same who / how-far / how-long questions a text transfer does. - The new assembly is wired into the 100% coverage gate (slnx and cover.sh), and reports 100%. Closes #23
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #23.
The interaction tier's transfer broker is text/metadata only — copying a GPU surface (canvas, composited page) would force a CPU round-trip, which the design forbids. This adds the v2 GPU bridge so a surface moves by reference.
What's new —
Skyline.Interaction.Gpu(a new, optional project)GpuSurfaceHandle— a wgpu texture handle plus format and dimensions. The source owns the texture and keeps it alive for the life of the offer; the taker binds or copies it before the offer expires or is revoked. The handle never touches the processor.GpuTransferOffer— the GPU twin ofTransferOffer, carrying the sameProvenanceandTransferPolicyfromSkyline.Interaction.IGpuTransferBroker/InProcessGpuTransferBroker— offer / take / revoke / list, with the same lifetime and local-vs-remote rules as the text broker (remote takers are denied a local-only offer; lapsed offers prune against an injectedTimeProvider).Depends on
Skyline.Interaction+Skyline.Gpu. No window dependency, so it stays headless-testable.Tests + coverage wiring
Skyline.Interaction.Gpu.Tests(headless MSTest, 7 tests) covers every broker branch: offer/list/take, unknown id, remote-denied, remote-allowed, revoke (twice), and expiry-prune-vs-survive.Skyline.slnxand added totools/cover.sh's reportgenerator-assemblyfilters. Verified it's actually measured: the report now showsAssemblies: 6(was 5) withSkyline.Interaction.Gpuat 100% — not a silent false-green.Verification
dotnet build Skyline.slnxclean (0 warnings); headless tests pass;format-check.shclean.main.Note
Fully isolated (new project + slnx + cover.sh) — no conflict with the open window/input PRs (#30/#31/#32/#34) or #33.