FSR: the shipping Xbox upscaler has one provider and one fixed configuration (static analysis, answers #302's open end)
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 20/100
- Issue 类型
- 文档
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
调研方向
Start with Appendix A.3 of docs/d3d12_vulkan.md, which the issue asks to extend with measured rows, and check them against game/xbox-1.0.2.1.json for the DLL hashes. For the test side, look at fsr_dispatch_test and its existing OutputDebugString redirect used by the BVH test. Done means the A.3 rows are added and the FSR test surfaces the DLL's refusal message; the work has no clear owner yet and needs maintainer sign-off before a newcomer starts.
由索引模型根据 Issue 内容生成。
描述
Why this is here
Appendix A.3 of docs/d3d12_vulkan.md stops at the PE tables for amd_fidelityfx_upscaler_xbox.dll, and #302 records the open end: ffxCreateContext "returns ERROR without touching the device for every backend descriptor tried: the Xbox one isn't public". I read the DLL's own code to find out what it accepts. The answer is that it carries exactly one provider and one configuration, and it prints the reason for every refusal.
Method
Static analysis only, Ghidra 12.2 on Linux, on our own 1.0.2.1 copy. The four DLLs were copied to a work folder outside the package first and checked against game/xbox-1.0.2.1.json by SHA-256 (upscaler faff02f2…, loader 431bdd2e…, XboxBvhBuilder.dll 99f803ac…, Bink2Scarlett.dll 9eaf045d…). Nothing was executed. Nothing from the DLLs is attached or quoted beyond the message text needed to describe behaviour. No keys, no decryption.
Measured
One provider, one effect. The module's TLS initialiser builds a two-record table and publishes it as a one-pointer registry: the registry spans 0x1800beb68 to 0x1800beb70, so it holds a single entry, and the provider record is named ffxProvider_FSR4_Int8. Its model record is named Fsr4Int8UpscalerModel and carries the version string 4.1.1 and an id word 0xf5a5ca1e01001001. There is no second backend in this DLL to try, which matches the "one provider, 4.1.1" line in #302.
Where the rejection happens. ffxCreateContext (0x1800011d0) walks the parameter chain for four keys (4, 5, 0x10009, 0x1000002), then for the provider calls vtable slot +0x8 with the device value and slot +0x10 with the version value. If neither accepts it returns 4. The DLL's own text names 4: FFX_API_RETURN_NO_PROVIDER (4), in a message that reads ... No device found in descriptor chain. For null-context queries to reach driver/external providers, chain an ffxCreateBackendDX12Desc (with device set) via header.pNext. So a chain that carries no device is refused before any device method runs, which is exactly the "without touching the device" symptom. Slot +0x18 is the create call, slot +0x0 the release.
One accepted configuration. The create path compares against literals and prints a different message for each mismatch:
| field | what the code compares | message |
|---|---|---|
| output resolution | 0x780 by 0x438 |
part of the must be %ux%u family |
renderSize |
0x500 by 0x2d0 |
Only the fixed Quality input geometry for this context's output resolution is included. |
upscaleSize |
must equal the output size | Shipping FSR4 configuration mismatch: %ls must be %ux%u; received %ux%u. %ls |
| flags, required | three separate bit tests | ... is missing FFX_UPSCALE_ENABLE_HIGH_DYNAMIC_RANGE, ... FFX_UPSCALE_ENABLE_DEPTH_INVERTED, ... FFX_UPSCALE_ENABLE_AUTO_EXPOSURE |
| flags, forbidden | one bit test | ... enables FFX_UPSCALE_ENABLE_DISPLAY_RESOLUTION_MOTION_VECTORS, but only the low-resolution motion-vector prepass permutation is included. |
| flags, anything else | mask test | Shipping FSR4 configuration mismatch: %ls contains unsupported flag bits 0x%08X. |
1920x1080 out from 1280x720 in, Quality, HDR, inverted depth, auto exposure, low-resolution motion vectors. That is the whole search space, which is the same configuration #302 found by probing.
Two pipeline sources, and a fallback that tells you which it used. The create path first looks for an ACCC part and builds compute PSOs by deserializing it, allocating with XMemAlloc; on each failure it logs a distinct line and falls back: no usable 'ACCC' part (extract result=%d) for '%ls' -- is this an ACO-cooked DLL? falling back to NewBE, XMemAlloc(%zu) FAILED ..., DeserializeComputePipelineStateX FAILED hr=0x%08X ... falling back to NewBE, and on success compute PSO created via ACO ('ACCC'). Two ASCII names, FFX_FSR4_XBOX_ACO and FFX_FSR4_XBOX_ACO_ACTIVE, sit near that code; I did not confirm they are environment variables, so I am not claiming it.
Every refusal is printed. Each mismatch formats a wide string and sends it to OutputDebugStringW with the prefix FSR_API_DEBUG_ERROR: , unless a callback pointer is installed at 0x1800beb60, in which case the DLL calls it with the message. A flag at 0x1800bc0a0 gates both. fsr_dispatch_test already redirects OutputDebugString for the BVH test, so wiring the same redirect into the FSR test turns the current single "returns ERROR" into the exact reason, with no new dependencies.
Not measured
The DLL was not run, so nothing here is a runtime trace. The offsets and slot numbers are the decompiler's reading of this build. I list the flag requirements by the DLL's messages rather than by bit position, because the decompiler showed bit tests inside the descriptor and I did not map each one to a published FFX_UPSCALE_* value.
Ask
If this is useful I can put it into docs/d3d12_vulkan.md A.3 as measured rows, in the style of A.2, and note the callback at 0x1800beb60 as the cheap way to get the DLL's own reason out of fsr_dispatch_test. Say the word and I will send a docs change.
AI-assisted (Halocline, a local model, in HADAL): it ran the analysis, read the decompiled functions and wrote this.
- 主要语言
- Python
- 星标
- 14.9k
- 派生
- 1.2k
- 平均合并
- 1 小时 58 分钟
- 30 天内合并 PR
- 40
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
ItsNotRexed/Leonida 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
ItsNotRexed/Leonida#3990 ·
维护者通常 1 天内回复
-
难度 3/5 半天 新手友好度 25/100
ItsNotRexed/Leonida#4257 · 18 条评论 ·
维护者通常 1 天内回复
-
Python SPIR-V assembler encodes BF16 constants as IEEE half可能已有人在做 @lumenpearson 今天认领。 未关闭bug
难度 3/5 半天 新手友好度 25/100
ItsNotRexed/Leonida#4237 ·
维护者通常 1 天内回复
-
SPIR-V reflection rejects Int8 array length constants可能已有人在做 @lumenpearson 今天认领。 未关闭bug
难度 3/5 半天 新手友好度 22/100
ItsNotRexed/Leonida#4221 ·
维护者通常 1 天内回复
-
Interrupted stub rebuild can truncate a valid SPIR-V output可能已有人在做 @lumenpearson 今天认领。 未关闭bug
难度 3/5 半天 新手友好度 18/100
ItsNotRexed/Leonida#4183 ·
维护者通常 1 天内回复
查看 ItsNotRexed/Leonida 的全部 Issue
相似的 Issue
-
pydanty:is-working
难度 2/5 1-3 小时 新手友好度 68/100
pydantic/pydantic-ai#14187 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 62/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 62/100
维护者通常 1 天内回复
-
[Bug]: legacy_json_to_doc crashes on persisted docs with "relationships": null可能已有人在做 @Harsh23Kashyap 今天认领。 未关闭
难度 1/5 1 小时以内 新手友好度 88/100
run-llama/llama_index#24392 ·
维护者通常 2 天内回复
-
难度 1/5 1 小时以内 新手友好度 72/100
pathintegral-institute/mcpm.sh#568 ·
维护者通常 21 天内回复