Repository navigation
Conversation
Adapt upstream PR boykopovar#2363 at 26a670a, preserving the existing prepared ABI diagnostics and depth tests.
|
Tested on Linux (CachyOS x86_64, Intel RPL-S iGPU / Mesa 26.3.0-devel / Vulkan 1.4.363, GCC 16.2.1) at
LGTM! |
|
Native Windows run, since no Windows results were posted. Setup: Windows 10 (19045), RTX 3060 Laptop (NVIDIA 616.92), MinGW-w64 GCC 15.2.0 (WinLibs r7), Release. Head
No title was run. 🤖 Addressed by Claude Code |
26a670a to
8692bb1
Compare
8692bb1 to
8e5e9a3
Compare
|
@oneandonlydean you asked whether the title from #2292 gets past the
Question: is the synthetic A/B enough for #218, or do you want a start-up measurement on the #2292 title first? If so, @mrk1987 could you time the title with and without this branch? |
8e5e9a3 to
7371e44
Compare
|
Independent validation on real hardware (correctness/concurrency, not performance) Built and ran the PR head
Results:
Rigor check (is the test real?): I reverted Honest limits of what I verified:
Written with AI assistance. |
7371e44 to
58d3114
Compare
…pen PR boykopovar#2363) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
adriadam10
left a comment
There was a problem hiding this comment.
Thanks for the rebase onto #2856 and the extra regression. Checked on Linux at 58d31147 merged on current main: AGC driver scope build, 371/371 ctest, agc_driver_registration_concurrency and _sync pass.
One blocker, already asked by @oneandonlydean above and not yet addressed:
- Start-up time of the #2292 title with and without this change (and whether it gets past the
FThreadHeartBeatkill). The synthetic A/B covers the lock change for #218, but the PR exists for that kill, and the body says that outcome is unverified. Also, the benchmark predates the async preparation from #2583, so it doesn't show the gain on the current base (single worker was ~13 % slower in the tiny/warm case).
If the title isn't available to you, ask in #2292 whether mrk1987 can run the two builds and post the numbers. Once that is posted this is ready from our side.
Heads-up: #3159 changes the same transaction defaults; whichever lands second needs a rebase.
58d3114 to
8710129
Compare
Upstream merged its own forms of the preparation lock (boykopovar#3159), the eh_frame index (boykopovar#1423) and host-import windows; those files take upstream's version, dropping our import-extent fix, the _dl_find_object unwinder lookup and our copy of boykopovar#2363. Our moved-buffer bindings, region index sort and retired-import keep are re-applied on top. The storage cache keeps upstream's deferred eviction with our frame-aware victims, write-only refresh and diagnostics. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Uzy15wqYTt6iWyxYXEzUWo
copy, superseded by boykopovar#3159 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Uzy15wqYTt6iWyxYXEzUWo
What
Driver::RegisterShaderholds the process-wide preparation writer lock while planning a private shader registration. Independent registering threads therefore wait behind that work, including full preparation whenAPS5_SYNC_SHADER_PREPARE=1.Move that acquisition to publication. For an identical registration, capture the matching immutable snapshot under the driver mutex, release the mutex, acquire the preparation writer, then reacquire the driver mutex and publish through
PublishRegisteredShader. Fresh registrations plan privately before acquiring the same locks in that order. The transaction still exists from function entry, so a caught registration failure aborts an enclosing preparation transaction.Current head
871012973005bae1e7e40c63d6c099e010ea4489is based onmain5aaf26bd325607f65bde28741a4e82ceaaf586c0. It preserves upstream94cffec3's lazy transaction implementation and existingHold()API unchanged;Read,EditandHoldacquire the writer, while an emptyCommitdoes not. No new transaction constructor or locking API is needed. The production diff is confined to registration lookup, planning and publication. Background scheduling, pending/failure waits, header reuse, ABI preparation and rollback retain upstream behavior.This is a concurrency correction, with no demonstrated affected-title startup benefit. The original reporter has already supplied the requested #2292 measurements; they are summarized below. No startup or
FThreadHeartBeatfix is claimed.Tested
git diff --checkpass for871012973.72fcef76d84a5ae356a746c8d8ed078d0bb4840c:871012973plus the Windows build guard from #4021 at121b16fb4bbd47ff4ce9302c40631bab858e3e71. That historical overlay fixed upstreamHostPollcompilation errors; onlySocket.cppdiffers from this PR. fix(libkernel): restore Windows select build for Demons Souls testing #4021 has since merged asbca7a29d259299aaa8972c94d12694232bb3bb08on October 11; the recorded validation source remains unchanged, and this PR does not duplicate its patch. Source pins, test inventory, separate preparation modes, exact completion markers, GPU identities, raw JUnit/logs, and 30-second limits were verified. No earlier benchmark or baseline failure was rerun.The concurrency tests explicitly hold the publication writer, verify that private registration reaches its expected planning/translation failure without waiting, and check that a duplicate registration does not hold the driver mutex while waiting for publication. They also cover lazy
Read/Edit/Hold, nested locking and rollback, eight concurrent registrations/resolutions, and subsequent dispatch. Both asynchronous and explicitly synchronous preparation modes remain separate tests, with 30-second limits.Affected-title measurements already supplied
The original #2292 reporter's October 11 results identify STAR WARS: Galactic Racer (PPSA28416), Windows 11, RTX 5090, MinGW-w64 GCC 15.2.0, Release. Both arms used newer
main1e8fff68with identical referenced and unpublished bring-up patches; the reported only difference was this PR's earlier five commits through58d31147. This is independent integration evidence, not a reproduction of the current rebased head.Both shader and Vulkan pipeline caches were warm, save data absent,
APS5_PROFILE_DRAW=1andAPS5_NO_SNAPSHOT_CHECK=1; the title's command line keptFThreadHeartBeatactive. The milestone was the first[present]statistics line, printed per 10-second window containing presents—a coarse upper bound, not exact first-frame latency.All six runs remained alive at the 150-second cap without a heartbeat kill. The results show no clear startup benefit or regression. For cold caches, the reporter observed no preparation-transaction waiters and attributed the remaining heartbeat kill to long NVIDIA compute-pipeline compilation; they attributed removal of the original registration-lock stall to #2583. These are the reporter's observations, not independently reproduced here.
The reporter also saw intermittent heap corruption in parallel preparation-test batches: 3/10 with this PR, 3/10 without it, and 3/10 on clean
main1e8fff68. That comparison does not establish a regression from this PR. The earlier changes-requested review predates the supplied title measurements; maintainer acceptance remains pending.Historical correctness and synthetic performance evidence — older revisions only
58d31147on basee8d6de4a, private self-hosted Linux run 38097454684 passed the Release/patched-library builds and 26 executions across 14 preparation/frontend test names, with no failures or CTest skips. Its inventory check found all 598 test executables registered; it did not execute the full suite. A duplicate-path lock-inversion mutation failed both concurrency modes at the intended assertion; restoring the exact source passed both. Environment: Ubuntu 24.04, GCC 13.3, Mesa 25.2.8 lavapipe/LLVM 20.1.2, SPIRV-Tools, required Vulkan and fresh caches.58d31147integrated into then-current main. No exact integration SHA or toolchain was specified. This is reported integration evidence, not validation of871012973.2567e8f997e8e0728943e801076d3fab07ca13ad, comparede8d6de4awith58d31147, both including asynchronous preparation. All 16 pilot and 240 full processes passed output/cache checks. Five paired trials per case used 12 tiny/arithmetic compute shaders, one/two/four callers and cold/warm caches; registration return and artifact/ABI readiness were timed separately, with dispatch/readback outside timing. Default-async readiness ratios ranged from 0.898–1.204×, showing mixed results and no consistent overall improvement. The separate synchronous control favored the candidate in all 40 multi-caller pairs, with readiness ratios of 1.763–1.985× for two callers and 2.572–3.412× for four. CPU work did not uniformly decrease. These synthetic results do not measure title startup or this rebased head; physical-host exclusivity was not established.346a6e73with the earlier perf(agc-driver): prepare shader ABI variants before taking the preparation lock #3159 implementation passed 32 selected executions and lock-order negative controls in run 38138738761. Its transaction design is superseded by upstream's now-merged lazyHold()implementation; those results are not attributed to this head.7371e448passed both concurrency modes and an eager-lock negative control. It included no title or performance measurements. Older synthetic synchronous speedups, including the approximately 3× four-caller results in run 38029920550, predate asynchronous preparation and do not establish current default-path gains.26a670a7reported 490 passes, 26 capability skips and oneagc_driver_flat_storetimeout among 517 tests. The same fence-wait failure was reproduced on unmodifiedd70b8998; the test and timeout remain unchanged. These historical outcomes are not a current full-suite result.Author-run Linux evidence used only locally managed self-hosted runners. Linked private workflows/artifacts require validation-repository access. The historical synthetic benchmarks, independently reported title results and current correctness validation are separate evidence sets.
Checklist
main5aaf26bd; preserves merged lazy transaction behavior