Field report (Seenko, 2026-09-01 diagnostics, RTX 4090, 4K@120 HDR AV1 500 Mbps): under a GPU-saturating game the stream collapses — ~25 fps delivered of a 60 fps game, client-reported encoder latency ~70 ms. Capping the game's fps restores a perfect stream; the same box streams fine under Sunshine.
Diagnosis
The diagnostics show feed-scheduling contention, the exact mechanism in punktfunk-planning/design/gpu-contention-investigation.md:
Observed source period collapsed to 34–42 ms — only ~24–29 fps of real frames reached the capture ring; the loss is upstream of NVENC (the ASIC sat near-idle).
Repeated encode behind cadence + IDD pipeline depth escalated 1→2 (GPU contention); the escalation's queue offset is most of the reported 70 ms.
Sunshine/OBS hold D3DKMT_SCHEDULINGPRIORITYCLASS_REALTIME, so their feed work preempts the game. Our 2026-08 downgrade to HIGH/off (after an RX 9070 XT A/B blamed REALTIME for the AMD metronomic capture stall) turned out not to be the AMD fix either — confirmed metronome cases kept arriving with the downgrade shipped, so that A/B recorded attenuation, not attribution.
Change
Host process class defaults to REALTIME (PUNKTFUNK_GPU_PRIORITY_CLASS, now off|normal|high|realtime). The auto gated-upgrade mode, HAGS probe, and VRAM monitor thread are deleted (−~300 lines).
vdisplay swap-chain REALTIME raise (IddCx IddCxSetRealtimeGPUPriority) defaults on; the PFVD_RT_GPU off/thread/realtime ladder is deleted. Opt-out PFVD_NO_RT_GPU remains and is now also read from the machine environment, so setx /M + a device restart applies without a reboot.
Stall-triage prose and docs no longer tell AMD boxes to clear the priority defaults first: display-stack suspects lead, the priority A/B is a last resort documented as masking.
Risks / expected behavior
The local game measurably loses fps under load when the host preempts it — by design; the remote view is the product.
REALTIME + NVIDIA + HAGS + near-full VRAM is a documented NVENC hang (Sunshine ships a downgrade path for it). PUNKTFUNK_GPU_PRIORITY_CLASS=high is the escape hatch; the removed VRAM auto-gate was the complexity we chose to drop.
Verified: rustfmt + check-writing clean, no dangling references repo-wide. Windows compile is CI-gated (cross-check from macOS fails on a cmake/MSVC dep before reaching our code).
## Symptom
Field report (Seenko, 2026-09-01 diagnostics, RTX 4090, 4K@120 HDR AV1 500 Mbps): under a GPU-saturating game the stream collapses — ~25 fps delivered of a 60 fps game, client-reported encoder latency ~70 ms. Capping the game's fps restores a perfect stream; the same box streams fine under Sunshine.
## Diagnosis
The diagnostics show feed-scheduling contention, the exact mechanism in `punktfunk-planning/design/gpu-contention-investigation.md`:
- Observed source period collapsed to 34–42 ms — only ~24–29 fps of real frames reached the capture ring; the loss is upstream of NVENC (the ASIC sat near-idle).
- Repeated `encode behind cadence` + `IDD pipeline depth escalated 1→2 (GPU contention)`; the escalation's queue offset is most of the reported 70 ms.
- `GPU-priority posture … rt_gpu_driver=off (default) rt_gpu_host=high (default)` — neither REALTIME lever engaged.
Sunshine/OBS hold `D3DKMT_SCHEDULINGPRIORITYCLASS_REALTIME`, so their feed work preempts the game. Our 2026-08 downgrade to HIGH/off (after an RX 9070 XT A/B blamed REALTIME for the AMD metronomic capture stall) turned out not to be the AMD fix either — confirmed metronome cases kept arriving with the downgrade shipped, so that A/B recorded attenuation, not attribution.
## Change
- Host process class defaults to REALTIME (`PUNKTFUNK_GPU_PRIORITY_CLASS`, now `off|normal|high|realtime`). The `auto` gated-upgrade mode, HAGS probe, and VRAM monitor thread are deleted (−~300 lines).
- vdisplay swap-chain REALTIME raise (IddCx `IddCxSetRealtimeGPUPriority`) defaults on; the `PFVD_RT_GPU` off/thread/realtime ladder is deleted. Opt-out `PFVD_NO_RT_GPU` remains and is now also read from the machine environment, so `setx /M` + a device restart applies without a reboot.
- Stall-triage prose and docs no longer tell AMD boxes to clear the priority defaults first: display-stack suspects lead, the priority A/B is a last resort documented as masking.
## Risks / expected behavior
- The local game measurably loses fps under load when the host preempts it — by design; the remote view is the product.
- REALTIME + NVIDIA + HAGS + near-full VRAM is a documented NVENC hang (Sunshine ships a downgrade path for it). `PUNKTFUNK_GPU_PRIORITY_CLASS=high` is the escape hatch; the removed VRAM auto-gate was the complexity we chose to drop.
- Verified: rustfmt + check-writing clean, no dangling references repo-wide. Windows compile is CI-gated (cross-check from macOS fails on a cmake/MSVC dep before reaching our code).
Under a GPU-saturating game the stream collapsed: capture delivered
~25 fps of a 60 fps game and reported encode latency hit 70 ms while
NVENC sat near-idle. The HIGH/off defaults from the 2026-08 AMD stall
triage left every feed leg waiting behind the game's render queue, and
the AMD stall reports they were meant to fix kept coming.
Pin the host process class to REALTIME (the auto gate and its VRAM
monitor are removed) and re-enable the vdisplay swap-chain REALTIME
raise by default (the PFVD_RT_GPU ladder is removed; PFVD_NO_RT_GPU is
now also read from the machine env so the opt-out applies without a
reboot). Downgrades stay one knob per layer for the AMD metronome A/B.
Confirmed metronomic-stall cases kept arriving after the 2026-08
priority downgrade shipped, so the A/B that blamed REALTIME recorded
attenuation, not attribution. Stop telling AMD triage to clear the
priority defaults first; the display-stack suspects lead again and the
priority A/B is a last resort that masks at most.
The Rust 1.96 clippy image denies the manual zero-check-then-divide
pattern (manual_checked_ops) under -D warnings, so the arm64 clippy
lane fails on main and on every PR branched from it.
The knob shipped in #485 neither documented in docs-site nor added to
the undocumented-env baseline, so the docs-drift ratchet fails every
PR. Document it: it is a user-facing escape hatch, not an internal
knob.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Symptom
Field report (Seenko, 2026-09-01 diagnostics, RTX 4090, 4K@120 HDR AV1 500 Mbps): under a GPU-saturating game the stream collapses — ~25 fps delivered of a 60 fps game, client-reported encoder latency ~70 ms. Capping the game's fps restores a perfect stream; the same box streams fine under Sunshine.
Diagnosis
The diagnostics show feed-scheduling contention, the exact mechanism in
punktfunk-planning/design/gpu-contention-investigation.md:encode behind cadence+IDD pipeline depth escalated 1→2 (GPU contention); the escalation's queue offset is most of the reported 70 ms.GPU-priority posture … rt_gpu_driver=off (default) rt_gpu_host=high (default)— neither REALTIME lever engaged.Sunshine/OBS hold
D3DKMT_SCHEDULINGPRIORITYCLASS_REALTIME, so their feed work preempts the game. Our 2026-08 downgrade to HIGH/off (after an RX 9070 XT A/B blamed REALTIME for the AMD metronomic capture stall) turned out not to be the AMD fix either — confirmed metronome cases kept arriving with the downgrade shipped, so that A/B recorded attenuation, not attribution.Change
PUNKTFUNK_GPU_PRIORITY_CLASS, nowoff|normal|high|realtime). Theautogated-upgrade mode, HAGS probe, and VRAM monitor thread are deleted (−~300 lines).IddCxSetRealtimeGPUPriority) defaults on; thePFVD_RT_GPUoff/thread/realtime ladder is deleted. Opt-outPFVD_NO_RT_GPUremains and is now also read from the machine environment, sosetx /M+ a device restart applies without a reboot.Risks / expected behavior
PUNKTFUNK_GPU_PRIORITY_CLASS=highis the escape hatch; the removed VRAM auto-gate was the complexity we chose to drop.