mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 21:30:53 +01:00
[PR #1862] [CLOSED] rdna2spirv: restore the dot4 inline op_sel_hi under exact re-anchoring too (SHADER-FSPX-DOT4-EXACT) #1874
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#1874
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?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/1862
Author: @Coderlord
Created: 11/25/2026
Status: ❌ Closed
Base:
main← Head:fspx-dot4-exact📝 Commits (1)
e88177erdna2spirv: restore the dot4 inline op_sel_hi under exact re-anchoring too (SHADER-FSPX-DOT4-EXACT)📊 Changes
2 files changed (+49 additions, -1 deletions)
View changed files
📝
tests/test_rdna2spirv_decode.py(+44 -0)📝
tools/rdna2spirv.py(+5 -1)📄 Description
Claimed in the coordination issue as: SHADER-FSPX-DOT4-EXACT (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7163717323)
What and why
A listing whose undecodable words sit at offsets its llvm-mc messages name is re-anchored exactly
(
invalid_at, from #984). That branch oftranslatetried thev_fma_mixliteral restores but notrestore_dot4_inline_sel, which the forward-search branch andcheck_printed_encodingsboth try. So av_dot4_i32_i8whose src1 is a replicated inline integer (llvm-mc printsop_sel_hi[1]set where the program'sword has it clear) was marked normalized, and the whole program was refused as "reachable instruction with
normalized encoding".
llvm-mc 23.1.6 names every word it rejects, so two of the 29 FSPX programs of the FidelityFX DLL take that branch and
did not translate. The title then has no pipeline for one of them, and the DLL reads through the missing object
(an access violation at
amd_fidelityfx_upscaler_xbox.dll+0x65ff, about 50 s after the first-run setup isconfirmed, native Windows). The fix is one condition: the exact branch tries
restore_dot4_inline_selbefore theliteral restores, as the other two paths do.
Tested
rdna2spirv.py <work>/shaders/fspx/disasm --no-asm --wave64-emulate) with llvm-mc 23.1.6 (conda-forgellvm-tools): 27 of 29 translated and passing spirv-val onmain98c2f7777, 29 of 29 with this change.The other 6 FSPX programs with rejected words (the dot4 forms #984 recovers) translate either way.
python -I tests/test_rdna2spirv_decode.py: 26 tests OK. The newtest_exact_anchoring_restores_dot4_inline_sel(one rejected word at a known offset afters_endpgm, a dot4printed with the default op_sel_hi) passes with the change and fails without it with "reachable instruction with
normalized encoding".
mained94fbef9+ #1768): without this change the processdied 50 s after the first-run setup was confirmed, in
amd_fidelityfx_upscaler_xbox.dll+0x65ff(a read at0x10), right after the runtime logged "no translated compute shader for FSPX" for one of the two programs and
refused its pipeline (
E_INVALIDARG). With the 29 retranslated, the next boot logged no missing FSPX programand did not fault in the DLL; it went on to a later, unrelated stop (a lost device about 75 s into the session).
GPUs tested: NVIDIA GeForce RTX 5080, driver 621.24, Windows 11 Pro 26300
AI-assisted: yes (Claude Code)
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed. (n/a: anexisting restore applied in one more branch, no new rule)
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.