test(agc-driver): flush untracked storage results before checking guest memory #2248
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2248"
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 MarcZX10 on 2026-10-09T13:10:20Z.
What
Fixes the untracked storage refresh check in
agc_driver_recorder_testsfor #2155.StorageTexture::Refresh()can keep an image's pending GPU results resident when guest-memory comparison is unchanged. The test now checks that the image remains pending, explicitly flushes it, waits for the GPU, and then verifies guest memory. The watched-memory assertion remains for platforms where watched imports are available.The unit-shadow host-import retirement fix was removed from this PR after it merged in #2299 (
0856926c) and is now part ofmain.Tested
The current head
cf043ca6is based on upstreammain0df342c6400ddafeaab3f8ccbc6eb751a1ca35a3. On Linux x86-64 with GCC 12.2 and lavapipe,agc_driver_recorder_testsbuilt and the full executable passed when run directly. This checkout does not register that executable with CTest. The runtime reports no write watching, so the watched-memory cases, including the watched storage-refresh assertion, were skipped; the untracked explicit-flush path did run.python3 tools/check_conventions.py --base upstream/mainandgit diff --check upstream/main...HEADpass.Earlier Windows 10 / RTX 3060 Laptop runs passed the combined refresh and unit-shadow changes 30/30 on a pre-rebase tree. Those results are not a run of this head. Earlier native macOS fixture evidence reproduced the original guest-memory assertion failure and passed with the explicit-flush test change; it was an isolated fixture, not the repository recorder suite.
Eligibility and report checks, plus all three relinker jobs, pass on this head. Conventions is still queued. The automated PR workflow skipped the full Linux and Windows Build jobs; an authorized collaborator must start Build for those under #2113.
Checklist
main; no other open PR implements this refresh visibility changeImported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-09T14:42:49Z.
The current-head diff is scoped to the recorder regression test, and the focused Linux tests and Conventions check are green. The contribution matrix also requires the full Linux/Windows Build and relinker jobs on the PR head (
d7d8005521e151f3c3879da6e49b4129f8ec2925); the current PR check list only contains Conventions. I do not have upstream Actions dispatch access from this account, so could an authorized collaborator run the required Build workflow against this open PR before merge? The forkmainbaseline run does not cover this PR head.Imported from boykopovar/AnyPS5. Originally posted by popcoder565 on 2026-10-09T15:01:28Z.
Native Windows run, since this was tested on Linux with llvmpipe. Setup: Windows 10 (19045), RTX 3060 Laptop (NVIDIA 616.92), MinGW-w64 GCC 15.2.0 (WinLibs r7), Release.
agc_driver_recorder_testswas built with--target.maind70b8998main+ this PR (d7d80055)main+ this PR + #2299unitShadowTestsleaves its import behind on Windows, and #2299 fixes that.agc_driver_dcc_keys_first_write: 10 of 10 with this PR.🤖 Addressed by Claude Code
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-09T18:15:45Z.
I rebased this existing PR onto current upstream main and force-pushed the reviewed head
8c236281ade4db49cd68e8ccf1ca3a999c3acca4to the existing fork branch. The full diff remains limited to the recorder regression test. Local validation on that exact head:agc_driver_recorder_testsbuilds successfully; the full executable passes on lavapipe, including the new untracked refresh checks;git diff --checkandpython3 tools/check_conventions.py --base upstream/mainpass. The Build workflow is still absent from the upstream PR checks, so the previously requested full Linux/Windows Build and relinker jobs on this exact head remain outstanding.Imported from boykopovar/AnyPS5. Originally posted by krishalivaibhav on 2026-10-09T18:37:31Z.
Native Apple M2 evidence for the recorder refresh test change: an isolated
storageRefreshTests(false)fixture reproduced the original guest-memory assertion twice; applying the exact test patch from this PR made it pass. A separate subagent independently reproduced failure before and success after the patch. The checks establish pending-image identity, explicit flush, synchronization, and guest-memory contents rather than changing production Refresh behavior.The companion original
agc_driver_dcc_keys_first_write_testsalso passed its ordinary/untracked-reuse cases on the real Apple M2 VulkanDevice. Watched-memory coverage is unavailable in this macOS runtime and explicitly skipped; Windows shared-import cases are excluded. The external recorder harness now reports a requested watched run as unsupported (77), not a pass. These companion outcomes were independently rerun.Environment: Apple M2 / 16 GB, macOS 27.2 beta 3, Apple Clang 21 / SDK 27, bundled SDL, MoltenVK 1.4.2, explicit ICD/loader, cache disabled and 30-second limits. The narrow Recorder fixture required enabling advertised VK_KHR_portability_subset in an external copy and adding selected-device logging; no repository changes were made. It uses its own fixture Device, distinct from the companion test's production VulkanDevice.
Tested against our local macOS integration
4d910ce3, including existing ARM64/macOS, placeholder-image and SPIRV1.3 dependencies. The original PR2248 test hunk atd7d80055was used; its added/removed lines are unchanged at rebased8c236281. This is not an exact-current-head full Linux/Windows Build validation. No full recorder suite or unit-shadow/device-loss path was tested. No claim about watched-memory correctness, PR #2299 or game compatibility. AI-assisted validation with independent subagent review.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-09T18:39:22Z.
Thanks for the native macOS reproduction and for spelling out the fixture boundaries. I added the result to the PR description, including that the original test hunk is unchanged at the current head, while the external fixture was not a full repository Build and could not exercise watched memory.
The evidence strengthens the targeted untracked refresh regression check. The exact-head Linux/Windows Build and relinker matrix is still outstanding under the repository's contribution rules.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-09T19:16:46Z.
Rebased the existing PR linearly onto current
main(ae3d5f95) at head66708cd8. The complete source diff remains the same 10-line test change inRecorder.cpp. On this head, Linuxagc_driver_recorder_testsbuilds and the full executable passes on lavapipe; it explicitly skips watched-memory coverage because write watching is unavailable. Local and GitHub Conventions pass. I updated the description to keep the macOS and Windows evidence clearly identified as pre-rebase/fixture evidence with their limits.\n\nCould a collaborator with write access run the required upstream Linux/Windows Build and relinker matrix on this exact head under CONTRIBUTING/#2113?Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-09T22:00:43Z.
After #2299 merged, I rebased this PR on current main and removed the already-merged unit-shadow host-import retirement commit. The PR now contains only the explicit-flush coverage for untracked storage refresh visibility. The recorder test executable builds and passes locally on Linux/lavapipe; this runtime has no write watching, so the watched-memory storage-refresh case is skipped. The official Build/relinker matrix remains for a collaborator to run on this head.