Skip to content

Retail Game potentially overcomitting VRAM - feasibility for 8GB VRAM cards? #320

Backlog

Description

@jvyden

Game and package version

The retail title - 1.0.2.1

What happens

I've noticed that the game commits quite a high amount of VRAM - 6.4GB on a 8GB card. This results in a lot of CPU traffic, almost 1GiB/s TX according to nvtop:

    PID   USER DEV     TYPE  GPU        GPU MEM    CPU  HOST MEM Command                                                                                                                                                                    
 197173 jvyden   0  Graphic N/A    6409MiB  78%    86%   7736MiB game_scarlett_master.exe 

VIctory, another emulator with the same goal, consumes significantly less VRAM, only about 4.7gb on the same game:

    PID   USER DEV     TYPE  GPU        GPU MEM    CPU  HOST MEM Command                                                                                                                                                                    
 196353 jvyden   0  Graphic  15%   4755MiB  58%     9%   3364MiB /run/host/work/victory-linux/victory.exe run game_scarlett_master.exe --execute  

Is there hope for this game on Turing cards or cards with low VRAM, especially considering the Xbox Series X only has ~10gb of RAM total? What causes the allocation difference?

XCL version

4017f8f with #128 and #283 applied

GPU and driver version

NVIDIA GeForce RTX 2080 Rev. A 615.78.8.0 (2580775424)

Windows version

Arch Linux x86_64

report.json and xcl.log

xcl.log
report.json
xcl.prev.log
report.prev.json

Console output

This log is way too long to fit. It should all be in xcl.log if I'm not mistaken.

