Recompiler: a second jump to a pending skip flag stops the code after it (#701) #729
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!729
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/729/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?
@towiice on GitHub · 2026-11-24 04:11 UTC · original
towiice:recompiler-repeated-skip-flag→main· +97 −1 · 2 files · 2 commits · closed without mergingPart of #701 (shape 1). Stacked on #728; only the top commit belongs here. The first structured form guards the items after a forward jump with
if (!(skip flag)), one guard for as long as the set of pending flags stays the same. A second jump to a target whose flag is already pending (two breaks to the same block) leaves the set as it is, so the guard stays open and the items after the jump run although it was taken. The guard is now closed after such a jump; the next item opens a new one that tests the flags again.What is in it
crates/xcl/src/gpu/recomp/mod.rs(emit_structured): close the open guard when an item raises a target that is already pending.crates/xcl/src/gpu/recomp/tests.rs:gpu_a_second_jump_to_a_pending_target_skips_what_follows: a loop with two breaks to the same block and an if before the latch, run on the GPU in the structured form and in thepcchain, five (s10, s11, s12) combinations.Tested
x86_64-pc-windows-gnullvm(llvm-mingw 20261117), DXC 1.9.2609.5, debugstructured: true, s10 = 1, s11 = 0, s12 = 1:(1, 1, 0), want(0, 1, 0)) and passes with itcargo test -p xcl --lib -- --test-threads=4(with DXC): 659 passed, 3 failed, 21 ignored;maingives 657 passed and the same 3 failures (see #728:hle::d3d12xtests that pass when run alone)Regression run
None: I have no title for
scripts/smoke.ps1. This changescrates/xcl/src, so the twoxcl-smokeblocks have to come from someone with a title.main:
not run
PR:
not run
Not tested
scripts/smoke.ps1; wave64; AMD; MSVC; the rest of the workspace on this branch}/ guard reopening changes the HLSL of shaders in a way that matters for compile time; I did not measure itAI use
@LocranKing on GitHub · 2026-11-24 04:46 UTC · original
Tested on Windows 11 + NVIDIA GeForce RTX 3060 Ti (8 GB, wave32).
Tested
425540203e798100f773fcfbadea4004550f49b5(pr-729, clean tree)8024 MiB VRAM, driver32.0.16.2101),rustc 1.100.0(x86_64-pc-windows-msvc, MSVC14.44.35207), DXC1.9.2602.17(SDK10.0.26100.0),--releasecargo test --workspace --release --no-fail-fast -- --test-threads=4: 687 passed, 0 failed, 41 ignored, exit0;2 (no wave64)skipped (gpu_geometry_wave32_prefix_count_over_a_mask,gpu_wave32_program_in_wave64_hardware)Regression run (
scripts/smoke.ps1, 60 s,XCL_NETWORK=0, title folder name redacted)main (
64b3f35):PR #729 (
4255402):Not tested: Debug build,
XCL_SAMPLE_RPF/ shader corpus tests on this branch, AMD / wave64 hardware.AI use: Antigravity (
Gemini 4 Hydrogen) ran the build, tests, and smoke runs and drafted this report from the command outputs.@ItsMrDubey on GitHub · 2026-11-24 04:57 UTC · original
Test report for
425540203e798100f773fcfbadea4004550f49b5(this PR's head)Tested
stable-x86_64-pc-windows-msvc), debug; DXC 1.9.2602.17 from Windows SDK 10.0.2610016 test binaries: 686 passed, 1 failed, 41 ignored. Same machine,
main64b3f3559: 700 passed, 1 failed, 41 ignored.This PR's tests:
gpu::recomp::tests::gpu_a_jump_from_the_if_branch_to_the_else_branch_runs_it: okgpu::recomp::tests::gpu_a_second_jump_to_a_pending_target_skips_what_follows: okFailures:
hle::kernelx::tests::xmem_virtual_query_marks_cpu_readable_memoryfails on this machine on every run, on this PR's head and onmain64b3f3559alike (5 of 5 reruns onmain), so it is not from this PR. #650 fixes it here.16 test binaries instead of
main's 17 because this branch predatestests/sparse_reinit.rs; nothing crashed.SKIPPED (no wave64 on this GPU):
gpu_geometry_wave32_prefix_count_over_a_mask,gpu_wave32_program_in_wave64_hardware.AI use: Claude Code (Claude Opus 5.5) ran the builds and tests and wrote this report from their output.
@QemmHD on GitHub · 2026-11-24 05:03 UTC · original · edited 2026-11-24 05:04 UTC
Verified on an RTX 4070 SUPER with the #701 harness (QemmHD/xcl
review/701-fixes,fed3380). On its own, this PR'smod.rschange fixes shape 1: random first-form programs that walk wrong go from 513 to 116 of 4 785, and GPU mismatches from 14 to 4 of 1 200. Your test needs #728'srun_scalar_program. With #728: 7 on the CPU, 2 on the GPU, the full suite gives 715 passed / 0 failed / 41 ignored (main: 701 / 0 / 41), and no program that was right onmainbreaks. The 7 leftovers are a nested variant of shape 2; details and a one-line fix are on #728. Nit:mod.rs:1011has a raw newline inside the format string where\nwould read better (same behaviour).AI-assisted (Claude Code, Claude Opus 5.5).
Discord: bigpeppa.
@raylitebull on GitHub · 2026-11-24 10:44 UTC · original
Closing as a duplicate of #765 for #701, which passes the
PR descriptioncheck (whereas this PR failsPR description).Pull request closed