[pr-refactor][frame-generation][startup][NVIDIA] Defer the FSR 3 SDK when AUTO can use DLSS Frame Generation #168

Open
tyr0nsur wants to merge 1 commit from tyr0nsur/Darner:codex/defer-auto-fsr-sdk into main
Contributor

Contributor role (optional)

  • Fluxer ID:

What it changes

AUTO requests FSR 3 as a fallback for DLSS Frame Generation. When Streamline reports DLSS FG support, Darner now records the optional FidelityFX fallback and loads the signed SDK only if FSR 3 can create the swap chain. An actual fallback preserves the upscale inputs recorded before the swap chain is created and attempts the SDK load once. Explicit FSR, FSR 3 when Streamline already reports native FG unavailable, and the PC FidelityFX/FSR 4 path still use their startup checks.

How it was tested

  • Tested 9a3a0f3678ecf036350bf38b4c7af0c0fbf0b118 against 57dea7f2367c4e902b8ef507f90536564b670b04.

  • Windows 11 Pro build 26300, RTX 4060 8 GB, NVIDIA driver 621.40, Streamline 2.14.16 and AMD FidelityFX SDK 2.4.0. Built with Rust 1.98.1 using cargo build --locked --profile diag -p darner --features diagnostics.

  • Startup in the title. Series X, 2560×1440, DLSS Quality, FG requested at 2× and ray tracing off. Both signed SDKs were installed. Each start used the same isolated warm cache and a copy of the same profile. One ABBA on base compared --fg-type auto with --fg-type dlss. The second ABBA compared base AUTO with candidate AUTO. Measured starts all reached Streamline's swap-chain proxy and the first group of presents.

    Condition PC FidelityFX DLLs loaded First present group after launch DXGI local usage at swap-chain creation
    Base AUTO vs forced DLSS ABBA 2 in AUTO, 0 in forced DLSS 6.454–6.613 s vs 6.486–6.906 s 234 MiB in every run
    Before vs after AUTO ABBA 2 on base, 0 on candidate 6.460–6.465 s vs 6.502–6.631 s 234 MiB in every run

    AUTO on base loaded the PC FidelityFX loader and frame-generation DLL. The sampled title private memory after the first group was 8,595–8,618 MiB on base AUTO and 8,501–8,721 MiB on candidate AUTO in the before/after ABBA. These short runs establish the two avoided loads. Timing and memory varied across runs.

  • Synthetic D3D12 checks. Repeated both ABBA sequences at 1920×1080 with the existing focused foreground FG fixture, driving production initialisation under AUTO or forced DLSS. These checks requested DLSS and exercised DLSS FG without dispatching the Super Resolution workload. In all eight measured runs the SDK showed 160 frames from 80 presents and DXGI counted 162 presents in its sampling window. Frame-interval p95 was 17.037–17.087 ms across the eight runs with the probe's nominal 16 ms pacing. The candidate passed the seven-phase ready/off, 2×, resize and swap-chain recreation check with the AMD SDK unloaded.

  • Deferred fallback. With AUTO supported, the candidate created the native DLSS swap chain at factor 0 while FidelityFX was unloaded. After the test marked the DLSS proxy unavailable, upscale input noting was active before loading the SDK. The replacement FSR 3 chain was ready at factor 0. The toggle used by the F1 menu enabled FSR 3 on 72/72 presents at 1280×720 and 72/72 after resizing to 1248×688, with a DLSS Super Resolution evaluation before each present.

  • The focused combined SR + DLSS FG diagnostic reported one output frame per input on both revisions. The dedicated FG workload above supplied the verified 2× measurements. Gameplay frame pacing with verified 2×, RTX 20/30 hardware, AMD hardware and generated-image fidelity remain outside this coverage.

  • Cargo and asset checks. Both cargo clippy --workspace --all-targets --locked -- -D warnings and the --all-features variant passed. The full asset check passed with cargo run --locked --quiet --package xtask -- policy (553 files), as did the staged check with --staged.

  • cargo test --workspace --locked -- --test-threads=1 hit the intermittent watch::tests::ask_once_by_res_splits_reservations_without_refusals assertion after 1,756 GPU test passes. The same assertion was reproduced on the exact base in an earlier run and is covered by #150. A new base GPU run passed, as did all 61 candidate Streamline tests.

