[Linux] 30–60 FPS with Series X + DLSS Frame Generation on a 12 GB RTX, under plain Wine (one setting kills the FG stutter) #3370
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from ubiquitarianism/leonida. Originally posted by janvitos on 2026-12-03T17:29:00Z.
Series X profile, DLSS Quality to 1440p and DLSS Frame Generation 2x now run well on my 12 GB card under upstream Wine. Two things made the difference:
LEONIDA_FG_RESET_STALE=0fixed the stutter. Before, the game felt like 10–15 fps even with the FG counter showing 35.LEONIDA_TEXTURE_BUDGET_MB=2048stops the card filling up and the driver crashing.Below: evidence, then a setup guide.
System
RTX 4070 SUPER 12 GB · Ryzen 7 9700X · 48 GB RAM · CachyOS (kernel 7.3.7) · NVIDIA 620.73.04 (open modules, patched with open-gpu-kernel-modules PR #1542) · Wine 11.23 (upstream, not Proton) · 2560x1440 · Mandy
d227aa73eEvidence
1. Frame-generation stutter. By default, Mandy tells DLSS-G "reset" (skip the in-between frame) on any present without a fresh upscale, and on the present after it (
fg.rs,present_start). Under Wine, 15–33% of gameplay presents were like that.FG_RESET_STALEon (default)LEONIDA_FG_RESET_STALE=0presented=2, 0 resets)The skipped frames left irregular double-length gaps. That's why a frame cap (
LEONIDA_FG_LIMIT_FPS=30) didn't help. A possible side effect of turning resets off is warping on a generated frame at a camera cut.2. VRAM. On Series X, texture storage grew to 4.0 GB. Frame generation needs about 1 GB more that DXGI's budget doesn't count. The card filled up and the kernel logged
nvidia-drm: Failed to allocate NVKMS video memory, then Xid 109 / Xid 31 and a device-removed crash (0x887A0005). Windows spills over-budget VRAM into system RAM (see #2821); here the driver failed allocations instead. WithLEONIDA_TEXTURE_BUDGET_MB=2048, after about 10 minutes:3. Frame rates (Mandy's log; FG doubles each):
Setup
Needs:
dxgianddxvk-nvapi; the bundled VKD3D-Proton 3.1 crashed NVIDIA's shader compiler.nvngx.dll/_nvngx.dll(in/usr/lib/nvidia/wine/on Arch-based systems).rustandcargo-xwin.d3dcompiler_47.dll(x64, the one winetricks ships). Wine's builtin compiler can't compile Mandy's helper shaders, which leaves the world black.Failed to insert new mapping nodelines. With the texture cap, VRAM shouldn't fill, but the patch is a safety net.1. Clone Mandy and get NVIDIA's SDK files. Use the layout of
d3d12/scripts/get-nvidia-sdks.ps1: DLSSv310.9.16from github.com/NVIDIA/DLSS and Streamlinev2.14.16from github.com/NVIDIA-RTX/Streamline.2. Apply the Wine frame-generation patch (below). Streamline only enables DLSS-G when hardware GPU scheduling is on. Wine 11.23 doesn't report it, so you get
eErrorOSDisabledHWS; Proton's Wine has a patch for this. This patch answers that one query as "on" under Wine and passes every other query through unchanged (LEONIDA_FG_WINE_HWS=0turns it off).3. Build:
--profile playwithdiagnosticsis needed: most of the settings below are diagnostics switches.4. Launch with the script below. Set
GAMEto your dump's path. The first start translates shaders, which takes a while.Why each setting
LEONIDA_FG_RESET_STALE=0LEONIDA_TEXTURE_BUDGET_MB=2048LEONIDA_FRAME_GEN=2,UPSCALE=dlss,RENDER_SCALE=0.6667,OUTPUT=2560x1440LEONIDA_FG_LIMIT_FPS=0automeasured the loading screen and locked the intro at 12 fpsLEONIDA_WINDOWS_BAR_MB=0play-nvidia.ps1puts up to 3 GB here on PCs with <48 GB RAM, and that comes out of VRAMLEONIDA_TITLE_RANGE=0XMemVirtualAlloc ... miss=Refused, thousands per run) and the picture looked washed outLEONIDA_PIPELINE_WAIT_MS=250play-linux.sh's 10000 froze the game for seconds when a new pipeline was builtdxgi+hideNvidiaGpu = Falsedxgicrashed at startup. DXVK reports NVIDIA cards as AMD by defaultdxvk-nvapi+nvngx+NGXCoreregistry keyPROTON_ENABLE_NVAPI)WINEDEBUG=fixme-allLEONIDA_*play-nvidia.ps1's play set as ofb41763227, copied as is (it halved the per-frame refresh time). The only change is BAR 0Reflex stays on: without it, DLSS-G turns itself off after a few seconds (
eFailReflexNotDetectedAtRuntime).Launcher script
fg-wine-scheduling.patch
For the devs
FG_RESET_STALE: under Wine, a large share of gameplay presents (15–33%) arrive without a fresh upscale. I don't know why, but resetting DLSS-G on all of them (and on the present after) costs a third of the generated frames and makes the pacing uneven. Maybe default it off on Linux, or only reset on real cuts?resource.rsroom()/ keep policy). On Series X + FG, blocks reached 4.0 GB while only 1.4–1.6 GB of textures were in them. An absolute cap works around it.