Shaders: xcl pipelines leaves to the title only what a crash cut short #1335
No reviewers
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!1335
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1335/head"
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?
@VolenNakov on GitHub · 2026-11-24 14:56 UTC · original
VolenNakov:pipelines-trying-in-flight→main· +1147 −25 · 11 files · 9 commits · closed without mergingStacked on #759; only the top commit (
Shaders: xcl pipelines leaves to the title only what a crash cut short) belongs here.xcl pipelineswrites each pipeline it starts topipelines.trying, and the next run marks everything in that file as done ("left to the title") so a pipeline that crashed the driver does not end every run. The file was never trimmed and had no binary key, so the next run also skipped everything the stopped run had finished or was building: after a Ctrl+C the builds in flight, after a rebuild of xcl.exe (pipelines.donestarts empty for a new binary) every pipeline the earlier run had started – 12 919 of a 15 129-pipeline share of the retail title's journal here, none of them built by the new binary.What is in it
crates/xcl/src/pipelines.rs:.tryingbegins withbinary_key(), and a pipeline's hash is written when its build starts and again when it ends.in_flighttakes only hashes written an odd number of times, in a file of this binary.stop_cleanly_on_ctrl_c(a console control handler) empties the file to its key before the process ends, so a Ctrl+C or a closed console leaves nothing to the title; a crash in the driver or DXC still does. Test:only_what_was_in_flight_with_this_binary_counts_as_crashed.Tested
cargo build --release --workspace, thencargo test --release --workspace --no-fail-fast -- --test-threads=4: 703 passed, 3 failed, 41 ignored. SKIPPED (no wave64):gpu_geometry_wave32_prefix_count_over_a_mask,gpu_wave32_program_in_wave64_hardware. The 3 failures aretitle_textures::tests::placed_title_textures_share_vram_and_preserve_pixels,title_textures::tests::transitions_apply_when_their_list_is_submittedandvram::tests::d32s8_targets_take_their_own_size_of_video_memory; run on their own they pass, on this commit (twice) and on #759's head788e366, so they fail only next to the other GPU tests on this 16 GB card. This change touches neither file.xcl pipelineson the retail title's journal with this commit's build, stopped with Ctrl+C after 1 222 pipelines:pipelines.tryingwent from 2 446 records to 8 bytes (the key only); the next start printed1222 done beforeand no "the last run ended while making …" line.main930e8b4): four processes on shares of the journal (a local--shardoption, not in this PR) stopped with Ctrl+C and restarted on a rebuilt xcl.exe started with "0 done before" and no "the last run ended while making …" line; before the change the same restart reported 12 919 such pipelines per shard.Regression run
main:
PR:
Not tested
xcl pipelines(the path that should still leave the in-flight pipeline to the title): only the unit test covers it.--watchbeside a running title, AMD and Intel GPUs, Wine.xcl pipelines; they check that the runtime is unchanged.main's peak commit is high because of #1307 (b8b1f49), which #759's base does not have.AI use
🤖 Generated with Claude Code
@DavidM1911 on GitHub · 2026-11-24 15:08 UTC · original
Does not compile merged with current
main(930e8b4):cargo test -p xcl --libfails withE0599: no methodacquireond3d12x::real::Slots(used at real.rs:4217,BIG_COMPILES.acquire())E0425: cannot find functionwait_for_commitLooks like the branch was written against an older/different allocator API — needs a rebase onto current main. Also ~1,147 changed lines across 11 files; likely wants splitting per CONTRIBUTING.
@futurepro62 on GitHub · 2026-11-24 15:05 UTC · original · edited 2026-11-24 15:09 UTC
Full-suite run, since this PR has no test report yet. Tested exact head
d26b19c(on its basef4ce27c).Tested
cargo build --workspace, thenXCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4: 706 passed, 0 failed, 41 ignored. SKIPPED (no wave64):gpu_geometry_wave32_prefix_count_over_a_mask,gpu_wave32_program_in_wave64_hardware.graphics_round_trip,a_torn_frame_written_over_is_read_again,done_file_of_another_binary_is_replaced_and_a_torn_record_cut,used_pipelines_first_done_ones_skipped_journal_followed,only_what_was_in_flight_with_this_binary_counts_as_crashed.XCL_ADAPTER=radeon),cargo test --workspace -- --test-threads=4: 706 passed, 0 failed, 41 ignored, no skips.Not tested
AI use
@JoaoPauluu on GitHub · 2026-11-24 15:37 UTC · original
A run of this commit under Wine on Linux, where
xcl pipelinesstill crashes (the stack overflow I reported on #759). That makes it a real crash case for the new.tryinghandling, which works as described.Tested
x86_64-pc-windows-gnu.d26b19cas it is (stacked on #759), no uncommitted changes.pipelines.done(406 272 bytes) andpipelines.trying(296 bytes) were written by #759's788e366build.57807 pipelines to make (228 the title used), 0 done before. The other binary's files were not taken, and there was no "last run ended" line. At 50 600 done it ended after 162 s withthread 'xcl-warm-0' has overflowed its stack, exit 5. It leftpipelines.tryingat 810 424 bytes.the last run ended while making 6 pipelines: left to the title, then7153 pipelines to make (0 the title used), 50654 done before. So of everything run 1 started, only the 6 in flight at the crash were skipped. It made 1 driver blob, then crashed again after 5 s (xcl-warm-1overflowed its stack, exit 5).788e366this morning, the reruns also left only 6 to the title after each crash, but there.tryingwas a fresh file per run. This run covers the binary key and the start / end records.Not tested
stop_cleanly_on_ctrl_c);only_what_was_in_flight_with_this_binary_counts_as_crashedand the rest of the suite on this head; native Windows.AI use
@VolenNakov on GitHub · 2026-11-24 21:10 UTC · original
Closing: #759 now does this itself –
d20dc0fkeeps only the pipelines being made in.trying, andbbf56a8makes Ctrl+C a clean stop – so this PR adds nothing on top of it. Thanks @futurepro62 for the full-suite runs (RTX 5070 Ti and the Radeon iGPU), @JoaoPauluu for the real crash case under Wine (only the 6 in-flight pipelines left to the title after 50 600 started), and @DavidM1911 for spotting that the old base no longer builds onmain.AI use: Claude Code (Claude Opus 5.5) wrote this note.
@DavidM1911 on GitHub · 2026-11-26 04:53 UTC · original
Re-verification on RTX 3060 Ti (Windows 11): still a merge conflict with current
mainon the new head — needs another rebase before it can be tested.Pull request closed