test(agc): drop a shared range's backing when the range goes away #5759
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/5759"
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 boykopovar/AnyPS5. Originally posted by YossiYad on 2026-10-14T09:42:58Z.
What
agc_host_import_sparse(added with #5309) fails on my machine onmain:The test's
Resolvecallback searches a globalbackingslist ofBacking*, and eachSharedRangeadds a pointer to its ownBacking. The ranges are locals of each check and nothing removed them from the list, so by the fourth check it held pointers into stack frames that had been reused. With a temporary print increateSparseDmaBufImport, the fourth check's range resolved tooffset=46330441829925and a descriptor withst_size=0. The sparse path was therefore not chosen, the range fell through to the whole-rangeUDMABUF_CREATE(refused above the 64 MiB limit, which logsfalling back to copies), and nothing threw. Whether it passes depends on what the compiler leaves in those frames.SharedRangenow removes itsBackingfrom the list in its destructor. Test-only change;GuestBufferMemory.cppis untouched.Tested
Linux (Bazzite 44, GCC 16.2.1, Ninja, Release,
-DBUILD_TESTING=ON), RX 7700 XT,/dev/udmabufaccessible,size_limit_mb64, based onmain1a40d3d81:agc_host_import_sparse: fails onmain, passes 20 of 20 (--repeat until-fail:20) with this change.if (bound != VK_SUCCESS) return false;in place of thevkQueueBindSparsethrow, the fixed test fails on both of that check's assertions, which the old test could not show here because it never reached that path.tools/check_conventions.py --base upstream/mainandtools/pr_overlap.py(no overlap) pass.Checklist
main; no other open PR implements the same functions.mdfiles or images added to the repositoryImported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-15T12:09:16Z.
Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.
core/libs/prx/libSceAgcDriver/tests/HostImportSparseDmaBuf.cppImported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-15T12:37:00Z.
Checked:
SharedRangeregisters&backinginbackingsin its constructor and the ranges are locals, so the destructor removal fixes the dangling pointers.agc_host_import_sparsepasses 20/20 with--repeat until-fail:20on the PR merged onto current main; merging.