Skip to content

docs: FSR DLL list slots 54/55/59/85, pipeline slot 11 and the device +0x18 copy switch - #2

Closed
CLHelper wants to merge 1 commit into
mainfrom
docs/console-list-fsr-slots
Closed

CLHelper wants to merge 1 commit into
mainfrom
docs/console-list-fsr-slots

Conversation

@CLHelper

Copy link
Copy Markdown
Owner

Review draft inside the fork; not submitted upstream. Remove this block and the "Before submitting upstream" section when the PR is opened against ItsNotRexed/Leonida.

Claimed as

Not claimed yet. CONTRIBUTING requires a claim in the open "Coordinating who works on what" issue before an upstream pull request; that has not been posted. D3D work should also be mentioned on ItsNotRexed#313.

Independent of the builder-slots PR (#1): no shared lines, and the two merge cleanly in either order (checked with git merge-tree). No Depends on.

What and why

Docs only: docs/d3d12_command_objects.md §3.5a. No code, no tests, no game data (RVAs, offsets, constants and short register excerpts only).

§3.5a maps the FSR DLL's console command list but leaves slots 54, 55 and 59 out, reads slot 85 as (stack pointer, 0, 0), gives slot 141's fourth argument as n, and notes the slot-24 CopyDescriptorsSimple path as "not taken in this run" without saying what selects it. A static reading of the call sites fills these in:

Item What it adds Label
List slot 54 (+0x1b0) → PC 50 ClearUnorderedAccessViewFloat: six arguments at 0x7296, chosen over the slot-53 call at 0x72ee by a compare with 0x12; values passed in place, where the 53 path copies them to the stack shape
List slot 55 (+0x1b8) → PC 51 DiscardResource(resource, null) at 0x6dcb shape
List slot 59 (+0x1d8) console only: (1, blob, size) at two sites and (0, &qword 1, 8) at two others, first argument a byte. It looks like one slot for both ends of a GPU event. With 55 at +4 and 61 at +2, the two missing slots are among 56–60 shape only, no name
List slot 85 (+0x2a8) correction: six arguments (&dst, 0, 0, 0, &src, null), the public CopyTextureRegion shape with two copy locations, not one pointer. Buffer to texture (src a placed footprint from device slot 38) at 0x7147, texture to texture at 0x7191. The run's (stack pointer, 0, 0) is the first three of these inferred name
Pipeline slot 11 console-only method (the public ID3D12PipelineState ends at 8), called on every new pipeline at 0x586d: (0, 0, &obj), a dword through obj slot 3, × 1024, kept per pipeline, maximum per context calls and arithmetic measured; units open
List slot 141 fourth argument = the bound pipeline's slot-11 value; skipped when 0. Scratch buffer = largest value × 0xd0, rounded up to 64 KiB, device slot 27 in UNORDERED_ACCESS measured; 0xd0 and the leading 2 open
Device byte +0x18 read before each descriptor copy (four sites): 0 → the DLL copies 32 bytes between CPU handles itself; set → device slot 24 CopyDescriptorsSimple(1, dst, src, 0). A device proxy that sets the byte sees the copies as calls measured

Why it matters here: the console-order list proxy in ItsNotRexed#1325 refuses slot 85 as unmapped; this gives it a shape it can forward. The +0x18 byte gives the device proxy a switch that makes this DLL's descriptor copies visible.

What is not done

  • Not tested at runtime. No proxy run, no CTest, no build: static disassembly only. The slots 54, 55 and 59 are not reached by the existing fsr_dispatch_test run; 85 is, but the run logs only three arguments.
  • No names where only the shape exists: 59 stays unnamed; 85 is the CopyTextureRegion shape, but what console slot 16 is remains open, as does whether 85 takes a seventh argument (the caller clears that stack slot).
  • Open: what the pipeline-slot-11 object is, the unit of its dword, the factor 0xd0, the leading 2 of slot 141, and what the 0x12 compare in front of slot 54 tests.
  • Not touched, to avoid overlapping the builder-slots PR: d3d12_vulkan.md §8.2 Q2 and the §4.3 Open list should also list 54/55/59 and the 85 correction. That is a small follow-up after both PRs land.
  • Based on f85582e2; merges cleanly onto current main. Not rebased.

Tested

Docs only. Every RVA, register and constant was re-read at instruction level in a static disassembly of the shipped amd_fidelityfx_upscaler_xbox.dll (package 1.0.2.1, image base 0x180000000); D3D12_TEXTURE_COPY_LOCATION and CopyTextureRegion layouts per SDK 10.0.26100 d3d12.h. Nothing was run. No GPU involved.

AI-assisted (Claude Code).

Before submitting upstream (checklist for the reviewer)

🤖 Generated with Claude Code

… +0x18 copy switch

Static reading of the FSR DLL's call sites, added to section 3.5a:

- 54 is ClearUnorderedAccessViewFloat and 55 DiscardResource (both +4).
- 59 is one console slot with a bool first argument, used for both ends of a
  GPU event; the two slots the console lacks are among 56-60.
- 85 takes the six CopyTextureRegion arguments (two copy locations), not one
  pointer: buffer-to-texture with a footprint from device slot 38, or
  texture-to-texture.
- Pipeline slot 11 (console-only) gives a per-pipeline scratch value; the
  largest times 0xd0 sizes FFX_XBox_ComputeScratch, and slot 141's fourth
  argument is the bound pipeline's value.
- A byte at device +0x18 selects between the DLL's own 32-byte descriptor
  copy and device slot 24 CopyDescriptorsSimple.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@CLHelper

Copy link
Copy Markdown
Owner Author

Review draft; submitted upstream as ItsNotRexed#1470.

@CLHelper CLHelper closed this Nov 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant