shader: retranslate example checks translations against a session's #504
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/lobomfz--VIctory-xmem!504
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-504"
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?
@Benflex1 on GitHub · 2026-12-04 19:47 UTC · original
Benflex1:retranslate-example→main· +539 −0 · 4 files · 1 commits · openProblem
Checking what a translator change does to the shaders the game actually uses currently means running the game, or reading a whole-archive tally. There's no quick offline way to answer two questions: which of a session's shaders would now translate differently, and did translation get slower?
translate_filelooks at one container at a time, andisa_probemakes pipelines for driver dumps. Neither compares output.Change
A new example,
retranslate, invictory-shader:VICTORY_SHADER_SAVE=<dir>. That writes<hash>.<stage>.cdxilplus the session's own<hash>.<stage>.dxilbeside it.host.rs/descriptor/host.rsset it up:--genericturns this off);--card-tests.VICTORY_*translator switches apply as in the game..dxil, or with an earlier run's--outvia--ref.--repeat Nreports the fastest of N and flags any translation that isn't the same every time.--listlists everything), then a summary. The exit status is 1 if anything differs, fails or is unstable, so it can gate a script.--outis refused inside the source tree (victory_core::ensure_outside_repo, rule #1).Other changes:
docs/DIAGNOSTICS.mdgets a short section, which also documentsVICTORY_SHADER_SAVE.victory-shadergainstempfileandvictory-coreas dev-dependencies only.test = true, so its tests run withcargo test -p victory-shader.There is no change to the translator or the runtime, and nothing game-derived is included.
Verified
x86_64-pc-windows-msvcbuild (built with--locked, run under Wine). They cover:--refreferences;emit::translatefailure on bytes that aren't a container;cargo xtask policy --stagedpasses..dxil, with 0 failures. So the offline setup matches the runtime's.--repeat 2, there were 0 failures and 0 unstable translations. The ones that differ are expected, since that session ran a different translator build.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.