Plan for extracting focused PRs from #2778 #2787
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl#2787
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?
@KOLESNiii on GitHub · 2026-11-26 12:35 UTC · original
Take the correctness fixes and self-contained improvements from #2778. Extract the larger runtime changes only where they solve a demonstrated problem. Leave the unfinished eviction and sparse planning systems on the branch.
This is a breakdown of #2778 at
a4f0399f19e4againstmainatb49be1836844(371 commits, 70 files). The commit IDs identify the changes to extract. Each row proposes one PR unless it gives an explicit sequence. Rebase the behavior and its tests onto currentmain, preserving attribution. The overlap notes at the end are for avoiding duplicate submissions.The commit-by-commit plan below gives the pick order and prerequisites, starting with the three slices requested on #2778.
Worth pulling first
3fd55dff. Implement the X1 event marker through the existing retirement path. Test sequential and parallel retirement and caller handle closure. This addresses a title wait that otherwise has no completion event.311fc618with the minimum write-producer tracking from62de4d55/b3d9441e. Prove a preceding CPU store becomes visible before the waiting continuation and independent stores stay asynchronous. Add immutable submission-effect capture (1b0b589c) only to the extent the fix needs it.3364f184). Follow with separate split-continuation reservation and Kickoff Close/Reset recovery PRs (d5aa0a6a,617b493d,03e4d27d,73898793,974e3395). Use fault injection to show the prior valid recording survives and the failed segment never executes.2d8b8295,fb810988). For allocators, first reserve the recorded backing before native Execute (06d03e60), then retain it and its UMA through the correct retirement/reset (93693054,9ec2b4a3). Cover creation on a rotated backing (3d0d0558) where that path needs a follow-up. Exercise address reuse, outstanding work, and Reset/Release.faea307a,37271a3c). Publish sent hashes only after a successful queue signal (41a369ee). Preserve and retry the dirty snapshot and stop submission when ordering remains unknown (3cd053e4). Test Close/Wait/Signal failure, including partial batches. Separately take054270cato preserve newer CPU writes during sparse copyback.4e62e7c8)) and failed-job completion (0eaef7e6)) as separate PRs. Cover completion during bind and cancellation/failure waking waiters. Take cold builds off bind threads (aff341e1) separately, with early wanted promotion (11cf89f9) and bounded-wait segmentation (76e87252) split out by behavior.ba659963into whole-group conversion and tail-lane masking with deferred replay. Test non-multiples of the group size, multidimensional IDs, and overflow. Both behaviors are needed for partial-group parity.2bfc36eb), another for graphics projection/cache safety (32ecdb27), then faithful extended rasterizer state (e3a52f43). Keep native-stream caching (9e82e2aa,6457c188) separate until identity and rejected-blob fallback are tested.b271eba5into retryable OOM and forwarding optimization/extra arguments. Test that OOM leaves linking enabled and that arguments reach the live linker. Review slot admission (2e45718b) separately with concurrent callers.fba7de2b)), static-sampler identity (be772deb), and node/device and graphics identities (e5d2e5ee,4cd1b772,5afb11ad,14524632). Test stale rejection after replacement and differing roots/node masks. Extract graphics precompile parity (5d91261c`) as its own PR with a cold-cache runtime hit test.b0deef15)) separately from lock elision. Take generation-checked sparse placed-buffer publication (7619ff8c)) separately. Test stale state and COM address reuse.355826c5), single-copy DXIL containers (3cf3451c), loader range rejection (b59e59b6), zero-mip staging reuse (396a4144), streaming shader effects plus its far-jump cap (e67817e4,911ad65d), contiguous 2D tiling runs (b81ac2eb), and BCPack bit packing (9fdfe6c9). Require byte/output parity and measure the operation being improved. For Opus, split scratch reuse and validation (5a5b6504)) from PCM copying and output preallocation (87c5c52c,2a577d7d). For frame pacing (75c4a245`), split writable-target validation from removing wait allocations.Worth extracting as stacks, with a measured reason to activate them
d8ddd5b5,e12049fe). The commit reports 3 hangs in 4 RTX 3080 world-load runs before the wait and 0 in 7 with it. Those runs support the dependency and need repeating on the extracted PR. Preserve staging ownership after a failed wait (0ea9a959) and per-queue ordering (23d7f4e8) in the activation or its prerequisites. Omit the reverted intermediate upload implementation (01c0835aand its revert).d93c63a7,c52ad726,0540a23c,9374675e,12b1b786). If needed, land native queue-slot dispatch and submission ordering independently (89343644,e10df30d,87b55ac8). Then split copyback into reverse layout conversion (b7af0096), generation/subresource writer and transition tracking (972f66ec,24ffb0e7,b0442a22), writer-queue staging and lifetime (e564cbb7,fafeee3e), and publication before the title observes fence completion (4cc28d40,547f3211). Activate with a title-path regression covering partial subresources, two queues, and failed waits.6f6b5a27), then define and test canonical identity (0fef9d5a,67629ad4,fedfbe4c), then enable in-process coalescing (b946815d). Measure duplicate builds and first-use wait time. Review priority queue activation (e7c522d8,2ccea5e1), bounded compile helpers, and prior-use preload ranking (56cffc2b) independently. Keep off-bind used-key journaling (7ea65ea9,77eb9e7f) separate and test shutdown and ordering.202c9623,ffac3219,2a6a8ba2), per-recording command storage reuse (aa446c29), and used-only prewarming (c162ffb1,6495067f). Compare direct/indirect output, first-use wait, and GPU time per piece. Review whole-build failure memoization (deb5fccf) separately with transient OOM recovery.3e417232,2f608f80,4db26aec,b077218f,7273e250). Keep branchless heap guards (0aa15353) apart from split-wave64 remapping (e0416843). Take the flat/guarded GPU parity test (ab323147) where it adds coverage beyondmain. Treat CFG allocation, EXEC folding and split-piece binding pruning as separate candidates.5bdaa54e,dfcd4bbb)), then the comparator (fd237b1b). Keep fixtures with their scripts and describe cold/warm as XCL cache states since driver caches are uncontrolled. Add coarse stall tracing (dab895e5,e0635a1c)) separately. Wait64 recording history and memory by owner have concrete diagnostic uses and can each stand alone. Add detailed hooks only for a specific investigation.Leave out of the initial merge series
c8889e88,b5f7fc0e,3116f06f,4e0b3555,7d0487c4). They model claims, plans, reservations, commit and receipt ordering without driving live uploads. The live failure fixes above have a direct testable outcome. The newerb628cfb4refactors the live synchronous path by bundling the slot, rollback point and pending hashes. Consider it separately after correctness lands, if it makes a concrete follow-up smaller.08662496,729dac6f,c77b4849,c58bf39a,96950cbb,fa2167b2,bf0db1ad,025dc2fa,0bd24ca7,cf4c3ebc,70a58f43). The branch adds opt-in tracking and ownership machinery while leaving pressure-driven eviction and descriptor mutation uncalled. Revisit with a workload that demonstrates reclaimed memory, safe in-flight lifetimes, and bounded reload cost.4893eb6c), AMD persistence defaults and compile lanes (80bb4516,16e58563), slow-blob persistence past the RAM cap (4ca5c6fe), write-watch gap tuning, pending lookup sharding, allocator spare pooling, wider fence-lock changes, persistent detile workers, and the XAudio2 atomic dispatch table. Measure them independently if the corresponding bottleneck remains. Keep the first-fault instruction rewrite (bf157ece) outside this series.Overlap to check when assigning the extracted changes includes #2569 (DirectStorage events), #2585 (linked DXC), #2610 (DispatchX group conversion), #2621 (graphics stream state), #2622 (deferred Close), #2633 (indirect CBV), #2691 (list Release), and #2702 (BCPack). Fold equivalent work into its focused PR and submit only a distinct follow-up where needed.
Target roughly 400 changed lines per PR and use
Stacked on #Nfor actual dependencies. Runtime PRs need a focused regression, full Windows suite counts with GPU skips, and same-title/same-duration smoke blocks for cleanmainand the exact PR head. This review was static. Windows/MSVC, GPU, and retail smoke tests were unavailable.Commit-by-commit extraction plan
The three slices requested in the #2778 handoff comment come first. The remaining rows are a backlog, subject to author coordination and the evidence gates below. Arrows give the order of commits within a PR. A dependency on another PR means stack on it or wait for it to land. Each new branch starts from current
mainor the named prerequisite.Patch applicability was checked against
b49be1836844with three-way Git application in a temporary index. That checks conflicts only. Pick means the listed source changes are the intended inputs togit cherry-pick -x. Port means adapt the named hunks to the current implementation, preserving source SHAs and attribution. A whole commit that applies can still need code or test changes after review. Use individual source commits, leaving the umbrella merge commits behind.1. Sparse upload recovery
faea307a→37271a3c. Coordinate the ring timeout and its test with #1277. If that timeout lands first, reuse it and extract only the unsubmitted-range handling plus the allocator/readback guards. Keep the scope to bounded waits, Reset/Close failure, and withholding CPU readback on incomplete copies.41a369eeon S1. Insparse.rs, make scanning plan dirty ranges without publishing sent hashes. Record proposed hashes per staging batch, apply only after the queue signal succeeds, and retain GPU-owned staging when Execute may have happened without a usable marker. The original commit conflicts with maincarry the small submission-outcome plumbing this invariant needs.
3cd053e4on S2. Limit runtime changes to the write-watch retry journal, rollback of a failed title-queue wait reservation, and the shared preparation checks at Execute and Kickoff. Keep the newer synchronous refactorb628cfb4out of S1–S3.2. Deferred CPU write ordering
The five commits below applied in source order as a stack. The original ordering fix alone conflicted with main. Divide the stack this way so the behavior change has one reviewable boundary.
62de4d55.1b0b589con W1.4d17a73bon W2.b3d9441eon W3.311fc618on W4. This is the behavior change. Keep9b847915as an optional measured follow-up for avoiding repeated scans of earlier segments.3. Contiguous 2D tiling
T1. Pick
b81ac2ebalone. It applied to main as a one-file change ingpu/tiling.rs(383 changed lines in the source commit). Retain the tiled and detiled comparisons against the element-by-element path, including base XOR, block formats and mip edges. Report byte parity and a before/after timing on the same texture workload. Keep persistent workers (6dd9d53f) out so the measurement isolates the copy strategy.Other extraction candidates
Each line in the table proposes a separate PR unless an explicit sequence is given. Where a source commit mixes scopes, extract the named hunks and retain its SHA in the new commit message.
3fd55dff(overlap #2569)command-list Release pick
2d8b8295(#2691)heap Release port
fb810988descriptor publication bounds pick
b0deef15(#2631)sparse placement lifetime port
7619ff8c(#2539).3364f184(#2622)reserve a continuation before closing port
d5aa0a6aand only the related split recovery from617b493d/03e4d27dKickoff Close port
73898793Kickoff Reset port
974e3395. Share W3 where it is needed.cf40395a→06d03e60as one change, keeping only their final reservation pathhold busy backing across final Release port
93693054make list creation use the active backing port
3d0d0558pin UMA to native backing until retirement port
9ec2b4a3after backing ownership is in place.4e62e7c8finish failed worker jobs port
0eaef7e6)<br>keep cold compiles off bind threads **port**aff341e1<br>record wanted state at deferred record time **port**11cf89f9<br>avoid put-off segments for bounded waits **port**76e87252`.2bfc36ebconservative graphics projection port
32ecdb27extended rasterizer state port
e3a52f43after projectionnative cache lifecycle port
9e82e2aa→6457c188after stream support. Fromb271eba5, extract DXC OOM handling and linker arguments as two PRsserialized DXC admission pick
2e45718bindependently. Fromba659963, extract group-count conversion first and tail-lane masking/deferred replay second.fba7de2bstatic samplers port
be772debNodeMask runtime and disk identity port
e5d2e5ee→4cd1b772→5afb11adgraphics cache identity port
14524632graphics CLI/runtime variant parity pick
5d91261c.355826c5DXIL container copy pick
3cf3451cloader range filter pick
b59e59b6zero-mip staging port
396a4144effects analysis pick
e67817e4→911ad65dtogetherBCPack pick
9fdfe6c9Opus scratch and validation pick
5a5b6504), then PCM bulk copy and preallocation **pick**87c5c52c→2a577d7dafter scratch. Split writability checks from allocations in75c4a245`.d8ddd5b5→e12049fetogether for upload ordering, with staging and queue lifetime prerequisites where needed (0ea9a959,23d7f4e8). For copyback: owned queue snapshotsd93c63a7retirement model then activation
c52ad726followed by0540a23c→9374675e, with sparse consumers12b1b786following separatelynative slots
89343644→e10df30dand queue ordering87b55ac8as distinct prerequisites where neededreverse conversion pick
b7af0096writer metadata port
972f66ec→24ffb0e7→b0442a22staging plans port
e564cbb7→fafeee3eactivate fence-visible publication port
4cc28d40→547f3211. Split writer metadata into bookkeeping and publication if it exceeds the size target.6f6b5a27canonical key
0fef9d5a→67629ad4→fedfbe4ccoalescing
b946815dqueue foundation
e7c522d8and activation2ccea5e1) as separate PRs<br>rank preloads56cffc2b<br>journal used keys7ea65ea9→77eb9e7f. Split indirect CBV ABI202c9623→ffac3219from activation2a6a8ba2)command-buffer reuse
aa446c29observed-use prewarm
c162ffb1→6495067f. Treat these as ports on the minimum landed prerequisites.0aa15353(guards) ande0416843(wave remap) separate. For tooling, runner pick5bdaa54ethen port the runner/fixture parts ofdfcd4bbbwith itcomparator port
fd237b1bplus comparator/fixture parts ofdfcd4bbbafter the runner. Defer the later counters until their producers land. Stall report foundationdab895e5→e0635a1cis separate from hook sets.The refreshed source head also adds
54039442anda4f0399f. Leave both out of these PRs. They extend the sparse claim ledger and the inert pipeline eviction ledger, respectively.After each extraction, review the diff against its base and retain only the named behavior, its regression, and any required README update. Link the source commits and this issue, preserve original author and co-author credit, and note any adaptation in the PR. Run the Windows/GPU suite and paired smoke checks described above before marking a runtime PR ready. No Windows, GPU or retail runs were performed for this plan.
AI use — Codex (GPT-6) inspected the diff, commit history and related PRs and drafted this issue.
@mokkamokacaffe on GitHub · 2026-11-26 13:25 UTC · original
The unsplit translated-cache buffer reuse listed here is already extracted as #2594, authored by @storrmzz at current head
ae921b40. Commit355826c5in #2778 explicitly says it was adapted from that PR, so another extraction would duplicate an active, focused and mergeable contribution.I reviewed #2594 against
mainb49be183:translated::decode_entryretains ownership of the fileVecand validates the DXIL container before modifying it.rest.is_empty()establishes that the validated payload ends at the end of the file buffer, sob.len() - lenis the payload start.copy_withinandtruncatepreserve the allocation; split entries keep the previous per-container copy path and do not retain all piece bytes.git diff --check origin/main...ae921b40passed.No separate PR should be opened for
355826c5; #2594 should remain the source of truth and receive any further testing. Its remaining merge requirement is the exact-head paired retail smoke run described in its body.AI use
@retrope13 on GitHub · 2026-11-26 13:25 UTC · original
Native Windows/MSVC + NVIDIA GPU verification and release benchmark for T1 (
b81ac2ebcherry-picked cleanly ontomainb49be183) — not claiming the PR (just providing the native Windows/MSVC test + timing data that was unavailable when #2787 was drafted).Environment
32.0.16.2140),XCL_ADAPTER=NVIDIA26300.9818),rustc 1.100.0(stable-x86_64-pc-windows-msvc), Windows SDK10.0.26100.0DXC1.9.2602.17Applicability & Full Windows/MSVC Test Suite
git cherry-pick --no-commit b81ac2ebontomain(b49be183): applies cleanly with 0 conflicts (crates/xcl/src/gpu/tiling.rs, +321 / -62) and 0 new compiler warnings.cargo test --locked -p xcl --lib gpu::tiling::: 17 passed, 0 failed in debug (10.64 s) and 17 passed, 0 failed in--release(0.86 s).cargo build --workspace --locked, thencargo test --workspace --locked --no-fail-fast -- --test-threads=4):main(b49be183): 1435 passed, 0 failed, 47 ignoredmain+b81ac2eb(T1): 1437 passed, 0 failed, 47 ignored (+2 new tiling tests, 0 regressions)Isolated
--releaseTiming & Byte Parity (mainb49be183vs.main+b81ac2eb)9 timed iterations after 1 warmup per workload (median ms reported; FNV-1a 64-bit checksums of both
tileanddetileoutputs matched 100% identically across all 4 cases):main(b49be183)main+b81ac2eb1920×1080R8 (mode 5,elem_log2=0)1b3af948a76d4c25)1920×1080R8 (mode 5,elem_log2=0)31cf563b857bf425)2048×2048RGBA8 (mode 10,elem_log2=2)a4118795b68a2325)2048×2048RGBA8 (mode 10,elem_log2=2)56e0fada6c622325)2048×2048BC7 (512×512×16B,mode 10)1b59b090d0bc2325)2048×2048BC7 (512×512×16B,mode 10)6645f0556de02325)2048×2048RGBA8 (mode 25XOR,pipes=3, pkrs=3, base_xor=0x100)a4118795b68a2325)2048×2048RGBA8 (mode 25XOR,pipes=3, pkrs=3, base_xor=0x100)d3edea4df9ca2325)Not Tested
#[ignore]tests.AI disclosure: Antigravity (Gemini 4 Neon, XHigh) ran the cherry-pick, Windows/MSVC test suites, release benchmark, and drafted this comment.