Frame pacing: VICTORY_FRAME_PACE=auto|<ms> evens out long/short frame pairs, with the wait at our present to the host (VICTORY_PACE_AT_PRESENT=1); the frame meter's report off the presenting thread #3851

Closed
duckey-dev wants to merge 2 commits from upstream-pr/3851 into main
duckey-dev commented 2026-11-30 09:19:15 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by duckey-dev on 2026-11-30T09:19:15Z.


Update, 30 Nov (rebased onto main c71899d). Where the text below differs, this note holds.

  • Where the wait sits with VICTORY_PACE_AT_PRESENT=1: just before main's hand-off of the present. With main's own presenter or the present put aside to another thread, that is before the hand-off, not literally at swap_chain.Present, which then happens on that other thread.
  • The meter's report on its own thread now also carries the lines main added since (the hardware ray tracing line of #3706, the placement ledger, the small-levels and memo lines). They read only statics and the frame count, so nothing new had to be handed across.
  • Measured again on current main (c71899d plus this and other changes of ours, same machine and walk, fixed 33.3 ms at our present): 29.7 fps, 95 % of frames at or under 34.3 ms, 0.3 % over 50 ms, none over 100 ms.
  • Checks on the rebased branch: both of CI's clippy runs add no warning over main, and cargo test --workspace has no failure that main does not have on this machine.

The problem

On an RX 7900 XTX at native 1440p (ray tracing off), a walk in the open world keeps about 28 frames a second, but the frames do not come evenly. They come in long/short pairs, 56 ms and then 15 ms. The median difference between two neighbouring frames is 21 ms, and 20 % of frames are over 50 ms. The average is close to 30, but what you see is closer to 18 fps with an extra frame squeezed in.

How it happens: a heavier frame lets the card fall behind. The limit on host lists in flight (VICTORY_LATE_WAIT_LISTS) then stops the submitting thread, so that present is late. Meanwhile the card drains. The next frame is already made, so it goes out at once.

