Skip to content

M2: Optimize real-time compressor DSP, sparse ramps and no-GR fast path with deadline stress tests - #3

Merged
masarray merged 2 commits into
mainfrom
perf/realtime-deadline-audit
Oct 31, 2026
Merged

masarray merged 2 commits into
mainfrom
perf/realtime-deadline-audit

Conversation

@masarray

@masarray masarray commented Oct 31, 2026 •

Copy link
Copy Markdown
Owner

M2 — Real-Time CPU Work Reduction / Ready-To-Test Windows

Engineering milestone passed on 2026-10-31. This is a testable VST3/Standalone baseline, NOT a confirmed fix for user-reported physical dropouts, memory leaks, or FabFilter sonic parity.

Changes merged in this milestone

  • Sparse ramp scheduling: immutable active-index array and canonical smoothed-value array; each audio sample updates only parameters with an ongoing ramp. The 19-param scan happens once per host buffer. All current parameter IDs, APVTS and preset state remain compatible.
  • Below-knee short circuit: preconvert the lower knee boundary to linear only when threshold and knee are stationary; definitely sub-knee detector levels skip log10 and static gain computation, with a float guard. During threshold/knee automation the original exact path remains.
  • Unity gain shortcut: no exp(0) when reduction is exactly zero. Original exp remains for actual compression; no unsafe approximate LUT.
  • No new worker, latency, locking or heap use in DSP. Input, output, RMS/Peak, three styles, stereo sidechain, bypass and GUI functionality are preserved.
  • Regression: exact sub-knee passthrough across 44.1/48/96/192 kHz, all three models and detector modes; automation+block-partition equivalence; 8-instance 32/64/128 short-buffer processing remains finite and allocation-free. Existing engine and JUCE bus/editor tests remain enabled.
  • Pro-grade reference direction: compare causal DSP behavior and program-dependent styles with official Pro-C 3 docs; keep zero-added-sample live mode, and do not infer proprietary algorithms.

Verified CI and actual artifact

  • Code SHA 2e696c5559ac9701d8ce305b8fe20bc190c3f2cf.
  • Windows/Linux Actions #41208101260: both jobs SUCCESS, including Windows Release VST3/Standalone, state/editor smoke, engine tests, Linux sanitizer/engine-safety and offline multi-instance benchmark.
  • GitHub Actions synthetic merge-test commit 4cd27a16b2fbc4ce3a8d8f99ba5a277bf50e5c1e has parents exactly 506c35e8 and 2e696c55, so the delivered build indeed contains this PR.
  • Windows artifact #13045466965 (VST3 complete bundle, Standalone EXE, screenshots full/minimum/sidechain/MINI, benchmark, realtime-stress, SHA256SUMS).
  • Artifact zip SHA256: 6279fea7fbe79b1b07c89e2a13779902a8ab69a8069aab71c932b7db30f9a45c, archive CRC PASS, VST3 binary/module metadata/Standalone exe all match SHA256SUMS, actual full 780×640 screenshot visually examined.

Measured CI benchmark (one pair of separate Windows hosted runner runs; NOT repeatable hardware proof)

27 exact scenario-pairs across Clean/Peak, Smooth/RMS/SC, and RMS automation × 32/64/128 frames × 1/8/24 instances:

  • 24/27 show lower mean time and 23/27 show lower P99 in this one comparison; some scenarios regress or are noisy.
  • Clean/Peak, 24 instances, 32 frames: mean 108.42 → 74.06 μs (31.7% lower), P99 175.3 → 106.6 μs (39.2% lower).
  • Smooth/RMS/external SC, 24 instances, 64 frames: mean 198.69 → 184.75 μs (7.0% lower), P99 293.9 → 213.4 μs (27.4% lower).
  • Separate runners / clock / scheduler / DPC variation preclude a universal speed-up claim. Actual host callback deadlines and audible dropouts remain unknown.

Mandatory physical validation / follow-up

User can immediately test Standalone / VST3 on actual Windows device. Compare previous (CI #41205740765) versus this build in the same DAW/driver and same hardware. Test 48 kHz, 128 then 64 then 32 samples, 1/8/16 instances; run 30–60 minutes while recording host xrun/dropout counters, driver, DPC spikes, GUI closed/open, bypass, mono/stereo sidechain, preset/automation save-reload and audible fast attack/release artifacts. Without this, never claim zero dropouts or no memory leaks.

Run pluginval and a second independent VST3 host, sustained multi-instance/editor lifecycle leak diagnostics and loudness-matched Pro-C 3-style listening/meter comparisons before a production release.

See RT reliability plan. Merge into main records an engineering testing baseline only; no production tag or release.

@masarray masarray changed the title Audit ArSonComp real-time dropout: deadline stress benchmark and Pro-C-class DSP strategy M2: Optimize real-time compressor DSP, sparse ramps and no-GR fast path with deadline stress tests Oct 31, 2026
@masarray
masarray marked this pull request as ready for review October 31, 2026 14:13
@masarray
masarray merged commit 5493e4b into main Oct 31, 2026
2 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-31T14:14:01.892352Z 2e696c5 Draft marked ready
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

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