Add opt-in tracing for audio voice submissions and completions #1044
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1046"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from fxceless/victory-fork. Originally posted by superboynick on 2026-11-25T17:26:31Z.
Listening tells you something is wrong with audio but not which of three states you are in: a fragment being replayed, a feed that stopped, or completions reported too early. This adds an opt-in trace that separates them.
Per voice and per submission it records the submitted byte count, the pending compressed bytes and active buffer count on the submission path, the read and write positions, a hash over the first 64 bytes of the submission, and whether completion was reported immediately or deferred. Two submissions with the same byte count and hash point at a replay; a submission counter that stops while the queue drains points at a starved feed.
The first version of this reported the per-voice playback counters, which are only advanced by the write-ring path and read zero on the coprocessor command path this title uses. The trace now reports the queue state that path actually maintains.
Rate limited to four lines per voice per second, with a dropped-line count every five seconds. Off by default: with
VICTORY_TRACE_AUDIOunset nothing is timed, hashed or printed, and the audio code path is unchanged.Verified on local runs with audio active: several thousand trace lines, none containing buffer contents (the hash covers 64 bytes only), with non-zero queue depth visible in the output. A run without the switch emits no trace lines.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.