Activity

  1. added
    bug
    on Nov 23, 2026
  2. ivall commented on Nov 23, 2026

    @ivall
    Collaborator

    Known and being worked on. Two parts: textures kept in step with the title's memory got a PC copy per placement that was never let go (#248) - #288, which backs them with shared video-memory pages, is being merged now and roughly halves the growth while the world streams; and GPU-owned targets already share pages per address since 38b05b7. Some of the rest is XCL's own (the coherent window, sparse pools). Whether 8 GB cards will be enough is not settled yet; a run of current main after #288 lands would be a useful data point.

  3. jvyden commented on Nov 23, 2026

    @jvyden
    Author

    Hmm, seems roughly the same on the latest version at the first screen, maybe about a ~100MB VRAM improvement:

        PID   USER DEV     TYPE  GPU        GPU MEM    CPU  HOST MEM Command                                                                                                                                                                    
     206939 jvyden   0  Graphic   0%   6329MiB  77%   212%   8091MiB game_scarlett_master.exe
    

    I do also have #335 applied though for Linux fixes but after looking at the code that shouldn't cause a difference in VRAM usage.

  4. CuteBooty commented on Nov 24, 2026

    @CuteBooty

    Data point for an 8 GB card on Windows. Edited: three corrections, and runs past the menus added.

    Setup: RTX 3070 8 GB (32-lane waves), NVIDIA 617.14 for the first-menu runs and 621.24 for the world-loading runs (driver updated in between); Ryzen 5 3600, 32 GB RAM; Windows 11 Pro 26200; rustc 1.100.0 MSVC; release builds; the same title and package version as this report; XCL_NETWORK=0 and a firewall block.

    Corrections to the first version

    First menu, main 2997c9a, scripts\smoke.ps1 -Seconds 60: run 1 (first run here): 543 frames, peak commit 15351 MB, video memory 6453 MB local / 1035 MB non-local. Run 2: 903 frames, 14535 MB, 6080 / 4619 MB. No device removal, no crash.

    World loading (A pressed by XCL_PRESS_AT every 6 s from 24 to 198 s; XCL_ACTIVITY=1; region sizes from VirtualQueryEx, GPU figures from Windows' "GPU Process Memory" counters):

    main 508a0c7, 4 runs main 3db536e (adds #435, #451, #300), 2 runs
    loading starts (500+ DirectStorage requests in 2 s) 216–254 s 42 s
    process commit with 8.5–8.6 GB of target pages 32.8–33.5 GB 24.6 GB
    of it in 1–16 MB heap allocations (one 508a0c7 run, both 3db536e runs) 10.2 GB (382 s) 1.1–1.2 GB (75–91 s)
    end of the run closed by my script at 348–388 s (under 4 GB of commit free) 132 and 133 s: the title's write to 0 at +0x23cf683 (#505)

    Not tested: #435 alone; a cold shader cache with fewer DXC threads.

    AI use: Claude Code made the runs with me present and wrote this: Claude Fable 5.2 the first version, Claude Opus 5.5 this edit.

  5. 3L1A5-1 commented on Nov 24, 2026

    @3L1A5-1

    Follow-up to my comment above: what the growth during world loading is made of. Same machine (RTX 2060 SUPER 8 GB, 617.14; i5-9400F; 16 GB RAM; Windows 11 26300), main 508a0c7 plus a local diagnostic patch (not for a PR): every XCL_ACTIVITY tick it also prints, from vram::Pages, the targets by state, pages in use vs idle, the most targets on one page, and counters bumped in place_on_pages (placed), forget_pages (released) and unmap_superseded (superseded). Release build, XCL_NETWORK=0, keyboard through the menus, then the world loads behind the black screen.

    t commit video memory local target pages live targets (mapped) placed released superseded pages busy / idle extra pages busy
    266 s (menus) 15.8 GB 6.6 GB 3.6 GB 1,547 (1,505) 1,549 2 42 55,745 / 0 1,818
    291 s (loading starts) 17.2 GB 7.6 GB 4.6 GB 16,902 (16,476) 16,904 2 426 56,610 / 0 16,362
    339 s 21.0 GB 8.8 GB 5.1 GB 21,197 (17,858) 21,208 11 3,340 64,440 / 0 16,703
    387 s 25.8 GB 11.3 GB 7.4 GB 28,729 (20,561) 28,740 11 8,169 100,528 / 0 17,231
    • In 6.5 minutes the title placed 28,740 GPU-owned textures on pages; res_release reached vram::forget for 11 of them. There are never idle pages: every page is held by a live, mapped target (1-6 targets per page). The mapped ones are mostly small (178,180 tiles over 20,561 targets, ~9 tiles each; the biggest 57 MB).
    • So the target pages only go back when a target is released or superseded by another GPU-owned placement, and for most of them neither happens: the pool grows with every streamed texture. Arenas stay flat (397 MB), sparse pools add ~0.8 GB.
    • On this 8 GB card, local video memory passes 8 GB at ~330 s, and the frame rate during loading drops from there; on 16 GB RAM the process runs out of commit (my run was stopped at 394 s).

    Not measured: who holds the references. The title may keep these objects (a texture streamer that keeps one per resident texture and reuses the memory underneath, which costs nothing on the console), or something holds an extra reference. If it's the former, the pages of a target whose memory the title has since used for something else are never given back. I haven't checked whether the title frees, decommits or reuses those addresses.

    Report written with Claude Code (Claude Opus 5.5) from these runs.

  6. MonkeyPython commented on Nov 24, 2026

    @MonkeyPython

    12 GB data point on current main (the maintainer ask: "a run of current main after #288 lands would be a useful data point"): the title's video-memory shape fits in 12 GB through the loading phase — no E_OUTOFMEMORY from video memory — but system RAM, not VRAM, is the binding constraint on a 32 GB machine.

    Setup: Windows 11 Pro 26300, Ryzen 7 7800X3D, 32 GB, RTX 3080 Ti 12 GB (driver 621.01), main 508a0c7, release, XCL_NETWORK=0 + firewall, GTA VI Series 1.0.2.1, 3840×2160. Scripted menu walk into loading; 266 s run ended in the #232 null write (not a memory failure).

    Video memory: coherent 3998/4095 MB, sparse 7445 MB, 99 blocks held for 98 allocators at the end; zero 0x8007000e, zero refused CreateHeap/CreatePlacedResourceX, zero no video memory lines. The sparse 7445 MB alone is ~7.3 GB — it fits in 12 GB with room for the rest, would be tight on 8 GB (this issue's 3070 point: 6453 MB local + 1035 MB non-local), and does not fit in 6 GB (#345).

    System memory (the actual pressure): xcl private commit 14.8 GB at t=122 s → 39.5 GB at t=274 s; free physical RAM 10.3 → 0.09 GB; window at 0.0 FPS with 5 running, 2 done, 58646 pipelines queued at t=254 s. The #542 thread-count-vs-memory shape, on 15 DXC threads (8C/16T). A follow-up run with XCL_DXC_THREADS=4 is in progress and will be reported in #542.

    Not tested: 8 GB cards directly, other titles, longer gameplay soaks.

    AI use: Gentle Shell (Pi coding agent), model qwen4-max: ran the title with scripted input and wrote this report from the logs and memory samples; a human reviews it before posting. No code changes.

  7. Ege-Mert commented on Nov 24, 2026

    @Ege-Mert

    A 6 GB data point: the menus, and (edited in) the first world load.

    Setup: RTX 3060 Laptop 6 GB (5994 MiB), driver 596.21 (32.0.15.9621), wave32; i5-12450H, 32 GB RAM; Windows 11 Pro 26200; release builds, Rust 1.100.0, DXC 1.9.2602.17. The same retail title, Series X profile, 3840×2160, XCL_NETWORK=0 XCL_ACTIVITY=1 XCL_DXC_THREADS=4, the process limited to 4 logical CPUs. No input, so each run sits at the title's first prompt: 180 s, exit 0, no crash, no device removal.

    Local video memory at the first prompt (MB, steady; from the XCL_ACTIVITY memory line; "other" = local − target-page pools − arenas − sparse pools):

    main coherent window local target-page pools arenas sparse pools other non-local
    db1ddb2 (before #288) 512 MB 6686 3264 397 896 2129 1103
    2b4bb43 (#288) 512 MB 6519 3584 397 896 1642 1102
    beaa245 512 MB 6586 3584 461 896 1645 1358
    beaa245 4095 MB (learned) 6211 3584 465 896 1266 4945
    • D3D12.X: back kept-in-step title textures by shared VRAM pages (#248) #288 took 167 MB off at this prompt (pools +320 MB, other −487 MB), the same to within 1 MB over repeated runs. The learned coherent window takes another 375 MB off compared with 512 MB.
    • So the floor on current main is about 6.2 GB before anything streams: 58 % target-page pools, 20 % other, 14 % sparse pools, 7 % arenas. The pools go from under 1 GB to 3.6 GB in about ten seconds (30 s to 40 s in the 512 MB run), when the title sets up its renderer.
    • That is still over a 6 GB card (nvidia-smi shows it full), and yet with the learned window the title holds its 30 fps here: a 360 s run through the first-run setup screens stayed at 60 presents per 2 s from 24 s to the end, with 6342 MB local and 15.1 GB of commit. On db1ddb2 Windows' counters showed 5588 MB dedicated and 2175 MB shared for the process at the same prompt, so roughly 1 GB of "local" was in system memory.
    • On this machine the frame rate changed with the coherent window (512 MB: 10–14 presents per 2 s, with more video memory in use than the learned window's 60). Numbers for that are better placed in First run of a title: the coherent window is 512 MB until uma_coherent.txt has been learned (menus at ~12 fps, then 30) #284.

    Edit: the first world load (main 1c87b1d, by now on Windows 11 26H2 26300.9974; learned window; scripted presses through the first-run setup into the load; a watchdog of mine ends the run at 25 GB of private bytes):

    time process commit local target-page pools sparse pools presents per 2 s
    85 s last menu 15.1 GB 6341 3648 960 60
    103–117 s loading screen, first step done 16.4 GB 7366 4608 1024 60
    127 s the world streams 19.4 GB 8858 5312 1792 18
    139 s 23.8 GB 12 349 8640 1856 0–2
    161 s ended by the watchdog 25.6 GB 12 835 9024 1856 0–14

    Not tested: the Series S profile on these commits; each world-loading configuration more than once.

    AI use: Claude Code (Claude Fable 5.2) ran the builds and the runs, read XCL's logs and wrote this comment and its edit; the numbers are from the runs above on this machine.

  8. Rednaxeh commented on Nov 24, 2026

    @Rednaxeh
    Contributor

    A 16 GB AMD data point for the world load, from the runs I posted on #232 / #891 (RX 7800 XT 16 GB, driver 32.0.32029.2010, Ryzen 7 7800X3D, 32 GB RAM, Windows 11 26300, release, XCL_NETWORK=0, numbers from XCL's memory: lines):

    build where the run ends local video memory at 60 / 70 / 80 s peak local non-local peak commit
    main 1c87b1d watchdog at 105 s, world loading not finished 11.7 / 13.0 / 13.9 GB 13.9 GB 4.8 GB 28.9 GB
    #891 without its variable (= main's path) watchdog at 107 s 11.7 / 12.9 / 20.6 GB 20.6 GB 4.8 GB 36.7 GB
    #891 with XCL_PSO_WAIT_MS=50, two runs (loading completes) device hung at 102 / 105 s 12.1 / 13.2 / 22.2 GB and 12.2 / 13.0 / 22.1 GB 22.9 / 22.8 GB 4.8 GB 37.0 / 39.5 GB

    So on this card the title's video-memory shape passes 16 GB between 70 and 80 s of the run – the moment the loading art fades and presents stop – in every run that gets that far, and settles at ~22 GB once the loading is through: ~6 GB over the card, which the driver pages (the non-local 4.8 GB is the part it already keeps in system memory). No E_OUTOFMEMORY here; the runs end in the watchdog or, with the budget, in a GPU hang (#891). Commit is 37–40 GB on 32 GB of RAM at that point.

    AI use: Claude Code (Claude Fable 5.1) pulled the numbers from the logs and wrote this; the runs were mine.

  9. ArturoWolff commented on Nov 24, 2026

    @ArturoWolff

    Linux / RTX 4060 8 GB, 16 GB system RAM, NVIDIA 620.73.04, GE-Proton11-14, retail 1.0.2.1, release build of unmodified main 47efa2ecea0a12934719ae69b81930cf02a4b1c3. Two separate observations:

    • During a Series X world-loading run (XCL_COHERENT_MB=512, XCL_RAYTRACING=off), systemd recorded a kernel OOM kill in the game unit after 3m28s. The unit had no MemoryMax or MemoryHigh. Its reported peaks were 8.4 GiB memory and 8.5 GiB swap; those are separate maxima. At 180.828s XCL reported target pages 8793 MiB / 8832 MiB pool capacity and sparse pages 1876 MiB mapped / 1920 MiB pool capacity. Those counters are not a physical VRAM total. No OPTIONS5 ray-tracing tier query was logged: the setting does not establish that the title disabled RT. Loading art only, no controllable world. This identifies the OS stop, not the allocation that triggered it.
    • On the same XCL binary and Series X profile, reporting an 8192 MiB title budget instead of the 13824 MiB default did not shrink allocations at the last exact matched DirectStorage checkpoint. At 22865 requests / 1271 MiB / 0 failures both runs reported target pages 4539 / 4608 MiB, sparse 1015 / 1024 MiB, and DXGI 6743 MiB local / 1926 MiB non-local. This is a matched sample, not a claim about every later allocation.

    The useful next measurement is how many target pages still have live owners when the pool grows, not just the difference between pool capacity and pages accounted for. No game data or dumps attached. AI use: Hermes Agent (gpt-6.2-astra), local trial execution, log comparison and draft.

  10. LocranKing commented on Nov 24, 2026

    @LocranKing

    A Windows 11 desktop 8 GB VRAM data point on clean main 9e3831e (menus through world streaming).

    Setup

    • GPU: NVIDIA GeForce RTX 3060 Ti (8024 MiB VRAM, wave32), driver 32.0.16.2101
    • CPU / RAM: AMD Ryzen 5 5500 (6C/12T), 31.8 GB RAM
    • OS: Windows 11 Home Single Language, build 26200
    • Build: clean main 9e3831e1f570d3646e53ab753b19ec07eb8f1485, --release, DXC 1.9.2602.17, retail 1.0.2.1 (UMA: 3 sparse VRAM window(s) (12 GiB VA) + 4095 MB coherent window at 0x400000000).
    • Flags: XCL_NETWORK=0 XCL_ACTIVITY=1; world-load runs also set XCL_PSO_PRELOAD=0 and XCL_PRESS_A_AT every 4 s from 20 s to 80 s (+ 90, 100).

    Memory progression from XCL_ACTIVITY memory: lines (MB):

    stage / run time committed local VRAM non-local target pages (pools) arenas sparse pools (mapped) outcome
    60 s smoke (default, menus) 58 s 14,715 6,147 4,876 3,578 (3,584) 465 896 (837) exit 0x0, 30.0 fps (1566 frames)
    60 s smoke (XCL_HEAP_WINDOWS=1, menus) 58 s 14,718 6,144 4,876 3,577 (3,584) 465 896 (837) exit 0x0, 30.0 fps (1570 frames)
    world load, account/pre-stream plateau 58–90 s 16,534–16,569 7,298–7,303 4,875–4,876 4,550–4,551 (4,608) 465 1,024 (1,013) 30.0 fps
    world load (default, peak) 132 s 23,198 11,007 4,894 7,070 (7,360) 465 1,856 (1,797) 0x887a0006 device removed at 133.8 s
    world load (XCL_HEAP_WINDOWS=1 + XCL_PSO_WAIT_MS=50, peak) 88 s 24,395 12,429 4,894 8,439 (8,832) 465 1,792 (1,777) 0x887a0006 device removed at 89.8 s
    world load (XCL_HEAP_WINDOWS=1, peak) 180–197 s 28,579 14,008 4,896 9,700 (10,048) 465 2,048 (2,043) +0x23cf683 watchdog at 195.8 s (0 device removals)
    world load (XCL_PSO_WAIT_MS=50, peak) 174–205 s 30,799 14,446 4,929 9,900 (10,176) 465 2,304 (2,266) +0x23cf683 watchdog at 204.8 s (0 device removals)

    Observations for 8 GB cards on Windows 11:

    • Menus fit comfortably inside 8 GB (~6.14 GB local, 4.88 GB non-local, 14.7 GB commit, steady 30 fps).
    • World streaming pushes local video memory to 14.0–14.4 GB (~1.8× physical VRAM), driven primarily by target pages growing from 3.58 GB to 9.90 / 10.18 GB and sparse pools from 0.90 GB to 2.30 GB (arenas stayed flat at 465 MB, non-local at 4.88–4.93 GB).
    • Windows WDDM paged that ~14.4 GB local allocation without E_OUTOFMEMORY in two of the four runs, but process commit climbed to 28.6–30.8 GB on a 31.8 GB RAM machine (leaving very little headroom even with XCL_PSO_PRELOAD=0), and the other two runs hit DXGI_ERROR_DEVICE_HUNG (0x887a0006) during texture copies/uploads at 11.0–12.4 GB local VRAM.

    Not tested: XCL_COHERENT_MB reduced below 4095 MB, Series S profile, Linux/Proton, repeats per configuration.

    AI use: Antigravity (Gemini 4 Neon) ran these builds and parsed the logs on this machine and drafted this comment; reviewed before posting. No game files attached.

  11. added
    goal:world-load
    on Nov 24, 2026
  12. iggyvilla commented on Nov 25, 2026

    @iggyvilla
    Collaborator

    Data point for the 8 GB question, on a discrete AMD card: main 930e8b4, release build, XCL_NETWORK=0 XCL_ACTIVITY=1, a scripted first-run walk into the world load (gamepad presses through the account/legal screens), retail title.

    Tested

    • AMD Radeon RX 6650 XT 8 GB (RDNA2), Windows 10.0.26300, title on an NVMe, no overlay (no OBS hook) in the process.
    • Through the intro and legal screens (28-92 s; Legal Notices on screen at 70 s) it holds at video memory 6,602 MB local / 4,733 MB non-local, of which XCL's tiled-texture pools are 3,712 MB (3,624 MB of pages in use), arenas 311 MB and sparse pools 960 MB; process commit 16.4 GB.
    • The loading spinner appears at about 100 s and the streaming starts. By 192 s: target pages 9,729 MB (pools 9,920 MB), sparse pools 1,984 MB, local video memory 14,994 MB (about twice the card; QueryVideoMemoryInfo counts what WDDM keeps in system memory), non-local 4,775 MB, commit 29.9 GB, 33.3 GB at the end.
    • 0 "no video memory" lines, 0 refused CreateHeap, no device removal. Nothing in XCL refuses or caps the growth (no XCL_PAGE_BUDGET_MB set).
    • The run stops at 211.8 s with an access violation, write at address 0x0, game_scarlett_master.exe+0x23cf683 (the title's own watchdog report: +0x2215c35 is in its watchdog thread, which writes to 0 after 30 one-second ticks without progress), after 421 compute pipelines had been built (the slowest 47.5 s, 37.1 s and 27.2 s, all finished by 134 s; the last at 194 s). Frames drop from 60 per 2 s to 0-46 from about 116 s and are 0 from 184 s to the stop, so the main thread was held for ~28 s; with the last pipeline built at 194 s, memory pressure is at least as likely a cause of that hold as pipeline builds. The signature is the one recorded for Newer retail title (TitleID 7952987A): reaches world loading, then the title's GPU watchdog ("GPU Loc Sig") after ListX #101 stub #505 / Retail title: black screen and reproducible access violation when entering gameplay #581.

    Reading: on this 8 GB card the title is already at 6.6 GB local through the intro/legal screens and needs about 9.7 GB of target pages (15 GB local, counting what Windows demotes) by 190 s of the world load, so 8 GB does not hold it as things are. What ends this run is the +0x23cf683 access violation (#505 / #581 signature), not a refused allocation, so it is not a clean "out of memory" row.

    Not tested

    AI use

    • Claude Code, Claude Sonnet 5.5, ran the walk and wrote this comment from the run's log and screenshots; a second Claude Code session (Claude Sonnet 5.5) checked it against them.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    buggoal:world-load

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions