Replay: --dump handles code that was not recorded; shader code checked against shaders.bin before allocating #276
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/276"
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 sharan104 on 2026-11-26T14:04:27Z.
Two crashes in
victory replayon captures it should handle:--dumpon a pipeline whose code wasn't recorded. When the recorder can't write a shader, it numbers the codeu32::MAXon purpose (record.rs).dumpindexedframe.codes[blob]and panicked on such a capture, which the recorder itself produces.dump, and the pipeline building inPlayer, sized a buffer straight from the code length stored inframe.bin. A wild length either panicked with a capacity overflow or aborted out of memory before the read could fail.Fix:
dumpwrites<kind>=(not recorded)for a missing code and carries on with the pipeline's other parts.code(file, c), checksat + lenagainst the size ofshaders.bin(overflow included) before allocating. Both readers use it.Test:
shaders_are_dumped_from_what_the_capture_holdsdumps a pipeline with one recorded code and oneu32::MAXcode. It gets18=….dxil 23=(not recorded)and the right bytes. A length past the file, and one ofu64::MAX, are both refused without allocating. The test panicked before the fix (index out of bounds) and passed 10 runs out of 10 after it.Results:
--features diagnosticspass.-D warningsadds nothing beyond main's existingwatch.rslint, which #241 fixes.🤖 Generated with Claude Code
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.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.