Display: Series S and Series X no longer stop at start at another resolution (UI pool sized for the output) #671

Open
cafe wants to merge 2 commits from cafe/s-ui-pool into post-merge AGit
Contributor

Contributor role (optional)

  • Fluxer ID: 1577752157942198273 (Cafe#9189)

What it changes

  • The problem on post-merge: a resolution other than the console's own stops the game at start.
    • The title's UI memory pool must match its UI targets, which follow the resolution: a pool too small stops at darner-image+0x56a2afd, one with more than 0x1FFFFF left over at +0x247af2d.
    • aspect.rs sizes the pool for the output on Series X at 1440 lines (ported from Darner's native 1440p), but skips Series S and Series X below 1440 lines.
  • Commit 1, Series S: its pool (82 MiB, for 1920x1080) is now sized for the output's targets, with the same formula as Series X: 94 MiB at 2560x1440, 128 MiB at 3840x2160, 72 MiB at 1280x720. Old Darner did the same for Series S at 1440p.
  • Commit 2, Series X below 1440 lines: the title's own 16:9 sizes (1920x1080, 1664x936, 1280x720) from the resolution option now get the layout Series S has at its 1920x1080 (legacy UI flag, 3840x2160 interface, the output as the output size, the pool sized to match). Before, they stopped at +0x247af2d. This one is new: old Darner held Series X at 1440 lines. Found by @NotGomenesai (#667, now closed).
  • Only the existing places are patched (one five-byte pool size more, for Series S); each is compared with the stock bytes first, and another build or other bytes leaves it alone. 1920x1080 on Series S and 2560x1440 on Series X are unchanged. DARNER_UI_LAYOUT=0 turns all of it off.

How it was tested

  • Tested revision: these two commits on 28a9b4259, in a test build that also has my bench-kit hooks (#665) and a local unpaced frame clock; neither touches this.
  • Each run: hardware RT, DLSS Performance (half the output inside), the bench kit's city camera flight (172 s).
Console, resolution post-merge as it is With this PR
Series S, 2560x1440 stops within 10 s at +0x56a2afd (run here) "UI pool 94 MiB"; flies the route: 22.2 fps, median 44.6 ms, p99 65.6 ms
Series S, 1280x720 stops within 10 s at +0x247af2d (run here; the address @Jesper-A traced in a player's log) "UI pool 72 MiB"; flies the route: 33.7 fps
Series X, 1920x1080 stops within 10 s at +0x247af2d (run here; first reproduced by @NotGomenesai) laid out, "UI pool 82 MiB"; world in 59 s, runs the whole flight: 27.3 fps
Series X, 1280x720 stops at +0x247af2d (reproduced by @NotGomenesai) laid out, "UI pool 72 MiB"; world in 58 s, runs the whole flight: 29.6 fps
  • Card and profile: RTX 2080 Ti, Windows 10 22H2. NVIDIA profile with the 1 GB shader heap.
  • Gates:
    • cargo build --locked --release -p darner: clean.
    • cargo test --release --locked -p darner --bin darner aspect::: 5 passed, including a new test of the Series S pool sizes.
    • cargo clippy --release --locked -p darner: nothing in aspect.rs.
  • Not tested: 3840x2160 and 1664x936 (the same formula; old Darner reached the world on Series S with the same 128 MiB at 4K), Series X 1664x936, a close look at menus and the pause map at the new sizes (I saw the loading screen fit the window at Series X 720p), other cards.

Checklist

  • One change (start at another resolution), based on post-merge.
  • No game files: offsets and sizes, compared with the stock bytes (docs/asset-policy.md).
  • Depends on: none.

Checked for overlap

  • Searched open PRs and issues for 1440, resolution, Series S, UI pool and both crash addresses.
  • #667 fitted Series S sizes above 1920x1080 down to 1920x1080; its author closed it in favour of this and pointed out the Series X case (commit 2).
  • #656 (docs) lists crash addresses; +0x56a2afd / +0x247af2d at a non-default resolution could point here.
## Contributor role (optional) - Fluxer ID: `1577752157942198273` (Cafe#9189) ## What it changes - The problem on post-merge: a `resolution` other than the console's own stops the game at start. - The title's UI memory pool must match its UI targets, which follow the resolution: a pool too small stops at `darner-image+0x56a2afd`, one with more than 0x1FFFFF left over at `+0x247af2d`. - `aspect.rs` sizes the pool for the output on Series X at 1440 lines (ported from Darner's native 1440p), but skips Series S and Series X below 1440 lines. - Commit 1, Series S: its pool (82 MiB, for 1920x1080) is now sized for the output's targets, with the same formula as Series X: 94 MiB at 2560x1440, 128 MiB at 3840x2160, 72 MiB at 1280x720. Old Darner did the same for Series S at 1440p. - Commit 2, Series X below 1440 lines: the title's own 16:9 sizes (1920x1080, 1664x936, 1280x720) from the resolution option now get the layout Series S has at its 1920x1080 (legacy UI flag, 3840x2160 interface, the output as the output size, the pool sized to match). Before, they stopped at `+0x247af2d`. This one is new: old Darner held Series X at 1440 lines. Found by @NotGomenesai (#667, now closed). - Only the existing places are patched (one five-byte pool size more, for Series S); each is compared with the stock bytes first, and another build or other bytes leaves it alone. 1920x1080 on Series S and 2560x1440 on Series X are unchanged. `DARNER_UI_LAYOUT=0` turns all of it off. ## How it was tested - Tested revision: these two commits on 28a9b4259, in a test build that also has my bench-kit hooks (#665) and a local unpaced frame clock; neither touches this. - Each run: hardware RT, DLSS Performance (half the output inside), the bench kit's city camera flight (172 s). | Console, resolution | post-merge as it is | With this PR | |---|---|---| | Series S, 2560x1440 | stops within 10 s at `+0x56a2afd` (run here) | "UI pool 94 MiB"; flies the route: 22.2 fps, median 44.6 ms, p99 65.6 ms | | Series S, 1280x720 | stops within 10 s at `+0x247af2d` (run here; the address @Jesper-A traced in a player's log) | "UI pool 72 MiB"; flies the route: 33.7 fps | | Series X, 1920x1080 | stops within 10 s at `+0x247af2d` (run here; first reproduced by @NotGomenesai) | laid out, "UI pool 82 MiB"; world in 59 s, runs the whole flight: 27.3 fps | | Series X, 1280x720 | stops at `+0x247af2d` (reproduced by @NotGomenesai) | laid out, "UI pool 72 MiB"; world in 58 s, runs the whole flight: 29.6 fps | - Card and profile: RTX 2080 Ti, Windows 10 22H2. NVIDIA profile with the 1 GB shader heap. - Gates: - `cargo build --locked --release -p darner`: clean. - `cargo test --release --locked -p darner --bin darner aspect::`: 5 passed, including a new test of the Series S pool sizes. - `cargo clippy --release --locked -p darner`: nothing in `aspect.rs`. - Not tested: 3840x2160 and 1664x936 (the same formula; old Darner reached the world on Series S with the same 128 MiB at 4K), Series X 1664x936, a close look at menus and the pause map at the new sizes (I saw the loading screen fit the window at Series X 720p), other cards. ## Checklist - [x] One change (start at another resolution), based on `post-merge`. - [x] No game files: offsets and sizes, compared with the stock bytes (`docs/asset-policy.md`). - [x] Depends on: none. ## Checked for overlap - [x] Searched open PRs and issues for 1440, resolution, Series S, UI pool and both crash addresses. - #667 fitted Series S sizes above 1920x1080 down to 1920x1080; its author closed it in favour of this and pointed out the Series X case (commit 2). - #656 (docs) lists crash addresses; `+0x56a2afd` / `+0x247af2d` at a non-default resolution could point here.
Series S's UI memory pool is sized for its stock 1920x1080 output: two
3840x2160 legacy surfaces and two 1920x1080 targets, 82 MiB. With another
resolution the targets are another size and the title stops at its assert
at start: larger outputs do not fit, smaller ones leave more than 0x1FFFFF
over (int3 at 0x247AF2D). The Series X layout patch skips Series S, so on
Series S the pool is now sized for the output's targets, as Darner's
native 1440p did (94 MiB at 2560x1440, 128 MiB at 3840x2160, 72 MiB at
1280x720). The stock bytes are checked first; 1920x1080 is left as it is.
On Series X the interface layout patch left outputs below 1440 lines as
they were, so the UI pool stayed sized for 3840x2160 targets and the
title stopped at its assert at start (int3 at 0x247AF2D; reported by
NotGomenesai in #667). The title's own smaller 16:9 sizes from the
resolution option now get the layout Series S has at 1920x1080: legacy
UI flag, 3840x2160 legacy UI size, the output as the output size, and the
pool sized for two output-sized targets. DARNER_ASPECT still takes
1440 lines only.
TrustNo1 changed title from [pr-fix][crash] Display: Series S and Series X no longer stop at start at another resolution (UI pool sized for the output) to Display: Series S and Series X no longer stop at start at another resolution (UI pool sized for the output) 2026-12-06 03:25:20 +00:00
This pull request can be merged automatically.
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 origin '+refs/pull/671/head:cafe/s-ui-pool'
git switch 'cafe/s-ui-pool'

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 'post-merge'
git merge --no-ff 'cafe/s-ui-pool'
git switch 'cafe/s-ui-pool'
git rebase 'post-merge'
git switch 'post-merge'
git merge --ff-only 'cafe/s-ui-pool'
git switch 'cafe/s-ui-pool'
git rebase 'post-merge'
git switch 'post-merge'
git merge --no-ff 'cafe/s-ui-pool'
git switch 'post-merge'
git merge --squash 'cafe/s-ui-pool'
git switch 'post-merge'
git merge --ff-only 'cafe/s-ui-pool'
git switch 'post-merge'
git merge 'cafe/s-ui-pool'
git push origin 'post-merge'
Sign in to join this conversation.
No reviewers
No milestone
No project
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.

Dependencies

No dependencies set

Reference
TrustNo1/Darner!671
No description provided.