The frame clock in frame.rs does not prevent this at these rates. Its ticks are absolute (start plus whole intervals of the title's 33.3 ms). A wait whose tick has already passed ends at once. Once frames take longer than the interval, the title is always behind the clock, every wait ends at once, and nothing is paced.

A second, smaller cause of uneven frames: once a second the frame meter builds its report (frame-time lines, budget, the 5-second counters) on the thread that presents. A timeline capture showed that block holding the submitting thread for 33 ms.

What it changes

1. Frame pacing (crates/victory-gpu/src/pacer.rs, new; hooks in queue.rs and host.rs). Off unless VICTORY_FRAME_PACE is set.

  • Rule: in the world, a present is not let go before the previous present's release plus a target. A present that is already past that goes at once, and the next one counts from it. Nothing is caught up, so a long frame is not followed by a burst of short ones.
  • "In the world" means world_since() is set and frames have 500 draws or more (8 frames in a row under that turn pacing off). Menus, movies and loading screens are not paced.
  • VICTORY_FRAME_PACE=<ms>: a fixed target, 1 to 1000 ms.
  • VICTORY_FRAME_PACE=auto: the first target comes from the intervals between our presents to the host, less the wait the pacer itself added. It is a high quantile of neighbour means, so a 60/18 alternation reads as 39 ms, plus 5 %. From then on the share of late presents steers it, looking at the last 32 presents once every 16: three or more late raise the target 3 %, none late lowers it 1 %, and after four looks in a row with none late it comes down 3 % a look. The target stays between 8 and 60 ms.
  • Where the wait happens:
    • by default, on the title's thread in its Present (queue.rs), before the present goes to the line or the host;
    • with VICTORY_PACE_AT_PRESENT=1, the title's present only notes its turn and goes on. The thread that presents to the host waits just before the swap chain's Present (host.rs). The frame's copy has already been sent, so the card keeps working, and the next frame's lists are submitted during the wait. This is the measured setup. With the wait on the title's thread, a capture showed that thread asleep about 27 ms a frame while the next frame's lists sat unsubmitted, and the card idle 15 to 20 ms every other frame.
  • VICTORY_PACE_SLACK=<share> (0 to 2, default 0.2, only with VICTORY_PACE_AT_PRESENT=1): how far past its turn a present may be, as a share of the target, before auto counts it as late. Frames a few ms past their turn do not show. Counting them as late kept auto 4 to 8 ms above what the walk sustains.
  • A log line every 5 seconds gives the target, the number of presents held back and for how long, the late ones, and the unpaced ones.
  • With DLSS or FSR 3 frame generation, the rendered frames pass the same Present, so they are paced before their markers. The generated frames in between are spaced by the frame-generation runtime, not by this.

2. The frame meter's report off the presenting thread (host.rs, VICTORY_METER_OFF_THREAD, on unless 0). The presenting thread takes only the meter's own figures: intervals, the present budget's window, frame and draw counts, and the 5-second counts. It hands them to a victory-meter thread, which reads the other modules' counters and writes the lines. The window caption is still set from the presenting thread, as before. 0 keeps the report on the presenting thread, as before. The lines and their contents are unchanged. Counters read off the thread may count a moment longer into one report and the same amount shorter into the next.

Switch Default Effect
VICTORY_FRAME_PACE unset (off) auto, or a target in ms
VICTORY_PACE_AT_PRESENT unset (off) 1: wait at our present to the host, not on the title's thread
VICTORY_PACE_SLACK 0.2 share of the target a present may be late before auto counts it
VICTORY_METER_OFF_THREAD on 0: report on the presenting thread, as before

Pacing is off by default. Turning it on lowers the average frame rate, for even frames (see below).

How it was tested

  • GPU and profile: RX 7900 XTX, Ryzen 7 7800X3D, Windows 11, Series X, native 2560x1440, no DLSS/FSR, frame generation off, ray tracing off. A scripted 4-minute walk in the open world, counting frames after the first 75 s. Other tuned switches were on in every row.
fps median difference between neighbouring frames frames over 50 ms over 100 ms
Before: no pacing 27.9 21 ms (pairs of 56 and 15 ms) 20 %
After: auto + VICTORY_PACE_AT_PRESENT=1 25.7 to 26.8 0.3 to 1.8 ms 2 to 8.6 % none
After: fixed 34.5 ms at our present 28.0 about 1 ms 0.7 %
  • The fixed target that suits this machine and route keeps the average and makes the frames even. auto gives up 1 to 2 fps against it. Its target sometimes wanders up for a stretch, for example after a burst of streaming, and that is where its frames over 50 ms come from.
  • Meter: the 33 ms stall is from a timeline capture. The fps effect of the meter change by itself was not measured separately.
  • Limits: one machine, one route, one resolution. These are not general numbers.
  • cargo test passed for the crates it touches: no failure that main does not have on this machine (13 pacer tests pass). Both of CI's clippy runs add no warning over main.

Not tested

  • In the game on this exact branch. It brings the measured commits over to current main by hand: the final state of the pacer plus its hooks, and the meter commit. It was built and checked with CI's commands on Windows, but the game runs behind the numbers were on a branch that also held other open pull requests. The hook sites and the meter's report body are the same on main as there.
  • NVIDIA, Intel: not run. The pacer is vendor-neutral and off unless set. It does not know about Reflex (VICTORY_REFLEX, #3072, or the Reflex that frame generation turns on). With both on, two things would pace.
  • Frame generation (DLSS FG, FSR 3): not run with pacing on.
  • Variable refresh, fixed-refresh displays: not checked. The pacer counts time and does not align to vblank. On a fixed 60 Hz display with V-sync, a 34 to 38 ms target does not fall on whole refreshes (see #2201).
  • Present paths from open PRs (#1988's present queue, #2346's present thread): not combined with this.
  • Linux/Wine: not run.

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches.

  • #2201 (stacked on #1988): "Present queue: VICTORY_PACE shows every frame for the same number of refreshes". This is the closest one. It paces on #1988's present thread in whole display refreshes (vblank waits through the output), with auto choosing the count by the share of late frames. That steering idea is the same as ours. Assessment: for a fixed-refresh display without VRR, theirs is better: a frame held for exactly n refreshes is what a V-synced display can show evenly, and ours does not align to refreshes. Ours is better where theirs does not reach: it needs #1988's present queue (a second queue and a stand-in copy, motivated by an NVIDIA driver behaviour), it is left out with frame generation, and its steps are whole refreshes (at 60 Hz, 33.3 or 50 ms; ours sustains 34.5 ms here). Ours works on the default present path, at any target, with or without VRR. They can live together, but not both on at once. If both land, ours should step aside when VICTORY_PACE is set. The names also share a prefix (VICTORY_PACE against VICTORY_PACE_AT_PRESENT / VICTORY_PACE_SLACK), and one side could rename.

  • #1988: the swap chain on a queue of its own (VICTORY_PRESENT_QUEUE=1). It replaces the Present call that our before_host_present hook sits before with a handover to its own thread. With both, our wait would happen on the submitting thread before the handover. That still paces, but it would belong on its present thread. The text conflict is next to our hook.

  • #2346: the present on a thread of its own (VICTORY_PRESENT_THREAD). It rewrites the same lines as our two host.rs hooks. The text conflicts are small. In meaning it is the same question as #1988: with it, the pacer's wait should move into its present job.

  • #2077: the frame clock keeps the title's 30 for videos and menus (VICTORY_FRAME_INTERVAL_DRAWS). It changes when the title's frames begin (frame.rs). Ours changes when finished frames are let go, and does not touch frame.rs. Complementary; both use the same 500-draw line for "in the world".

  • #3072: NVIDIA Reflex low latency without frame generation (VICTORY_REFLEX). Reflex's sleep paces the title's frames, on NVIDIA only. It adds markers next to our queue.rs hook (a small text conflict). Turning both on would mean two pacers.

  • #1938, #2371: pacing inside frame-generation runtimes. No code overlap.

  • #1357 (with #1360, #1363): the base-frame pace guard for frame generation (streamline/pace.rs). Despite the name, it decides whether frame generation runs, not when frames go. No overlap.

  • #2783: takes the 5-second VirtualQuery walk off in release builds. Related to the meter change only in symptom: that walk already runs on a thread of its own, and this PR moves the rest of the report.

  • Many open PRs add lines to the meter's report body (for example #3074, #3650, #3703, #3617). They merge as text, since the body stays where it is. But a line added there that reads a Meter field through self. has to take its figure into MeterReport instead. None of the open ones checked does this.

🤖 Generated with Claude Code

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5562418203 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3851). Originally posted by [duckey-dev](https://github.com/duckey-dev) on 2026-11-30T09:19:15Z. --- > **Update, 30 Nov (rebased onto main c71899d).** Where the text below differs, this note holds. > - **Where the wait sits with `VICTORY_PACE_AT_PRESENT=1`:** just before main's hand-off of the present. With main's own presenter or the present put aside to another thread, that is before the hand-off, not literally at `swap_chain.Present`, which then happens on that other thread. > - **The meter's report on its own thread** now also carries the lines main added since (the hardware ray tracing line of #3706, the placement ledger, the small-levels and memo lines). They read only statics and the frame count, so nothing new had to be handed across. > - **Measured again on current main** (c71899d plus this and other changes of ours, same machine and walk, fixed 33.3 ms at our present): 29.7 fps, 95 % of frames at or under 34.3 ms, 0.3 % over 50 ms, none over 100 ms. > - Checks on the rebased branch: both of CI's clippy runs add no warning over main, and `cargo test --workspace` has no failure that main does not have on this machine. ## The problem On an RX 7900 XTX at native 1440p (ray tracing off), a walk in the open world keeps about 28 frames a second, but the frames do not come evenly. They come in long/short pairs, 56 ms and then 15 ms. The median difference between two neighbouring frames is 21 ms, and 20 % of frames are over 50 ms. The average is close to 30, but what you see is closer to 18 fps with an extra frame squeezed in. How it happens: a heavier frame lets the card fall behind. The limit on host lists in flight (`VICTORY_LATE_WAIT_LISTS`) then stops the submitting thread, so that present is late. Meanwhile the card drains. The next frame is already made, so it goes out at once. The frame clock in `frame.rs` does not prevent this at these rates. Its ticks are absolute (start plus whole intervals of the title's 33.3 ms). A wait whose tick has already passed ends at once. Once frames take longer than the interval, the title is always behind the clock, every wait ends at once, and nothing is paced. A second, smaller cause of uneven frames: once a second the frame meter builds its report (frame-time lines, budget, the 5-second counters) on the thread that presents. A timeline capture showed that block holding the submitting thread for 33 ms. ## What it changes **1. Frame pacing** (`crates/victory-gpu/src/pacer.rs`, new; hooks in `queue.rs` and `host.rs`). Off unless `VICTORY_FRAME_PACE` is set. - Rule: in the world, a present is not let go before the previous present's release plus a target. A present that is already past that goes at once, and the next one counts from it. Nothing is caught up, so a long frame is not followed by a burst of short ones. - "In the world" means `world_since()` is set and frames have 500 draws or more (8 frames in a row under that turn pacing off). Menus, movies and loading screens are not paced. - `VICTORY_FRAME_PACE=<ms>`: a fixed target, 1 to 1000 ms. - `VICTORY_FRAME_PACE=auto`: the first target comes from the intervals between our presents to the host, less the wait the pacer itself added. It is a high quantile of neighbour means, so a 60/18 alternation reads as 39 ms, plus 5 %. From then on the share of late presents steers it, looking at the last 32 presents once every 16: three or more late raise the target 3 %, none late lowers it 1 %, and after four looks in a row with none late it comes down 3 % a look. The target stays between 8 and 60 ms. - Where the wait happens: - by default, on the title's thread in its Present (`queue.rs`), before the present goes to the line or the host; - with `VICTORY_PACE_AT_PRESENT=1`, the title's present only notes its turn and goes on. The thread that presents to the host waits just before the swap chain's `Present` (`host.rs`). The frame's copy has already been sent, so the card keeps working, and the next frame's lists are submitted during the wait. This is the measured setup. With the wait on the title's thread, a capture showed that thread asleep about 27 ms a frame while the next frame's lists sat unsubmitted, and the card idle 15 to 20 ms every other frame. - `VICTORY_PACE_SLACK=<share>` (0 to 2, default 0.2, only with `VICTORY_PACE_AT_PRESENT=1`): how far past its turn a present may be, as a share of the target, before `auto` counts it as late. Frames a few ms past their turn do not show. Counting them as late kept `auto` 4 to 8 ms above what the walk sustains. - A log line every 5 seconds gives the target, the number of presents held back and for how long, the late ones, and the unpaced ones. - With DLSS or FSR 3 frame generation, the rendered frames pass the same `Present`, so they are paced before their markers. The generated frames in between are spaced by the frame-generation runtime, not by this. **2. The frame meter's report off the presenting thread** (`host.rs`, `VICTORY_METER_OFF_THREAD`, on unless `0`). The presenting thread takes only the meter's own figures: intervals, the present budget's window, frame and draw counts, and the 5-second counts. It hands them to a `victory-meter` thread, which reads the other modules' counters and writes the lines. The window caption is still set from the presenting thread, as before. `0` keeps the report on the presenting thread, as before. The lines and their contents are unchanged. Counters read off the thread may count a moment longer into one report and the same amount shorter into the next. | Switch | Default | Effect | |---|---|---| | `VICTORY_FRAME_PACE` | unset (off) | `auto`, or a target in ms | | `VICTORY_PACE_AT_PRESENT` | unset (off) | `1`: wait at our present to the host, not on the title's thread | | `VICTORY_PACE_SLACK` | 0.2 | share of the target a present may be late before `auto` counts it | | `VICTORY_METER_OFF_THREAD` | on | `0`: report on the presenting thread, as before | Pacing is off by default. Turning it on lowers the average frame rate, for even frames (see below). ## How it was tested - GPU and profile: RX 7900 XTX, Ryzen 7 7800X3D, Windows 11, Series X, native 2560x1440, no DLSS/FSR, frame generation off, ray tracing off. A scripted 4-minute walk in the open world, counting frames after the first 75 s. Other tuned switches were on in every row. | | fps | median difference between neighbouring frames | frames over 50 ms | over 100 ms | |---|---|---|---|---| | Before: no pacing | 27.9 | 21 ms (pairs of 56 and 15 ms) | 20 % | | | After: `auto` + `VICTORY_PACE_AT_PRESENT=1` | 25.7 to 26.8 | 0.3 to 1.8 ms | 2 to 8.6 % | none | | After: fixed 34.5 ms at our present | 28.0 | about 1 ms | 0.7 % | | - The fixed target that suits this machine and route keeps the average and makes the frames even. `auto` gives up 1 to 2 fps against it. Its target sometimes wanders up for a stretch, for example after a burst of streaming, and that is where its frames over 50 ms come from. - Meter: the 33 ms stall is from a timeline capture. The fps effect of the meter change by itself was not measured separately. - Limits: one machine, one route, one resolution. These are not general numbers. - `cargo test` passed for the crates it touches: no failure that main does not have on this machine (13 pacer tests pass). Both of CI's clippy runs add no warning over main. ## Not tested - **In the game on this exact branch.** It brings the measured commits over to current main by hand: the final state of the pacer plus its hooks, and the meter commit. It was built and checked with CI's commands on Windows, but the game runs behind the numbers were on a branch that also held other open pull requests. The hook sites and the meter's report body are the same on main as there. - **NVIDIA, Intel**: not run. The pacer is vendor-neutral and off unless set. It does not know about Reflex (`VICTORY_REFLEX`, #3072, or the Reflex that frame generation turns on). With both on, two things would pace. - **Frame generation** (DLSS FG, FSR 3): not run with pacing on. - **Variable refresh, fixed-refresh displays**: not checked. The pacer counts time and does not align to vblank. On a fixed 60 Hz display with V-sync, a 34 to 38 ms target does not fall on whole refreshes (see #2201). - Present paths from open PRs (#1988's present queue, #2346's present thread): not combined with this. - Linux/Wine: not run. ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. - **#2201** (stacked on #1988): "Present queue: VICTORY_PACE shows every frame for the same number of refreshes". This is the closest one. It paces on #1988's present thread in whole display refreshes (vblank waits through the output), with `auto` choosing the count by the share of late frames. That steering idea is the same as ours. Assessment: for a fixed-refresh display without VRR, theirs is better: a frame held for exactly n refreshes is what a V-synced display can show evenly, and ours does not align to refreshes. Ours is better where theirs does not reach: it needs #1988's present queue (a second queue and a stand-in copy, motivated by an NVIDIA driver behaviour), it is left out with frame generation, and its steps are whole refreshes (at 60 Hz, 33.3 or 50 ms; ours sustains 34.5 ms here). Ours works on the default present path, at any target, with or without VRR. They can live together, but not both on at once. If both land, ours should step aside when `VICTORY_PACE` is set. The names also share a prefix (`VICTORY_PACE` against `VICTORY_PACE_AT_PRESENT` / `VICTORY_PACE_SLACK`), and one side could rename. - **#1988**: the swap chain on a queue of its own (`VICTORY_PRESENT_QUEUE=1`). It replaces the `Present` call that our `before_host_present` hook sits before with a handover to its own thread. With both, our wait would happen on the submitting thread before the handover. That still paces, but it would belong on its present thread. The text conflict is next to our hook. - **#2346**: the present on a thread of its own (`VICTORY_PRESENT_THREAD`). It rewrites the same lines as our two `host.rs` hooks. The text conflicts are small. In meaning it is the same question as #1988: with it, the pacer's wait should move into its present job. - **#2077**: the frame clock keeps the title's 30 for videos and menus (`VICTORY_FRAME_INTERVAL_DRAWS`). It changes when the title's frames begin (`frame.rs`). Ours changes when finished frames are let go, and does not touch `frame.rs`. Complementary; both use the same 500-draw line for "in the world". - **#3072**: NVIDIA Reflex low latency without frame generation (`VICTORY_REFLEX`). Reflex's sleep paces the title's frames, on NVIDIA only. It adds markers next to our `queue.rs` hook (a small text conflict). Turning both on would mean two pacers. - **#1938**, **#2371**: pacing inside frame-generation runtimes. No code overlap. - **#1357** (with #1360, #1363): the base-frame pace guard for frame generation (`streamline/pace.rs`). Despite the name, it decides whether frame generation runs, not when frames go. No overlap. - **#2783**: takes the 5-second `VirtualQuery` walk off in release builds. Related to the meter change only in symptom: that walk already runs on a thread of its own, and this PR moves the rest of the report. - Many open PRs add lines to the meter's report body (for example #3074, #3650, #3703, #3617). They merge as text, since the body stays where it is. But a line added there that reads a `Meter` field through `self.` has to take its figure into `MeterReport` instead. None of the open ones checked does this. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
lewisenator commented 2026-12-01 00:52:29 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by lewisenator on 2026-12-01T00:52:29Z.


Tested under Proton on NVIDIA: the same long/short pairs are here, and this removes them.

Setup: Linux (CachyOS, kernel 7.3.6), GE-Proton11-15, RTX 3080 Ti 12 GB (driver 620.73.04), Ryzen 7 5800X, Series X profile, DLSS Quality at 2560x1440, no frame generation, VICTORY_VRAM_BUDGET_MB=8000. Build: main at e1251c31 plus this PR (and the one-line -HV 2018 of #3417, which Proton needs). Scene: the prison cell after the prologue, 115 s of scripted pad movement (the same tape every run), frame times from the diagnostics build's frame log. Runs interleaved, minutes apart.

fps over the window frames under 30 ms over 100 ms short-then-long pairs mean step frame to frame p99
off 18.3 32 % 6 % 469 of 2,271 48.0 ms 126 ms
off 18.1 32 % 6 % 503 of 2,252 48.0 ms 128 ms
VICTORY_FRAME_PACE=auto, VICTORY_PACE_AT_PRESENT=1 16.6 0 % 2 % 0 5.6 ms 116 ms
same 15.9 0 % 2 % 0 7.1 ms 118 ms

Off, a typical stretch reads 74, 52, 53, 75, 19, 96, 26, 85, 19, 103 ms; with it, 59, 60, 59, 60, 59, 60. The pacer's own line agrees: target 54-59 ms, 75-89 presents held in 5 s, at most 44 ms.

So on this machine it evens the frames out completely for about 1.9 fps (10 %).

Two things from here that bear on the cause described above:

  • VICTORY_LATE_WAIT_LISTS=512 and 1024 (on main at 41adb551): the stops for lists in the air went to zero, the frame rate did not move. I did not look at the pairs in those runs.
  • VICTORY_SUBMIT_FRAMES=0 made the pairs sharper (36 % of frames under 30 ms), and VICTORY_FRAME_INTERVAL_US=58000 left them as they were; in a timeline the title's own Present calls already alternate (53/80, 54/89 ms).

Not tested: with frame generation; a fixed target in ms; cargo test.

Merge note: on today's main (7d93ee07) this conflicts with #2910 in one place in host.rs (each adds a report line, crate::cardmem::line() and crate::pacer::line()); keeping both lines resolves it. With that, this PR's commits on 7d93ee07 together with #2910 and a dozen other open PRs build and ran twice here with the same result (16.5 and 16.0 fps over the window, no pairs, mean step 6.4 and 6.9 ms).

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7296838678 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3851#issuecomment-7296838678). Originally posted by [lewisenator](https://github.com/lewisenator) on 2026-12-01T00:52:29Z. --- Tested under Proton on NVIDIA: the same long/short pairs are here, and this removes them. **Setup:** Linux (CachyOS, kernel 7.3.6), GE-Proton11-15, RTX 3080 Ti 12 GB (driver 620.73.04), Ryzen 7 5800X, Series X profile, DLSS Quality at 2560x1440, no frame generation, `VICTORY_VRAM_BUDGET_MB=8000`. Build: main at e1251c31 plus this PR (and the one-line `-HV 2018` of #3417, which Proton needs). Scene: the prison cell after the prologue, 115 s of scripted pad movement (the same tape every run), frame times from the diagnostics build's frame log. Runs interleaved, minutes apart. | | fps over the window | frames under 30 ms | over 100 ms | short-then-long pairs | mean step frame to frame | p99 | |---|---|---|---|---|---|---| | off | 18.3 | 32 % | 6 % | 469 of 2,271 | 48.0 ms | 126 ms | | off | 18.1 | 32 % | 6 % | 503 of 2,252 | 48.0 ms | 128 ms | | `VICTORY_FRAME_PACE=auto`, `VICTORY_PACE_AT_PRESENT=1` | 16.6 | 0 % | 2 % | 0 | 5.6 ms | 116 ms | | same | 15.9 | 0 % | 2 % | 0 | 7.1 ms | 118 ms | Off, a typical stretch reads 74, 52, 53, 75, 19, 96, 26, 85, 19, 103 ms; with it, 59, 60, 59, 60, 59, 60. The pacer's own line agrees: target 54-59 ms, 75-89 presents held in 5 s, at most 44 ms. So on this machine it evens the frames out completely for about 1.9 fps (10 %). Two things from here that bear on the cause described above: - `VICTORY_LATE_WAIT_LISTS=512` and `1024` (on main at 41adb551): the stops for lists in the air went to zero, the frame rate did not move. I did not look at the pairs in those runs. - `VICTORY_SUBMIT_FRAMES=0` made the pairs sharper (36 % of frames under 30 ms), and `VICTORY_FRAME_INTERVAL_US=58000` left them as they were; in a timeline the title's own Present calls already alternate (53/80, 54/89 ms). Not tested: with frame generation; a fixed target in ms; `cargo test`. Merge note: on today's main (7d93ee07) this conflicts with #2910 in one place in `host.rs` (each adds a report line, `crate::cardmem::line()` and `crate::pacer::line()`); keeping both lines resolves it. With that, this PR's commits on 7d93ee07 together with #2910 and a dozen other open PRs build and ran twice here with the same result (16.5 and 16.0 fps over the window, no pairs, mean step 6.4 and 6.9 ms).
duckey-dev commented 2026-12-01 15:38:54 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by duckey-dev on 2026-12-01T15:38:54Z.


@lewisenator Thank you, this is the measurement the PR lacked: another vendor, another OS, alternating runs. Your note that the title's own Present calls already alternate fits something we measured since. The title's present job waits on a two-slot ring until the previous frame's sync value is reached, so it keeps one frame outstanding, and when our pipeline needs more than one interval the waits fall into long and short pairs. The pacer evens out what that gate produces; it doesn't remove the gate. I'll resolve the conflict with #2910 by keeping both report lines when I rebase.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7316270507 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3851#issuecomment-7316270507). Originally posted by [duckey-dev](https://github.com/duckey-dev) on 2026-12-01T15:38:54Z. --- @lewisenator Thank you, this is the measurement the PR lacked: another vendor, another OS, alternating runs. Your note that the title's own Present calls already alternate fits something we measured since. The title's present job waits on a two-slot ring until the previous frame's sync value is reached, so it keeps one frame outstanding, and when our pipeline needs more than one interval the waits fall into long and short pairs. The pacer evens out what that gate produces; it doesn't remove the gate. I'll resolve the conflict with #2910 by keeping both report lines when I rebase.
trustno1-coder commented 2026-12-01 18:48:12 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:48:12Z.


Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7321573377 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3851#issuecomment-7321573377). Originally posted by [trustno1-coder](https://github.com/trustno1-coder) on 2026-12-01T18:48:12Z. --- Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
trustno1-coder/VIctory-NVIDIA!3851
No description provided.