Hash only the declared bytes of embedded DXBC containers #322
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/322"
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?
Imported from avatarmanz/VIctory-7900XTX. Originally posted by agonisingbasher on 2026-11-26T16:41:02Z.
When the shader scanner finds an uncompressed DXBC container, it currently passes the entire suffix of the enclosing file downstream. Different copies of the same shader then produce different hashes, and the shader cache can hash and copy unrelated archive data.
This change keeps the slice already bounded by the DXBC parser and passes it to
shader-info,translate, andshadersthrough their shared scanner. Packed SGD5 records continue through the existing path.Validation
The Windows diagnostics build and the embedded-container regression test passed. The asset policy check also passed.
A synthetic 16 MiB file containing 512 identical valid DXBC headers produced 512 distinct hashes before the fix and one after it. Median
shader-info --verbosetime across three runs on this machine went from 3.973 s to 0.073 s. This measures the offline scanner.The full diagnostics suite for the Victory CLI passed (27 tests). On an RX 6600 XT, a separate local shader inventory matched the README totals: 25,694 translated entries and 195 unsupported entries in the shader archive, plus 96 translated entries and no errors from the executable and DLL scan. The executable and DLL scan used the patched build. The patch addresses cache keys and scanner cost.
Pull request closed