Shaders: track literal bit operations in sampler descriptors #947

Open
github-bot wants to merge 1 commit from github-bot/gh-947 into main AGit
Owner

@⁠avt0m4t48 on GitHub · 2026-11-25 13:27 UTC · original
avt0m4t48:fix/literal-sampler-words → main · +36 −2 · 1 files · 1 commits · open

The descriptor tracer already folds inline operands for s_brev_b32 and s_not_b32. The same scalar operations with a literal dword left the sampler word unresolved, so a later image instruction could reject an otherwise constant sampler. Fold the literal operand for either operation's scalar result.

A synthetic pixel program verifies the same four sampler dwords with literal moves, a literal bit reverse, and a literal complement. The old tracer refused the bit-reverse variant. On Linux, the full shader library suite passed (172 passed, two ignored), and the Windows MSVC-target check and asset policy passed. The native Windows shader suite also passed (216 passed, three ignored). I did not test a physical GPU or a title shader. Windows run

AI-assisted using Codex.

**@⁠avt0m4t48** on GitHub · 2026-11-25 13:27 UTC · [original](https://github.com/fxceless/victory-fork/pull/947) `avt0m4t48:fix/literal-sampler-words` → `main` · +36 −2 · 1 files · 1 commits · open The descriptor tracer already folds inline operands for `s_brev_b32` and `s_not_b32`. The same scalar operations with a literal dword left the sampler word unresolved, so a later image instruction could reject an otherwise constant sampler. Fold the literal operand for either operation's scalar result. A synthetic pixel program verifies the same four sampler dwords with literal moves, a literal bit reverse, and a literal complement. The old tracer refused the bit-reverse variant. On Linux, the full shader library suite passed (172 passed, two ignored), and the Windows MSVC-target check and asset policy passed. The native Windows shader suite also passed (216 passed, three ignored). I did not test a physical GPU or a title shader. [Windows run](https://github.com/avt0m4t48/victory-fork/actions/runs/45627268771) AI-assisted using Codex.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 03:54:25 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/947/head:github-bot/gh-947'
git switch 'github-bot/gh-947'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-947'
git switch 'github-bot/gh-947'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-947'
git switch 'github-bot/gh-947'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-947'
git switch 'main'
git merge --squash 'github-bot/gh-947'
git switch 'main'
git merge --ff-only 'github-bot/gh-947'
git switch 'main'
git merge 'github-bot/gh-947'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.