Repository navigation
docs: the retail boot chain, what stops gta6rt --run in order (RT-5 measurement) - #6915
Conversation
…easurement) Ten stops measured on one Windows + RTX 4090 run with six open PRs merged locally: which PR clears each, the physical-page export shapes, and the three device slots whose Xbox shape differs from the PC (26 struct return with the buffer first, 48 queue creation, 73 list creation). Counts, export names and slot shapes only; no addresses, IID values or bytes from the executable. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…3), review nits Placeholder reserves through XMemVirtualAlloc, the physical sub-ranges carved out of them, device slot 133 (a resource placed at a VA) and the current stop at the first descriptor heap. Cites ItsNotRexed#6715 and wraps the long line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Independent reproduction of this chain on Linux under Wine: own 1.0.2.1 copy, Wine 11.21, RTX 4070 Laptop (Vulkan), Same stops in the same order, 1 to 13, and the same current stop: the first descriptor heap's CPU start is asserted against the value the title already holds. Same counts at that point: 5 queues, 5 fences, 7 allocators, 581 command lists created and closed, about 1,180 D3D12 trace lines. Stop 10/11 placeholders work under Wine through Two stops are specific to this setup. They come before stop 3 and stop 7:
Device slot 78 and 79 calls also arrive just before the shader-cache and descriptor work: two calls of slot 79 and one of slot 78. Forwarded by number they land on PC AI-assisted. |
thiefyzheng
left a comment
There was a problem hiding this comment.
Read + local run (AI-assisted review, per AGENTS.md). This is the most useful page I have seen on the boot state — one stop at a time, each with the PR that clears it, and §5's "what this does not show" keeps it honest about the local stand-ins.
Verified
- Applies cleanly to current
main(2 files, new page + its README row). python -m pytest -q tests/test_docs_links.py-> 6 passed.- Every
§-reference in the stops table resolves: §2 and §3.1–§3.4 are the actual headings (## 2. Physical pages,### 3.1 ……### 3.4 Device slot 133 …), so the table is navigable rather than pointing at nothing.
One mismatch, in the README row only
docs/README.md:63 summarises the page as "…and device slots 26, 48 and 73", but the page also documents slot 133 (§3.4, "Device slot 133 places a resource at a virtual address") — and slot 133 is stop 12 of the 13, i.e. a stop the reader is being sent to this page for:
| [retail_boot_chain.md](retail_boot_chain.md) | … the physical-page export shapes, and device slots 26, 48 and 73. |Suggest slots 26, 48, 73 and 133. That is the whole of my review — the page body itself is consistent (the counts at stop 13, the 581 command lists, the "128-slot table" explanation and the slot-9 hypothesis all read as measured rather than inferred).
One thing I would keep when this page grows: stop 13's hypothesis is currently the only unmeasured step, and saying so explicitly ("Hypothesis:") is what makes the rest trustworthy. If a later edit turns it into a statement before the descriptor model answers boot.md Q4, the page loses that property.
shayderrr
left a comment
There was a problem hiding this comment.
Summary
Adds docs/retail_boot_chain.md (102 lines) plus its docs/README.md row. The page records a measured gta6rt --run on the retail executable: thirteen ordered stops, each with the merged PR or local stand-in that clears it. Section 2 gives inferred signatures for XMemAllocatePhysicalPages, XMemMapPhysicalPages, XMemMapPhysicalPagesScatter and XMemFreePhysicalPages and a pagefile-based CPU stand-in. Section 3 documents device slot 26's ret-buffer-first struct return, slot 48's command queue from a PC D3D12_COMMAND_QUEUE_DESC prefix, slot 73's console-list IID (581 lists via #2490's proxy), placeholder reserves with MEM_REPLACE_PLACEHOLDER, and slot 133's CreatePlacedResourceX shape. Stop 13 is a descriptor-heap CPU-start assert.
Why merge
Directly serves static recompilation and executable analysis: it saves RT-5 owners and xmem/d3d12_xs authors from remeasuring the call shapes and boot order. Docs-only, new file, no overlap with open PRs.
Verdict: Approve
SummaryAdds Why mergeDirectly serves static recompilation and executable analysis: it saves RT-5 owners and xmem/d3d12_xs authors from remeasuring the call shapes and boot order. Docs-only, new file, no overlap with open PRs. Verdict: Approve |
…e and placeholder calls through gta6rt --run tiny_xmem_physical imports xmem.dll like the title and makes the calls ItsNotRexed#6915 measured after the first allocations, with synthetic sizes and no game data: - XMemAllocatePhysicalPages(0x280) with the count read back, a reserve-only MEM_PHYSICAL | MEM_LARGE_PAGES window, XMemMapPhysicalPages into it, an unmap by null array, a remap in another order (a page keeps its contents) and XMemMapPhysicalPagesScatter; - a 185 MiB MEM_RESERVE | MEM_RESERVE_PLACEHOLDER reserve with attribute 7 and PAGE_NOACCESS, five ranges carved out of it with MEM_REPLACE_PLACEHOLDER | MEM_PHYSICAL | MEM_LARGE_PAGES at addresses inside it, a second batch of physical pages mapped into them, and the rest of the placeholder still reserved. It checks only what the title can observe (results, counts, addresses, memory contents), so any xmem implementation can be run against it. xmem_stub gains the four physical-page exports for the link. The fixture's own logic was run on Linux against an mmap/memfd emulation of the five calls (passes; fails when the emulation maps the wrong page). The Windows build and the run under gta6rt are left to CI. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UkEUa9YfGQH4p9g1Guw9gq
… not import the title's pages RADV under Wine refuses to import a view of a pagefile-backed section (E_OUTOFMEMORY on an RX 9070 XT, found in review), which is the form xmem's physical pages take, so the retail boot stopped at the first 174 MiB placement. An import failure other than a misaligned VA now gives an ordinary DEFAULT buffer of the same description, as ItsNotRexed#6915's stand-in did, logged once: the boot goes on, and the title's writes at that VA don't reach it on such a driver. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claimed in the coordination issue as: RT-5 measurement (data for its owners, not a claim; the finding was posted on #6750 first)
Depends on: none to merge (docs only). It describes a run with #6709, #4531, #6582, #4313, #4348 and #2490 merged locally.
What and why
Adds
docs/retail_boot_chain.mdand its row indocs/README.md. The page records how fargta6rt --rungets with the retail executable on Windows. It lists the thirteen stops in order and, for each, the PR that clears it or the local stand-in used. It also gives the call shapes behind them, so RT-5's owners and the xmem/d3d12_xs authors don't have to measure them again:XMemAllocatePhysicalPages,XMemMapPhysicalPages,XMemMapPhysicalPagesScatterandXMemFreePhysicalPages, and a placeholder-based CPU stand-in that gets past them.(ret, this, …).D3D12_COMMAND_QUEUE_DESCprefix followed by Xbox words.XMemVirtualAllocwithMEM_RESERVE_PLACEHOLDER, then physical sub-ranges carved out withMEM_REPLACE_PLACEHOLDER.CreatePlacedResourceX), and the proxy's 128-slot table turned that call into a null call.New file, so it doesn't conflict with the open PRs on
docs/boot.md.Tested
LEONIDA_D3D12=vulkan, an MSVC 2022 RelWithDebInfo build, and main1cc6e3c12plus the PRs above, from my own 1.0.2.1 copy.python -m pytest tests/test_docs_links.pypasses.AI-assisted: yes (Claude Code)
Checklist
docs/design.md, with how it was confirmed. (n/a: no translator change)🤖 Generated with Claude Code