Checklist

  • 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: #113, #139 and #144 also touch FSR. #47, #48 and #143 also touch Streamline. No existing PR for this deferral was found.
## Contributor role (optional) - Fluxer ID: ## What it changes AUTO requests FSR 3 as a fallback for DLSS Frame Generation. When Streamline reports DLSS FG support, Darner now records the optional FidelityFX fallback and loads the signed SDK only if FSR 3 can create the swap chain. An actual fallback preserves the upscale inputs recorded before the swap chain is created and attempts the SDK load once. Explicit FSR, FSR 3 when Streamline already reports native FG unavailable, and the PC FidelityFX/FSR 4 path still use their startup checks. ## How it was tested - Tested `9a3a0f3678ecf036350bf38b4c7af0c0fbf0b118` against `57dea7f2367c4e902b8ef507f90536564b670b04`. - Windows 11 Pro build 26300, RTX 4060 8 GB, NVIDIA driver 621.40, Streamline 2.14.16 and AMD FidelityFX SDK 2.4.0. Built with Rust 1.98.1 using `cargo build --locked --profile diag -p darner --features diagnostics`. - **Startup in the title.** Series X, 2560×1440, DLSS Quality, FG requested at 2× and ray tracing off. Both signed SDKs were installed. Each start used the same isolated warm cache and a copy of the same profile. One ABBA on base compared `--fg-type auto` with `--fg-type dlss`. The second ABBA compared base AUTO with candidate AUTO. Measured starts all reached Streamline's swap-chain proxy and the first group of presents. | Condition | PC FidelityFX DLLs loaded | First present group after launch | DXGI local usage at swap-chain creation | |---|---:|---:|---:| | Base AUTO vs forced DLSS ABBA | 2 in AUTO, 0 in forced DLSS | 6.454–6.613 s vs 6.486–6.906 s | 234 MiB in every run | | Before vs after AUTO ABBA | 2 on base, 0 on candidate | 6.460–6.465 s vs 6.502–6.631 s | 234 MiB in every run | AUTO on base loaded the PC FidelityFX loader and frame-generation DLL. The sampled title private memory after the first group was 8,595–8,618 MiB on base AUTO and 8,501–8,721 MiB on candidate AUTO in the before/after ABBA. These short runs establish the two avoided loads. Timing and memory varied across runs. - **Synthetic D3D12 checks.** Repeated both ABBA sequences at 1920×1080 with the existing focused foreground FG fixture, driving production initialisation under AUTO or forced DLSS. These checks requested DLSS and exercised DLSS FG without dispatching the Super Resolution workload. In all eight measured runs the SDK showed 160 frames from 80 presents and DXGI counted 162 presents in its sampling window. Frame-interval p95 was 17.037–17.087 ms across the eight runs with the probe's nominal 16 ms pacing. The candidate passed the seven-phase ready/off, 2×, resize and swap-chain recreation check with the AMD SDK unloaded. - **Deferred fallback.** With AUTO supported, the candidate created the native DLSS swap chain at factor 0 while FidelityFX was unloaded. After the test marked the DLSS proxy unavailable, upscale input noting was active before loading the SDK. The replacement FSR 3 chain was ready at factor 0. The toggle used by the F1 menu enabled FSR 3 on 72/72 presents at 1280×720 and 72/72 after resizing to 1248×688, with a DLSS Super Resolution evaluation before each present. - The focused combined SR + DLSS FG diagnostic reported one output frame per input on both revisions. The dedicated FG workload above supplied the verified 2× measurements. Gameplay frame pacing with verified 2×, RTX 20/30 hardware, AMD hardware and generated-image fidelity remain outside this coverage. - **Cargo and asset checks.** Both `cargo clippy --workspace --all-targets --locked -- -D warnings` and the `--all-features` variant passed. The full asset check passed with `cargo run --locked --quiet --package xtask -- policy` (553 files), as did the staged check with `--staged`. - `cargo test --workspace --locked -- --test-threads=1` hit the intermittent `watch::tests::ask_once_by_res_splits_reservations_without_refusals` assertion after 1,756 GPU test passes. The same assertion was reproduced on the exact base in an earlier run and is covered by [#150](https://git.gtahub.st/TrustNo1/Darner/pulls/150). A new base GPU run passed, as did all 61 candidate Streamline tests. ## Checklist - [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: #113, #139 and #144 also touch FSR. #47, #48 and #143 also touch Streamline. No existing PR for this deferral was found.
First-time contributor

