[pr-fix][shaders] Preserve the slow limit with screen priority off #247

Open
andrewpozdnakov7-jpg wants to merge 1 commit from andrewpozdnakov7-jpg/Darner:port/4892-keep-slow-pipeline-limit into main
First-time contributor

Contributor role (optional)

  • Fluxer ID:

What it changes

With DARNER_SCREEN_WAIT_MS=0 and early screen handling enabled, a known slow screen pipeline can bypass the slow queue even though it does not qualify for the screen queue. Use the same predicate both when routing to the screen queue and when exempting a pipeline from the slow limit.

Restores locally saved VIctory-NVIDIA work from December 1, 2026. Recovered revision: bcebf7d. Adapted by andrewpozdnakov7-jpg (GitHub profile).

How it was tested

  • Tested revision: b0865cf on f3840d7.
  • Commands and results: A Rust fixture compiled the actual queue routing methods from both revisions. With screen priority off, main selected early and the patch selected slow. Five controls covering enabled priority, disabled early screen handling, disabled slow limit, other pipelines, and unknown slow status were unchanged. cargo check --locked -p darner-gpu --lib --tests, xtask policy, and git diff --check passed.
  • Changes a default: no.
  • Independent queue check: superhero-520 passed ten synthetic scenarios on Windows. With the only slow slot occupied, the patch held the known-slow pipeline, let ordinary work proceed and dispatched the slow pipeline once when the slot was released. Explicit requests and enabled screen priority retained their behavior.
  • Gates run on that revision: none of the three workspace-wide gates.
  • Coverage gaps: Synthetic queue entries and switches. No gameplay or performance measurements.

Checklist

  • I ran this change in the game.
  • This PR contains one change based on main.
  • The diff follows docs/asset-policy.md.
  • I recorded this PR's dependencies below.
    • Depends on: none

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches.
  • Related PRs: #187 edits the adjacent early_start lines. git merge-tree of current heads reports a conflict in pipeline/make.rs. If both changes land, retain #187's early return followed by this PR's shared queue predicate. See Jesper-A's review.
  • Replaces or overlaps: none found
## Contributor role (optional) - Fluxer ID: <!-- optional --> ## What it changes With DARNER_SCREEN_WAIT_MS=0 and early screen handling enabled, a known slow screen pipeline can bypass the slow queue even though it does not qualify for the screen queue. Use the same predicate both when routing to the screen queue and when exempting a pipeline from the slow limit. Restores locally saved VIctory-NVIDIA work from December 1, 2026. Recovered revision: bcebf7d. Adapted by [andrewpozdnakov7-jpg](https://git.gtahub.st/andrewpozdnakov7-jpg) ([GitHub profile](https://github.com/andrewpozdnakov7-jpg)). ## How it was tested - Tested revision: b0865cf on f3840d7. - Commands and results: A Rust fixture compiled the actual queue routing methods from both revisions. With screen priority off, main selected early and the patch selected slow. Five controls covering enabled priority, disabled early screen handling, disabled slow limit, other pipelines, and unknown slow status were unchanged. cargo check --locked -p darner-gpu --lib --tests, xtask policy, and git diff --check passed. - Changes a default: no. - Independent queue check: [superhero-520](https://git.gtahub.st/TrustNo1/Darner/pulls/247#issuecomment-861987) passed ten synthetic scenarios on Windows. With the only slow slot occupied, the patch held the known-slow pipeline, let ordinary work proceed and dispatched the slow pipeline once when the slot was released. Explicit requests and enabled screen priority retained their behavior. - Gates run on that revision: none of the three workspace-wide gates. - Coverage gaps: Synthetic queue entries and switches. No gameplay or performance measurements. ## Checklist - [ ] I ran this change in the game. - [x] This PR contains one change based on main. - [x] The diff follows docs/asset-policy.md. - [x] I recorded this PR's dependencies below. - Depends on: none ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. - Related PRs: #187 edits the adjacent early_start lines. git merge-tree of current heads reports a conflict in pipeline/make.rs. If both changes land, retain #187's early return followed by this PR's shared queue predicate. See [Jesper-A's review](https://git.gtahub.st/TrustNo1/Darner/pulls/247#issuecomment-862353). - Replaces or overlaps: none found
Adapt locally saved VIctory-NVIDIA work from December 1, 2026 (bcebf7d). Use the same early-screen condition to select the queue and to exempt a pipeline from the slow limit.

https://git.gtahub.st/andrewpozdnakov7-jpg
https://github.com/andrewpozdnakov7-jpg
First-time contributor

