feat(vk): a Present queue row on the Debug tab, for the presents' own GPU queue #1554

Merged
llun merged 2 commits from pmwork-personal/Longshot:feat/present-queue-debug-row into main 2026-11-18 05:48:12 +00:00
Member

Type: feat · Risk: low · Tested on: Windows 11, RTX 5090 (NVIDIA 621.24) · Needs: the tester's RTX 5080, to trace the present queue's lost GPU with the row

TL;DR

Since #1549 the presents' own GPU queue is off by default, and only a line in longshot_env.txt turned it on. The Insert
menu's Debug tab now has it as Present queue (Off by default, applied after a restart), so a player can try it and a
tester can switch it while we trace why it loses the GPU on an RTX 5080 with frame generation on.

Breakdown

  • Who it helps: testers and players who want the presents' own queue (more even frame generation with V-Sync Off on
    some cards), and the trace of its lost GPU on an RTX 5080.
  • What was wrong: nothing broken; turning the queue on needed RX_VK_PRESENT_QUEUE=1 in a file.
  • What changes: a Debug tab row, saved as present_queue= in longshot_options.ini, read by create_device at the
    start; RX_VK_PRESENT_QUEUE still decides over it.
  • What does not change: the default (Off on every PC, as since #1549); the queue itself; every other row.
  • How it was checked: a game-free check that compiles the queue choice with an options file (fails on main); the full
    suite as on main.
  • What is still open: the row seen and used in the game (see Testing).
  • Risk: low: Off by default, the same as main; On is what RX_VK_PRESENT_QUEUE=1 does on main.

Why

#1549 made the presents' compute queue opt-in again after a tester's RTX 5080 lost the GPU with it and frame generation on
(the crashes stopped with RX_VK_PRESENT_QUEUE=0; #1491 looks the same). Why it does that is not known: other games present
on the graphics queue, and the fault was never placed. Tracing it needs the tester to switch the queue, one setting at a
time, and a menu row is easier for a player than a line in a file. The queue also still helps on an RTX 5090 (V-Sync Off,
fixed multiplier: made frames on the screen under 2 ms after the one before from a third to 0.1%), where a player can keep
it with this row.

See #1549, #1476, #1491.

How to reproduce

Seen on: any PC; main 79d4a143
Settings and switches: the Insert menu's Debug tab
Steps: open the Insert menu, go to the Debug tab.
Expected: a row to turn the presents' own queue on.
Actual: none; only RX_VK_PRESENT_QUEUE=1 in longshot_env.txt turns it on.

What changed

The Debug tab gets a Present queue row; the renderer reads it at the start, the switch over it.

  • gpu/vk/vk_menu.cpp: the row (Off or On, restart, preset-exempt), after Robust buffers; with RX_VK_PRESENT_QUEUE
    set (the old README's way, in some longshot_env.txt files) the row shows the switch's value, cannot be changed and says
    so, as ASTC as RGBA8's row with RX_VK_ASTC_RGBA8; gpu/vk/vk_menu.h: Options::present_queue, 0.
  • gpu/vk/vk_main.cpp create_device: with RX_VK_PRESENT_QUEUE unset or empty, present_queue= from
    longshot_options.ini (read at the start, as robust_buffers=: the menu's options are not loaded yet).
  • gpu/vk/switches.def: RX_VK_PRESENT_QUEUE is a player switch over the row, as RX_VK_ROBUST.
  • README.md (the Debug tab's list, the frame generation note: with the row On and no way to the menu after a lost GPU,
    RX_VK_PRESENT_QUEUE=0 in longshot_env.txt overrides it) and docs/development.md (the switch's row) name the row;
    the log's presents on a queue of their own line names it too.
  • tests/test_present_queue_default.py: the compiled queue choice also gets an options file: present_queue=1 takes the
    compute family, 0 or none leaves it, the switch decides over the row, an empty switch leaves it to the row; and the
    row's text and its display while the switch holds it. Fails on main: "the Debug tab's Present queue On, the switch
    unset: family -1, expected 2".

Measurements

Nothing to measure: the row turns on what RX_VK_PRESENT_QUEUE=1 turns on (measured in #1476), Off is main's default.

Flags and settings

One menu row and its ini key are added; one switch changes its kind.

Flag What it is Before this PR After this PR Effect Helps / doesn't help / untested Recommendation
Present queue Insert menu row, Debug tab (restart) none Off by default the presents on a compute family's queue of their own, from the next start helps: even frames with V-Sync Off on an RTX 5090; doesn't help: an RTX 5080 (the GPU lost) Off; On where it runs
present_queue longshot_options.ini key none 0 the row's value, read by create_device at the start as the row 0
RX_VK_PRESENT_QUEUE env, renderer attempt: 1 on, else off player: 0 or 1 over the row, unset or empty: the row as before when set as before unset

Testing

Tested:

  • tests/test_present_queue_default.py passes here and fails on main (Windows, llvm-mingw clang 23).
  • python -I -B tests/run_all.py on 567d09f9 (Windows, llvm-mingw): 666 passed, 55 failed, 50 skipped; the same 55 fail
    on main 79d4a143's parent run (none reads a file this PR changes, or each fails there for its own reason, as
    test_damage_debug_menu's Frame pacing and Threaded rendering rows and test_switch_table's host switches).

Not testable by hand: the RTX 5080 where the queue loses the GPU.

Not tested: the row in the game: its line on the Debug tab, its save, and a restart with it On giving the log's
presents on a queue of their own.

Must be tested:

  • Windows, any GPU: the Debug tab shows Present queue (Off); turn it On, restart: the log says vk: presents on a queue of their own; Off again, restart: it does not; with RX_VK_PRESENT_QUEUE=0 set the row's On is overridden; expecting
    each of those (by hand: me, before this is marked ready).

Risks

What could break: nothing that I know of: Off is main's default, and the row only stands in for the switch.

Turning it off: set the row Off (the default), or RX_VK_PRESENT_QUEUE=0.

Compatibility: longshot_options.ini gains present_queue=0; an older build ignores it. Saves, caches and the vk ABI
as before.

Issues

See #1549, #1476, #1491

Checklist

Everyone

  • One topic.
  • The title is a Conventional Commit (type(scope): description) of the status line's type.
  • Why gives the reason plainly and links the issues that fit (the tracker searched).
  • Tested on my own PC where it runs (in the game, for a change the game runs), as Testing's Tested says; what
    can't be run by hand is in Testing's Not testable by hand, with why.
  • Measurements has a verdict, or one line saying why there is nothing to measure.
  • Nothing gets worse that I know of: any cost (speed, latency, memory, a setup that worked before) is measured and
    in Risks.
  • Testing names what was tested, what wasn't, and what must still be tested, where and how.
  • Rebased on current main.
  • python -I -B tests/run_all.py passes (any failure that also fails on main is named).
  • No game files, dumps, build output or generated files.
  • third_party/ untouched (a new folder with a PROVENANCE.md instead).
  • The license is OK: GPL-3.0-or-later, nothing incompatible and nothing decompiled.

When it applies

  • AI assistance recorded with Assisted-by: / Co-Authored-By: trailers.
  • Switches documented (docs/development.md; the README for a menu row) and shipped at their recommended value.
  • A check under tests/ that reads changed source updated in this PR, not weakened.
  • A game-free test added for the fix, failing on main and passing here.
  • Docs updated.

🤖 Generated with Claude Code

Assisted-by: Claude Code
Co-Authored-By: Claude Opus 5.5 [email protected]

**Type:** feat · **Risk:** low · **Tested on:** Windows 11, RTX 5090 (NVIDIA 621.24) · **Needs:** the tester's RTX 5080, to trace the present queue's lost GPU with the row ## TL;DR Since #1549 the presents' own GPU queue is off by default, and only a line in `longshot_env.txt` turned it on. The Insert menu's Debug tab now has it as **Present queue** (Off by default, applied after a restart), so a player can try it and a tester can switch it while we trace why it loses the GPU on an RTX 5080 with frame generation on. ## Breakdown - **Who it helps:** testers and players who want the presents' own queue (more even frame generation with V-Sync Off on some cards), and the trace of its lost GPU on an RTX 5080. - **What was wrong:** nothing broken; turning the queue on needed `RX_VK_PRESENT_QUEUE=1` in a file. - **What changes:** a Debug tab row, saved as `present_queue=` in `longshot_options.ini`, read by `create_device` at the start; `RX_VK_PRESENT_QUEUE` still decides over it. - **What does not change:** the default (Off on every PC, as since #1549); the queue itself; every other row. - **How it was checked:** a game-free check that compiles the queue choice with an options file (fails on main); the full suite as on main. - **What is still open:** the row seen and used in the game (see Testing). - **Risk:** low: Off by default, the same as main; On is what `RX_VK_PRESENT_QUEUE=1` does on main. ## Why #1549 made the presents' compute queue opt-in again after a tester's RTX 5080 lost the GPU with it and frame generation on (the crashes stopped with `RX_VK_PRESENT_QUEUE=0`; #1491 looks the same). Why it does that is not known: other games present on the graphics queue, and the fault was never placed. Tracing it needs the tester to switch the queue, one setting at a time, and a menu row is easier for a player than a line in a file. The queue also still helps on an RTX 5090 (V-Sync Off, fixed multiplier: made frames on the screen under 2 ms after the one before from a third to 0.1%), where a player can keep it with this row. See #1549, #1476, #1491. ## How to reproduce **Seen on:** any PC; main 79d4a143 **Settings and switches:** the Insert menu's Debug tab **Steps:** open the Insert menu, go to the Debug tab. **Expected:** a row to turn the presents' own queue on. **Actual:** none; only `RX_VK_PRESENT_QUEUE=1` in `longshot_env.txt` turns it on. ## What changed The Debug tab gets a Present queue row; the renderer reads it at the start, the switch over it. - `gpu/vk/vk_menu.cpp`: the row (Off or On, `restart`, preset-exempt), after Robust buffers; with `RX_VK_PRESENT_QUEUE` set (the old README's way, in some `longshot_env.txt` files) the row shows the switch's value, cannot be changed and says so, as ASTC as RGBA8's row with `RX_VK_ASTC_RGBA8`; `gpu/vk/vk_menu.h`: `Options::present_queue`, 0. - `gpu/vk/vk_main.cpp` `create_device`: with `RX_VK_PRESENT_QUEUE` unset or empty, `present_queue=` from `longshot_options.ini` (read at the start, as `robust_buffers=`: the menu's options are not loaded yet). - `gpu/vk/switches.def`: `RX_VK_PRESENT_QUEUE` is a `player` switch over the row, as `RX_VK_ROBUST`. - `README.md` (the Debug tab's list, the frame generation note: with the row On and no way to the menu after a lost GPU, `RX_VK_PRESENT_QUEUE=0` in `longshot_env.txt` overrides it) and `docs/development.md` (the switch's row) name the row; the log's `presents on a queue of their own` line names it too. - `tests/test_present_queue_default.py`: the compiled queue choice also gets an options file: `present_queue=1` takes the compute family, `0` or none leaves it, the switch decides over the row, an empty switch leaves it to the row; and the row's text and its display while the switch holds it. Fails on main: "the Debug tab's Present queue On, the switch unset: family -1, expected 2". ## Measurements Nothing to measure: the row turns on what `RX_VK_PRESENT_QUEUE=1` turns on (measured in #1476), Off is main's default. ### Flags and settings One menu row and its ini key are added; one switch changes its kind. | Flag | What it is | Before this PR | After this PR | Effect | Helps / doesn't help / untested | Recommendation | |---|---|---|---|---|---|---| | Present queue | Insert menu row, Debug tab (restart) | none | Off by default | the presents on a compute family's queue of their own, from the next start | helps: even frames with V-Sync Off on an RTX 5090; doesn't help: an RTX 5080 (the GPU lost) | Off; On where it runs | | `present_queue` | `longshot_options.ini` key | none | 0 | the row's value, read by `create_device` at the start | as the row | 0 | | `RX_VK_PRESENT_QUEUE` | env, renderer | attempt: 1 on, else off | player: 0 or 1 over the row, unset or empty: the row | as before when set | as before | unset | ## Testing **Tested:** - `tests/test_present_queue_default.py` passes here and fails on main (Windows, llvm-mingw clang 23). - `python -I -B tests/run_all.py` on 567d09f9 (Windows, llvm-mingw): 666 passed, 55 failed, 50 skipped; the same 55 fail on main 79d4a143's parent run (none reads a file this PR changes, or each fails there for its own reason, as test_damage_debug_menu's Frame pacing and Threaded rendering rows and test_switch_table's host switches). **Not testable by hand:** the RTX 5080 where the queue loses the GPU. **Not tested:** the row in the game: its line on the Debug tab, its save, and a restart with it On giving the log's `presents on a queue of their own`. **Must be tested:** - Windows, any GPU: the Debug tab shows Present queue (Off); turn it On, restart: the log says `vk: presents on a queue of their own`; Off again, restart: it does not; with `RX_VK_PRESENT_QUEUE=0` set the row's On is overridden; expecting each of those (by hand: me, before this is marked ready). ## Risks **What could break:** nothing that I know of: Off is main's default, and the row only stands in for the switch. **Turning it off:** set the row Off (the default), or `RX_VK_PRESENT_QUEUE=0`. **Compatibility:** `longshot_options.ini` gains `present_queue=0`; an older build ignores it. Saves, caches and the vk ABI as before. ## Issues See #1549, #1476, #1491 ## Checklist ### Everyone - [x] One topic. - [x] The title is a Conventional Commit (`type(scope): description`) of the status line's type. - [x] Why gives the reason plainly and links the issues that fit (the tracker searched). - [ ] Tested on my own PC where it runs (in the game, for a change the game runs), as Testing's Tested says; what can't be run by hand is in Testing's Not testable by hand, with why. - [x] Measurements has a verdict, or one line saying why there is nothing to measure. - [x] Nothing gets worse that I know of: any cost (speed, latency, memory, a setup that worked before) is measured and in Risks. - [x] Testing names what was tested, what wasn't, and what must still be tested, where and how. - [x] Rebased on current `main`. - [x] `python -I -B tests/run_all.py` passes (any failure that also fails on `main` is named). - [x] No game files, dumps, build output or generated files. - [x] `third_party/` untouched (a new folder with a `PROVENANCE.md` instead). - [x] The license is OK: GPL-3.0-or-later, nothing incompatible and nothing decompiled. ### When it applies - [x] AI assistance recorded with `Assisted-by:` / `Co-Authored-By:` trailers. - [x] Switches documented (docs/development.md; the README for a menu row) and shipped at their recommended value. - [x] A check under `tests/` that reads changed source updated in this PR, not weakened. - [x] A game-free test added for the fix, failing on `main` and passing here. - [x] Docs updated. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Assisted-by: Claude Code Co-Authored-By: Claude Opus 5.5 <[email protected]>
test_present_queue_default's compiled queue choice now gets a longshot_options.ini too: present_queue=1 (the Debug tab's
Present queue row, read at the start as robust_buffers=) takes the compute family, 0 or none leaves it; RX_VK_PRESENT_QUEUE
decides over the row either way, an empty value leaves it to the row. And the row: on the Debug tab, Off or On, applied after
a restart, its value Options::present_queue, 0 by default.

Fails on main: there is no row, and present_queue=1 leaves the presents on the replay's queue.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Assisted-by: Claude Code
feat(vk): a Present queue row on the Debug tab, for the presents' own GPU queue
Some checks failed
CI / Python source checks (ubuntu-24.04, part 1/2) (pull_request) Has been skipped
CI / Python source checks (ubuntu-24.04, part 2/2) (pull_request) Has been skipped
CI / SPIR-V fixtures (global narrow load/store, direct surface atomics, F2I immediate) (pull_request) Has been skipped
Third-party parts / The same as upstream (pull_request) Has been skipped
Website / Website on Cloudflare (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 8s
Website / Website on Cloudflare (pull_request_target) Has been skipped
Guide screenshots / Guide images and local UI source review (pull_request) Failing after 15s
CI / Workflow lint (actionlint) (pull_request) Successful in 17s
Third-party parts / As their notes say (pull_request) Successful in 19s
PR description / Description follows the template (pull_request_target) Failing after 4s
64a9a3d9d5
Since #1549 the presents' own compute queue is off by default and only RX_VK_PRESENT_QUEUE=1 turned it on, a line in a file.
The Insert menu's Debug tab now has it as Present queue (Off or On, applied after a restart, saved as present_queue= in
longshot_options.ini), so a player can try it and say which way the game runs, and a tester can tell the two causes of a lost
GPU apart without editing a file. create_device reads the key at the start, as robust_buffers=; RX_VK_PRESENT_QUEUE decides
over it (the switches' yes/no rule), so the switch is a player's again. The README's Debug tab list, its frame generation
note and the development guide's row name the row.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Assisted-by: Claude Code
llun approved these changes 2026-11-18 05:48:01 +00:00
llun changed title from WIP: feat(vk): a Present queue row on the Debug tab, for the presents' own GPU queue to feat(vk): a Present queue row on the Debug tab, for the presents' own GPU queue 2026-11-18 05:48:07 +00:00
llun merged commit 68d7757e5c into main 2026-11-18 05:48:12 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MagicBeanDev/Longshot!1554
No description provided.