Verified 2× DLSS Frame Generation during gameplay on an RTX 4070 Ti SUPER. On parent 57dea7f2, Windows showed both AMD FidelityFX DLLs loaded before and after each window. On candidate 9a3a0f36, neither AMD DLL was present at either check. All six game processes loaded the same eight NVIDIA DLLs. Both SDKs were installed and their signatures verified.

Run Rendered FPS Rendered median / p99, ms NVIDIA inputs → outputs SDK outputs/s
A1 26.64 37.39 / 38.89 1,168 → 2,336 53.28
B1 26.04 38.04 / 49.57 1,144 → 2,288 52.07
B2 26.70 37.32 / 40.87 1,167 → 2,334 53.38
A2 25.41 39.18 / 46.69 1,117 → 2,234 50.80

Every complete SDK interval gave exactly 2×, status zero and zero FG-off presents. DLSS SR reported one successful evaluation per frame. The candidate built 11 and 4 pipelines during its respective windows. Draw counts and traffic varied, so these runs do not establish a pacing gain or regression.

Windows 11 build 28000, i5-13600KF, driver 617.14. Stock locked release builds, Series X, 2560×1440 SDR, DLSS Quality (1706×960 input), AUTO, FG 2×, RT off. One warm-up per build, then ABBA using the same save and fixed camera. The frame CSV covered 45 s per run (+55 to +100 s after the world marker), with focus throughout. Complete SDK groups cover 43.72–43.98 s per run. These output counts are from Streamline. Physical scanout and generated-image fidelity were not measured.

Verified 2× DLSS Frame Generation during gameplay on an RTX 4070 Ti SUPER. On parent 57dea7f2, Windows showed both AMD FidelityFX DLLs loaded before and after each window. On candidate 9a3a0f36, neither AMD DLL was present at either check. All six game processes loaded the same eight NVIDIA DLLs. Both SDKs were installed and their signatures verified. | Run | Rendered FPS | Rendered median / p99, ms | NVIDIA inputs → outputs | SDK outputs/s | |---|---:|---:|---:|---:| | A1 | 26.64 | 37.39 / 38.89 | 1,168 → 2,336 | 53.28 | | B1 | 26.04 | 38.04 / 49.57 | 1,144 → 2,288 | 52.07 | | B2 | 26.70 | 37.32 / 40.87 | 1,167 → 2,334 | 53.38 | | A2 | 25.41 | 39.18 / 46.69 | 1,117 → 2,234 | 50.80 | Every complete SDK interval gave exactly 2×, status zero and zero FG-off presents. DLSS SR reported one successful evaluation per frame. The candidate built 11 and 4 pipelines during its respective windows. Draw counts and traffic varied, so these runs do not establish a pacing gain or regression. Windows 11 build 28000, i5-13600KF, driver 617.14. Stock locked release builds, Series X, 2560×1440 SDR, DLSS Quality (1706×960 input), AUTO, FG 2×, RT off. One warm-up per build, then ABBA using the same save and fixed camera. The frame CSV covered 45 s per run (+55 to +100 s after the world marker), with focus throughout. Complete SDK groups cover 43.72–43.98 s per run. These output counts are from Streamline. Physical scanout and generated-image fidelity were not measured.
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 'codex/defer-auto-fsr-sdk:tyr0nsur-codex/defer-auto-fsr-sdk'
git switch 'tyr0nsur-codex/defer-auto-fsr-sdk'

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 'tyr0nsur-codex/defer-auto-fsr-sdk'
git switch 'tyr0nsur-codex/defer-auto-fsr-sdk'
git rebase 'main'
git switch 'main'
git merge --ff-only 'tyr0nsur-codex/defer-auto-fsr-sdk'
git switch 'tyr0nsur-codex/defer-auto-fsr-sdk'
git rebase 'main'
git switch 'main'
git merge --no-ff 'tyr0nsur-codex/defer-auto-fsr-sdk'
git switch 'main'
git merge --squash 'tyr0nsur-codex/defer-auto-fsr-sdk'
git switch 'main'
git merge --ff-only 'tyr0nsur-codex/defer-auto-fsr-sdk'
git switch 'main'
git merge 'tyr0nsur-codex/defer-auto-fsr-sdk'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
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
TrustNo1/Darner!168
No description provided.