I compared b0865cff4791b8de231ee5bcf6a657b7c3bf3a40 with f3840d73d3504c30218debfbc8795b9225447317 using the queue’s compiled push, pop and worker-selection code. A gated worker held the only slow slot. With DARNER_SCREEN_WAIT_MS=0, main dispatched a known-slow screen pipeline while that slot was busy. When ordinary work was also queued, main picked the screen pipeline first.

On the PR, the slow pipeline alone stayed queued. Ordinary work could run while the slot was occupied. Releasing the slot then dispatched the slow pipeline exactly once and counted it against the limit. Both revisions still dispatched an explicitly promoted request while the slot was busy, and kept screen priority when it was enabled. All ten cases passed their expected outcomes on Windows with Rust 1.98.1. The jobs were synthetic and no GPU timing was measured.

I compared `b0865cff4791b8de231ee5bcf6a657b7c3bf3a40` with `f3840d73d3504c30218debfbc8795b9225447317` using the queue’s compiled push, pop and worker-selection code. A gated worker held the only slow slot. With `DARNER_SCREEN_WAIT_MS=0`, main dispatched a known-slow screen pipeline while that slot was busy. When ordinary work was also queued, main picked the screen pipeline first. On the PR, the slow pipeline alone stayed queued. Ordinary work could run while the slot was occupied. Releasing the slot then dispatched the slow pipeline exactly once and counted it against the limit. Both revisions still dispatched an explicitly promoted request while the slot was busy, and kept screen priority when it was enabled. All ten cases passed their expected outcomes on Windows with Rust 1.98.1. The jobs were synthetic and no GPU timing was measured.
Collaborator

Code-read review of b0865cf. I did not build or run it.

The change is right. On main, Queue::push exempts a pipeline from the slow limit with !(p.screen && screen_early()) (pipeline/make.rs:1784), but push_as only puts it in the screen list when p.screen && screens_first() && screen_early() (:1800). With DARNER_SCREEN_WAIT_MS=0, screens_first() is false (:601), so a known-slow screen pipeline was exempt from slow and then landed in early. Using one predicate for both fixes that. Default runs are unchanged, because there the two predicates are equal.

One conflict to know about: #187 (hingeowl, CS_RaytracingResolve culling) inserts an early return directly above the line this PR rewrites in early_start (let screen = ..., main make.rs:1113). git merge-tree of the two heads reports a content conflict in pipeline/make.rs. The two do not interact: keep #187's return, then this PR's let screen = p.queues_early_as_screen();. Whichever merges second needs a one-line rebase. Please list #187 as related.

This comment was written with AI assistance (Claude Code).

Code-read review of b0865cf. I did not build or run it. The change is right. On main, `Queue::push` exempts a pipeline from the slow limit with `!(p.screen && screen_early())` (`pipeline/make.rs:1784`), but `push_as` only puts it in the screen list when `p.screen && screens_first() && screen_early()` (`:1800`). With `DARNER_SCREEN_WAIT_MS=0`, `screens_first()` is false (`:601`), so a known-slow screen pipeline was exempt from `slow` and then landed in `early`. Using one predicate for both fixes that. Default runs are unchanged, because there the two predicates are equal. One conflict to know about: #187 (hingeowl, `CS_RaytracingResolve` culling) inserts an early `return` directly above the line this PR rewrites in `early_start` (`let screen = ...`, main `make.rs:1113`). `git merge-tree` of the two heads reports a content conflict in `pipeline/make.rs`. The two do not interact: keep #187's `return`, then this PR's `let screen = p.queues_early_as_screen();`. Whichever merges second needs a one-line rebase. Please list #187 as related. This comment was written with AI assistance (Claude Code).
Author
First-time contributor

Thanks for checking both queue paths. This PR stays on main and changes the condition for the slow-limit exemption. I noted the overlap you found with #187 in the early_start block. The shared lines will need to be reconciled when one of the PRs reaches main.

Thanks for checking both queue paths. This PR stays on main and changes the condition for the slow-limit exemption. I noted the overlap you found with #187 in the `early_start` block. The shared lines will need to be reconciled when one of the PRs reaches main.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'port/4892-keep-slow-pipeline-limit:andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git switch 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'

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.

git switch 'main'
git merge --no-ff 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git switch 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git rebase 'main'
git switch 'main'
git merge --ff-only 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git switch 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git rebase 'main'
git switch 'main'
git merge --no-ff 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git switch 'main'
git merge --squash 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git switch 'main'
git merge --ff-only 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git switch 'main'
git merge 'andrewpozdnakov7-jpg-port/4892-keep-slow-pipeline-limit'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
3 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
TrustNo1/Darner!247
No description provided.