Skip to content

feat(io2c): primary-clock ASRC-to-ChannelId reader and stable device-map leases - #825

Open
masarray wants to merge 67 commits into
mainfrom
feat/io2c-primary-clock-capture-consumer-20261119
Open

masarray wants to merge 67 commits into
mainfrom
feat/io2c-primary-clock-capture-consumer-20261119

Conversation

@masarray

@masarray masarray commented Nov 19, 2026 •

Copy link
Copy Markdown
Owner

IO-2D milestone — 20 Nov 2026: exact HEAD e2d1df477f35a9e453278c5adcb1797167f2e10f, based on main@07e5f65fbe69bcfe1c5768bf0528bfed631b2ccd (including G-MV and N-MOD #828). Fast Native, M1–M2, logical-roster PASS; exact-head Codex review CLEAN and all comments resolved. Previous Windows #44624145756 yielded 105/105 CTest PASS, but latest commit requires exact-head Windows #44647270460 now IN PROGRESS; protected Required CI Merge Gate PENDING. OPEN, NOT MERGED. Added non-destructive same-driver primary ASIO restart preserving ChannelId/WIRE/FX while B PCM becomes silent NEEDS_REMAP, second restart recovery, immutable Device B assignment subset on SOURCE NONE/Delete Track, qualified A-only .smix restore, hardware callback frame chunking (512 hardware/256 graph), fail-closed B registration and lease. Synthetic CTest does not prove physical two-vendor ASIO; GUI Device B picker, IO-5 .smix persistence, sink and physical FAT remain NOT DONE. Do not bypass protected gate.

Actual native implementation (not only fixtures)

  • QualifiedSecondaryCaptureReader consumes the already merged IO-1 SPSC/ASRC at the exact primary callback clock. A/B generation, deviceLease, primary epoch and frame bounds are checked. Secondary loss yields silent B slots while A passes; zero RT allocation, lock, driver open or FX invocation.
  • DynamicNativeSessionPublisher preserves the qualified map inside the SAME accepted ChannelId PCM/VST3 snapshot across internal WIRE and FX-only revisions. Unqualified SOURCE ordinal edits, stale B leases and map replacement with armed output fail closed.
  • LiveDryRoutingLab::process is the existing sole JUCE PCM render host: default A-only path unchanged; when the verified B reader and clock are both present it calls the same native renderer once with qualified A+B blocks. A partial pair is denied. Actual JUCE callback A count is never confused with virtual A+B count.
  • LiveDryRoutingLab::installQualifiedSecondaryInput is the CONTROL-only atomic graph/FX admission gate; QualifiedCaptureAdmission checks the real primary pin count, B lease/generation/clock and bounded frame size. Rejects without replacing existing accepted PCM.
  • LiveAudioEngine::installSecondaryAsioCapture adds opt-in real B ASIO capture-only open and readback validation from separate attested driver class, explicit physical pin mask and rate/period. It prepares per-ChannelId A/B physical source choices then publishes exactly one native session. The callback gates admission on one acquire of qualifiedSecondaryInstalled_. The default-OFF primary ASIO fast path adds no FIFO or SRC. A device hotplug/stop invalidates stale clock and disconnect B keeps installed A graph while B inputs mute.
  • Portable negative tests for stale epoch/device lease, partial host resource admission, primary-count confusion, 44.1k B -> 48k A ASRC -> ChannelId + BUS/WIRE/MAIN once, loss and FX map revisions.

Explicit unshipped work: no registered GUI/native requestId ADD/REMOVE/ASSIGN transaction or accepted ACK+readback for the new host API; no schema-v6 source picker or durable .smix physical intended identity/NEEDS_REMAP; no independent BUS/CH output sink and no attended dual-vendor hardware FAT. Until those are implemented and qualified, this PR must not be described as an installer-ready multi-device feature. Keep main one PCM/FX authority and no ASIO speaker fallback.

Current required checks: exact HEAD Fast Native + Logical Mixer (auto); one owner-dispatched exact-head Windows MSVC/CTest when fast tests are GREEN; Codex exact-head review, required CI Merge Gate SUCCESS, then squash only if clean. Canonical /preview/ not altered. Coordination #812.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 19, 2026 •

Copy link
Copy Markdown

Deploying arsonmix with  Cloudflare Pages  Cloudflare Pages

Latest commit: e071e16
Status: ✅  Deploy successful!
Preview URL: https://78d11767.arsonmix.pages.dev
Branch Preview URL: https://feat-io2c-primary-clock-capt.arsonmix.pages.dev

View logs

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native 5cb7bc7

Copy link
Copy Markdown
Owner Author

@codex review

Please re-review current exact HEAD 5cb7bc770a67fb96f6531613ed4709eec2488fa4, especially cross-epoch A+B qualified map retirement (Re­altimeRoutePublisher::controlOwnedEpoch, DynamicNativeSessionPublisher::commit and verifyQualifiedMapCrossEpochReplacement). This is a follow-up to the new P2 review thread; earlier e2d1df477f review does not cover the new fix. Windows exact-head CTest has been dispatched; do not equate it with physical dual-ASIO FAT.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5cb7bc770a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Owner Author

INT-1 I/O safety-critical handoff: #837
At last audit Codex marked exact HEAD 5cb7bc7 with a P1 primary-restart regression: retained qualified A+B map rejected during explicit A-only recovery because replaceQualifiedWithPrimaryOnly is not propagated through the retained rebind path; mixer can stay muted after primary restart. Reproduce/fix with a negative regression: B map retiring only on explicit verified disarmed primary-only fallback; old epoch/revision safety remains fail-closed; no output auto-arm or second renderer. Re-review fresh HEAD, run exact-head Windows CTest and protected gate, then merge #825 only if green; hand off merged main SHA to child #830. Not proof of two-vendor hardware compatibility or shipped dual-ASIO. Keep user-testable single-ASIO baseline unblocked.

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. What shall we delve into next?

Reviewed commit: 1b80519874

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native bea8842

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: bea88420d1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native 74e4c80

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 74e4c80d9a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/LiveAudioEngine.h Resolved

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native e071e16

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: e071e16e71

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

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