xshader: take a vertex shader's table parameter from its own records #173
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/brcly--TuxBox!173
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/173/head"
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?
@JeffreyBytes on GitHub · 2026-11-25 14:59 UTC · original
JeffreyBytes:feat/vertex-table-parameter→main· +48 −0 · 3 files · 1 commits · merged 2026-11-25 18:00 UTCSummary
Draft, opened early so nobody duplicates it. Follow-up to #168, which lists "guest root kept: vertex stage untranslated" among the cases it leaves.
root_tablemaps a table register to a root parameter by a fixed base. For a vertex shader that starts withs_swappc_b64it used the chained-entry rule (tables seven registers after the swapped pair), which is for shaders built to feed a geometry shader. A vertex shader with a generated fetch call also starts withs_swappc_b64, but keeps its tables where FSSM says:s8for parameter 0,s9for parameter 1, and so on. Only thes8case was recognised, and only when every record sat ins8.With a table in
s9the lookup landed on the wrong parameter, found no range for the slot and fell back to the slot number in space 0 (register(b5)where the root hasb22, space1). The driver then rejected the pipeline for a binding the root does not have, or the translation was refused withbuffer in table of kind None.When the vertex shader's used-resource records place descriptors in the register, the parameter they name is used. The chained-entry rule still applies to registers the records do not mention. Only vertex shaders are affected.
Results on ProjectScarlett
Offline, translator before and after over 14,924 locally recorded requests (measured at
1d821cb, before the module split; the change is the same): 83 outputs change, all vertex shaders whose registers move to the ones their root declares; 38 requests that were refused now translate; none are lost.In the game, RX 6700 XT on RADV (Mesa 26.3.1), Intel i5-12600K, Proton Experimental, offline. Each build got its own
--prepare-onlypass and a warm-up run, then a run stopped at 300 s. Counts are from the pipeline failure file;mainis7b22d71.mainNo failed presents in any run, and the present rate is the same across builds (about 300 to 340 per 10 s). #174 alone gives 395 stand-ins; the two together reach 65 because some pipelines need both stages fixed before either can use the reflected root.
Verified on Lanes
python tuxbox.py checkpassed on this branchNot run yet; this is why the pull request is a draft.
Checks
Run on this branch, rebased onto
7b22d71(after the test and module split):python -m unittest discover -s tests: 348 testsvertex_table_parameter_follows_the_shaders_own_recordsdxbcwithnative-bindings: 61xg-layout: 14cargo check --target x86_64-pc-windows-msvc -p tuxbox-d3d12No evidence JSON changed.