fix(agc): report arena host holes as stored over on Windows #4131
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/4131"
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 oneandonlydean on 2026-10-11T23:51:25Z.
What
agc_write_trackingfails in the Windows job onmainsince #3594 (run 38181250683, 2 of 908 tests fail, this is one of them):The fix is the one @screamm proposed in #4087, with his lines unchanged:
StoredOverreturnstruefor a range that overlaps a host region inside the guest arena interval.#3594 made
Watched,CollectWrites,UnchangedSinceandUnchangedSinceAlltreat those host regions as unwatched.StoredOverwas left out. On Windows the tracker's coverage spans the whole arena interval, host regions included, soStoredOverpassed its coverage check, found no newer stamps on blocks that are never stamped and answered "not stored over". The test's last check takes a buffer on the main thread's stack, which on Windows lies in such a host region:Watchednow says no andStoredOverstill gave a proof.Outside the test,
StoredOveris called by the CMASK proof inDraw.cpp, which collects first and so already rejects such a range since #3594, and by the edge-unit checks inTexture.cpp, which sit behindChangedBlocks. Guest surfaces are not placed in host regions, so no title-visible change is expected; the tracker just stops contradicting itself.Only Windows is affected. On Linux and macOS the coverage check asks the write watch for registered ranges, an unregistered range is never covered, and
StoredOveralready returnstruefor it. The same check inagc_write_trackingruns and passes there, so no new test case is added: the existing one fails on Windowsmainand covers the change.The other stamp readers #4087 lists (
ChangedBlocks,WrittenSince,MarkWritten,ImportWatched) are not changed here.Tested
Windows was not run here. @screamm reports in #4087 that
agc_write_trackingpasses with these lines on Windows 11 (WinLibs GCC 15.2.0) and fails without them; the Windows job on this pull request is the check.Linux (CachyOS, GCC 16, Release, CI's configure flags) on
mainbca7a29d, where the added lines are compiled out:libs;agc_write_trackingpasses;ctest -R "agc_write|guest_kernel|guest_memory|write": 26 of 26 pass.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)Fixes #4087.
Imported from boykopovar/AnyPS5. Originally posted by LeandroLP23 on 2026-10-12T00:14:58Z.
Windows run of this head (
5864ee583, which already includes #4021): Windows 11 (26300), Radeon 860M, WinLibs GCC 15.2.0 r7, Release, full build.agc_write_trackingandagc_driver_graphicspass 3/3. Without this change (mainae7dbfa9c+ #4021),agc_write_trackingfails 3/3 withan unwatched range reads as not stored over.WriteTracker::covers(), so every reader answers the same way. I've closed it in favour of this PR, which came first. With this PR alone, extra host-hole checks onUnchangedSinceCollectedandStoredOverin theBdaResources.cppregression also pass, so I found no other reader that gives a wrong answer today. Thecovers()variant stays onLeandroLP23:fix/agc-write-tracker-host-holesin case it's wanted later.Imported from boykopovar/AnyPS5. Originally posted by AlxcBTW on 2026-10-12T00:22:50Z.
Windows check of this change (WinLibs GCC 15.2.0, Release, non-GPU node). Base:
mainbab7b3285with #4021'sSocket.cppguard applied locally, sincemaindoesn't compile on MinGW without it.agc_write_tracking(--repeat until-fail:5)ctestwrite tracking test failed: an unwatched range reads as not stored overlog_macros,guest_kernel_stack_protect,agc_write_trackinglog_macros,guest_kernel_stack_protect, both also failing on the baseSo this fixes
agc_write_trackingon Windows and changes nothing else in the non-GPU suite.AI-assisted: yes (Claude Code)