AGC: agc_idle_publish_wait fails on RADV since #9521: the idle flush's CPU-side publish drops both units as changed #11889
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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 Lander0606 on 2026-10-27T11:50:57Z.
What happens
agc_idle_publish_waitfails on RADV since #9521 merged, withAGC graphics: the idle publish's bytes are wrong; it passes on lavapipe.Title, test or build step
agc_idle_publish_wait(ctest)AnyPS5 commit
main801d5b9bc1(and8df2c3ed0e). First bad:c831db72df(merge of #9521). Last good:22a8590492, its first parent.System
Fedora 44, kernel 7.2.11, AMD Ryzen AI 7 350 with Radeon 860M (RADV KRACKAN1), Mesa 26.2.5. Built in an Ubuntu 24.04 container with GCC 13.3, Release,
BUILD_TESTING=ON,ANYPS5_ENABLE_SPIRV_TOOLS=ON; tests run on the host.Steps to reproduce
The test sets
APS5_PIN_WAIT_MS=3000andAPS5_WRITE_WATCH_IMPORTS=watchitself. It fails after 0.03 s.Log
What was checked
main801d5b9bc1main8df2c3ed0ec831db72df(merge of #9521)22a8590492(its first parent)main48c160c58b(2026-10-26)#11696 lists the same failure on
mainf5e3dc5e3bon an RX 9070 XT (RADV, Mesa 26.2.5), with the same message, so it isn't specific to this GPU. WithVK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation(1.4.341) it still fails, and noVUID-line is logged. In the full^agcrun on8df2c3ed0e, the only other failure isagc_driver_tessellation, the Mesa 26.2.5 crash. #9521's ownagc_storage_idle_writeback_racepasses here.Where the bytes go. I added two
fprintfdiagnostics onc831db72df(attached asdiagnostic.patch, and removed afterwards): one in the completion ofrecordCopiesOnCpu(UnitShadow.cpp), one aroundFlushAllPending("idle")inidlePublishWaitTests. WithAPS5_TRACE_SHADOW=1:RADV:
lavapipe:
FlushAllPending("idle")returns, so before the test's own CPU stores, and the host buffer holds the right bytes (0x22,0x33).GuestMemory::UnchangedSinceCollectedreturns false for both units, so the completion drops them as stale (UnitShadow.cpp:272onmain). Units 2 and 3 still hold0x11when the flush returns. On lavapipe it returns true and the bytes land.[write-watch] host imports resolve write protection: yes (4 of 4 scratch pages written after a GPU read, 4 after a GPU write, 4 after the import); imported ranges are compared. The test forcesAPS5_WRITE_WATCH_IMPORTS=watch, so the import stays watched, and those page writes then look like guest stores made after the publish collected the units. I did not check which access marks the pages.APS5_WRITE_WATCH_IMPORTSunset, this device compares its host imports, and the test logshost import of the idle publish test block refused or not watched: idle publish wait not tested. I have not checked whether a title is affected.cc @Raghav314 (#9521), @fisherjoey (#7984)
Logs (
main, the merge and its parent, on both drivers), the patch and its output, with an index inREADME.txt:anyps5-agc-idle-publish-wait-radv-logs.zip
AI-assisted: yes