Recompiler: a compute loop's passes shrink with the dispatch's size #2281

Closed
Prime1997 wants to merge 1 commit from upstream-pr/2291 into main
Prime1997 commented 2026-11-25 12:29:38 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Prime1997 on 2026-11-25T12:29:38Z.


Requested by Prime

A lane may run 65 536 loop passes before LOOP_GUARD ends its loops, so that console code looping on a count XCL gave it wrong does not keep the GPU busy. The bound is per lane, so the work it allows grows with the dispatch: WindNew:CS_AdvectFromParentStep (a542b07e605c8fd7) runs as 16 x 16 x 16 groups of 64 threads, and with a loop count that never comes that is about 31 s on an RTX 3060 Ti, where Windows removes the device after 2 s (the open dispatch of #1452; measurements in this comment). With this change every entry of a loop in a compute program has its own count of passes that shrinks with the dispatch's size, so a loop that runs away on its own ends in time. Part of #1452.

What is in it

  • crates/xcl/src/gpu/recomp/mod.rs: IO_LOOP_BUDGET (io slot 113, free in the trap-temp range), DISPATCH_LOOP_PASSES (2^28), dispatch_loop_budget(groups); the two loop emitters ask Em::loop_guard for what goes before a loop and at its top.
  • crates/xcl/src/gpu/recomp/emit.rs: Em::loop_guard. In a compute program a loop gets uint xcl_nK = xcl_cap; before it and if (xcl_nK == 0u) break; xcl_nK--; in front of the existing guard; the entry point sets xcl_cap = clamp(slot / threads per group, 1024, 65536) when the slot is not 0. The lane's budget of 65 536 for all its loops stays, so loops inside one another are not cut to one loop's share. Other stages and programs without a loop emit the HLSL they did.
  • crates/xcl/src/hle/d3d12x/bind.rs, console_list.rs: a direct dispatch writes its share (2^28 / groups) into the slot. An indirect dispatch leaves 0: 65 536 as before.
  • crates/xcl/src/gpu/recomp/tests.rs: dispatch_loop_budget_shrinks_with_the_groups, only_compute_programs_with_a_loop_read_the_dispatch_loop_budget (no GPU), gpu_compute_loop_passes_follow_the_dispatch.

Up to 4096 lanes nothing changes. At 16 x 16 x 16 groups of 64 threads one entry of a loop ends after 1024 passes.

Tested

  • hardware (GPU + driver, CPU), Rust version, debug / release: NVIDIA GeForce RTX 3060 Ti 8 GB (driver 617.14), Intel Core i5-10400, Windows 11 26200, Rust 1.100.0, debug.
  • cargo test -p xcl --lib -- gpu_compute_loop_passes_follow_the_dispatch dispatch_loop_budget_shrinks only_compute_programs_with_a_loop: 3 passed, 0 failed, no SKIPPED. The GPU test runs a loop that never ends as a wave32 and as a split wave64 program: it stops after 65 536 passes with the slot at 0, after 5000 and 1024 for shares of that size, and entered three times it runs 3 x 1024.
  • 62 compute programs of a retail title that have loops (every sixth by size of 346, and the five with the most loops, up to 95) compile with DXC with the new guard: 62 ok, 0 failed.
  • The a542 program alone on the GPU with a count that never comes, 16 x 16 x 16 groups: 485 ms when the loop is ended after 1024 passes, against about 31 s for 65 536 (0.47 ms a pass measured). That was measured with an earlier form of this change that set the lane's total to the same 1024; I have not timed this head yet.
  • cargo test --workspace -- --test-threads=4: 1157 passed, 0 failed, 46 ignored (SKIPPED GPU tests: 25 – 20 need 64-lane waves, 3 are cases the direct per-lane form refuses, heap_window_out_of_memory_falls_back_to_the_switch_form (no heap windows), pso_measurement_compiles_an_exact_synthetic_record (needs Windows Developer Mode)).

Regression run

Seeded 60 s runs without input (the same copied profile and shader cache for each, release builds from clean checkouts of the two commits, XCL_HEAP_WINDOWS=1 XCL_LAZY_PSO=1 XCL_LAZY_COMPUTE=1 XCL_PSO_PRELOAD=0 XCL_DXC_THREADS=2). The main run is from earlier the same day, not back to back.

main:

xcl-smoke v1
commit: 568e7db7729c8fa6c8f0f4b32d798faaf11462bb
gpu: NVIDIA GeForce RTX 3060 Ti
title: 419239bf
seconds: 60
exit: 0x0
frames shown: 357 (PresentX 357)
presents per 2 s (last 3): 17 18 18
device removals: 0
crashes: 0
peak commit: 15226 MB

PR:

xcl-smoke v1
commit: 4bad50562dd5e1f7c3a26602367904a695296892
gpu: NVIDIA GeForce RTX 3060 Ti
title: 419239bf
seconds: 60
exit: 0x0
frames shown: 416 (PresentX 416)
presents per 2 s (last 3): 23 23 24
device removals: 0
crashes: 0
peak commit: 15191 MB

Not tested

  • The regression run reaches the title's start screen only: it does not reach the wind dispatch. The frame counts differ by run-to-run noise; no performance claim.
  • The title itself past the dispatch that hangs. Why the count is wrong there is not known; this only keeps the device.
  • A loop that runs away with another loop inside it still has the lane's 65 536 passes.
  • The direct DXIL translator keeps its fixed budget.
  • AMD / Intel GPUs, 64-lane hardware.

AI use

  • Claude Code with Claude Fable 5.2 did the measurements, wrote the code, the tests and this description, and opened the PR at Prime's request. The runs were on Prime's machine.

🤖 Generated with Claude Code

<!-- greyfinch-sync:ivall/xcl:issue:5491340718 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291). Originally posted by [Prime1997](https://github.com/Prime1997) on 2026-11-25T12:29:38Z. --- <!-- claude-projects-attribution: {"github_login":"Prime1997"} --> _Requested by **Prime**_ A lane may run 65 536 loop passes before `LOOP_GUARD` ends its loops, so that console code looping on a count XCL gave it wrong does not keep the GPU busy. The bound is per lane, so the work it allows grows with the dispatch: `WindNew:CS_AdvectFromParentStep` (a542b07e605c8fd7) runs as 16 x 16 x 16 groups of 64 threads, and with a loop count that never comes that is about 31 s on an RTX 3060 Ti, where Windows removes the device after 2 s (the open dispatch of #1452; measurements in [this comment](https://github.com/xcl-dev/xcl/issues/1452#issuecomment-7162332475)). With this change every entry of a loop in a compute program has its own count of passes that shrinks with the dispatch's size, so a loop that runs away on its own ends in time. Part of #1452. **What is in it** - `crates/xcl/src/gpu/recomp/mod.rs`: `IO_LOOP_BUDGET` (io slot 113, free in the trap-temp range), `DISPATCH_LOOP_PASSES` (2^28), `dispatch_loop_budget(groups)`; the two loop emitters ask `Em::loop_guard` for what goes before a loop and at its top. - `crates/xcl/src/gpu/recomp/emit.rs`: `Em::loop_guard`. In a compute program a loop gets `uint xcl_nK = xcl_cap;` before it and `if (xcl_nK == 0u) break; xcl_nK--;` in front of the existing guard; the entry point sets `xcl_cap = clamp(slot / threads per group, 1024, 65536)` when the slot is not 0. The lane's budget of 65 536 for all its loops stays, so loops inside one another are not cut to one loop's share. Other stages and programs without a loop emit the HLSL they did. - `crates/xcl/src/hle/d3d12x/bind.rs`, `console_list.rs`: a direct dispatch writes its share (2^28 / groups) into the slot. An indirect dispatch leaves 0: 65 536 as before. - `crates/xcl/src/gpu/recomp/tests.rs`: `dispatch_loop_budget_shrinks_with_the_groups`, `only_compute_programs_with_a_loop_read_the_dispatch_loop_budget` (no GPU), `gpu_compute_loop_passes_follow_the_dispatch`. Up to 4096 lanes nothing changes. At 16 x 16 x 16 groups of 64 threads one entry of a loop ends after 1024 passes. **Tested** - hardware (GPU + driver, CPU), Rust version, debug / release: NVIDIA GeForce RTX 3060 Ti 8 GB (driver 617.14), Intel Core i5-10400, Windows 11 26200, Rust 1.100.0, debug. - `cargo test -p xcl --lib -- gpu_compute_loop_passes_follow_the_dispatch dispatch_loop_budget_shrinks only_compute_programs_with_a_loop`: 3 passed, 0 failed, no SKIPPED. The GPU test runs a loop that never ends as a wave32 and as a split wave64 program: it stops after 65 536 passes with the slot at 0, after 5000 and 1024 for shares of that size, and entered three times it runs 3 x 1024. - 62 compute programs of a retail title that have loops (every sixth by size of 346, and the five with the most loops, up to 95) compile with DXC with the new guard: 62 ok, 0 failed. - The a542 program alone on the GPU with a count that never comes, 16 x 16 x 16 groups: 485 ms when the loop is ended after 1024 passes, against about 31 s for 65 536 (0.47 ms a pass measured). That was measured with an earlier form of this change that set the lane's total to the same 1024; I have not timed this head yet. - `cargo test --workspace -- --test-threads=4`: 1157 passed, 0 failed, 46 ignored (SKIPPED GPU tests: 25 – 20 need 64-lane waves, 3 are cases the direct per-lane form refuses, `heap_window_out_of_memory_falls_back_to_the_switch_form` (no heap windows), `pso_measurement_compiles_an_exact_synthetic_record` (needs Windows Developer Mode)). **Regression run** Seeded 60 s runs without input (the same copied profile and shader cache for each, release builds from clean checkouts of the two commits, `XCL_HEAP_WINDOWS=1 XCL_LAZY_PSO=1 XCL_LAZY_COMPUTE=1 XCL_PSO_PRELOAD=0 XCL_DXC_THREADS=2`). The main run is from earlier the same day, not back to back. main: ``` xcl-smoke v1 commit: 568e7db7729c8fa6c8f0f4b32d798faaf11462bb gpu: NVIDIA GeForce RTX 3060 Ti title: 419239bf seconds: 60 exit: 0x0 frames shown: 357 (PresentX 357) presents per 2 s (last 3): 17 18 18 device removals: 0 crashes: 0 peak commit: 15226 MB ``` PR: ``` xcl-smoke v1 commit: 4bad50562dd5e1f7c3a26602367904a695296892 gpu: NVIDIA GeForce RTX 3060 Ti title: 419239bf seconds: 60 exit: 0x0 frames shown: 416 (PresentX 416) presents per 2 s (last 3): 23 23 24 device removals: 0 crashes: 0 peak commit: 15191 MB ``` **Not tested** - The regression run reaches the title's start screen only: it does not reach the wind dispatch. The frame counts differ by run-to-run noise; no performance claim. - The title itself past the dispatch that hangs. Why the count is wrong there is not known; this only keeps the device. - A loop that runs away with another loop inside it still has the lane's 65 536 passes. - The direct DXIL translator keeps its fixed budget. - AMD / Intel GPUs, 64-lane hardware. **AI use** - Claude Code with Claude Fable 5.2 did the measurements, wrote the code, the tests and this description, and opened the PR at Prime's request. The runs were on Prime's machine. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
upipibi commented 2026-11-25 13:05:15 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by upipibi on 2026-11-25T12:51:21Z.


@Prime1997 A heads-up from our #1284 (XCL_LOOP_BUDGET, mergeable, head f3eb053). It isn't a duplicate, but the two meet in the same place:

  • #1284 makes the per-lane xcl_budget that LOOP_GUARD counts down configurable: XCL_LOOP_BUDGET swaps the prelude's 1u << 16 for any whole number from 1. This PR adds a per-loop xcl_cap in front of that guard, defaulting to 1u << 16 and clamped to 1024..=1u << 16 (emit.rs:4699, :4873 at 4bad505). With both merged, raising XCL_LOOP_BUDGET above 65 536 would no longer let a single loop in a compute program run longer, because xcl_cap would end it first. Lowering it still works, because LOOP_GUARD fires first.
  • They also conflict as text: git merge-tree of the two heads stops in recomp/emit.rs and recomp/mod.rs.

If the upper bound of the clamp (and xcl_cap's default) took loop_budget() from #1284 instead of a literal 1u << 16, the two would compose. Whichever merges second needs that. I'm happy to rebase #1284 onto this one if it lands first.

AI-assisted (Claude Code). Read from the two diffs only; nothing run.

<!-- greyfinch-sync:ivall/xcl:comment:7162950475 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7162950475). Originally posted by [upipibi](https://github.com/upipibi) on 2026-11-25T12:51:21Z. --- @Prime1997 A heads-up from our #1284 (`XCL_LOOP_BUDGET`, mergeable, head `f3eb053`). It isn't a duplicate, but the two meet in the same place: - #1284 makes the per-lane `xcl_budget` that `LOOP_GUARD` counts down configurable: `XCL_LOOP_BUDGET` swaps the prelude's `1u << 16` for any whole number from 1. This PR adds a per-loop `xcl_cap` in front of that guard, defaulting to `1u << 16` and clamped to `1024..=1u << 16` (`emit.rs:4699`, `:4873` at `4bad505`). With both merged, raising `XCL_LOOP_BUDGET` above 65 536 would no longer let a single loop in a compute program run longer, because `xcl_cap` would end it first. Lowering it still works, because `LOOP_GUARD` fires first. - They also conflict as text: `git merge-tree` of the two heads stops in `recomp/emit.rs` and `recomp/mod.rs`. If the upper bound of the clamp (and `xcl_cap`'s default) took `loop_budget()` from #1284 instead of a literal `1u << 16`, the two would compose. Whichever merges second needs that. I'm happy to rebase #1284 onto this one if it lands first. AI-assisted (Claude Code). Read from the two diffs only; nothing run.
oni-swr commented 2026-11-25 14:09:58 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-25T13:19:11Z.


AMD RDNA3 (native wave64) test report for exact head 4bad50562dd5e1f7c3a26602367904a695296892, as pushed (not merged onto current main).

Tested

  • AMD Radeon RX 7800 XT (RDNA3, native wave64), driver 32.0.31035.1003; Windows 11 Pro 10.0.26200; Rust 1.100.0 (stable-x86_64-pc-windows-msvc); debug; DXC 1.9.0.5512 (dxcompiler.dll)
  • cargo build --workspace: ok
  • Targeted: dispatch_loop_budget_shrinks_with_the_groups, only_compute_programs_with_a_loop_read_the_dispatch_loop_budget, gpu_compute_loop_passes_follow_the_dispatch: 3 passed, 0 failed (the GPU one ran, not skipped)
  • cargo test --workspace --no-fail-fast -- --test-threads=4: 1156 passed, 1 failed, 46 ignored (summed over all test binaries)
  • SKIPPED: 7 lines in the full run (6 `lower_dxil` f16/f32 per-lane-form cases "refused (unsupported V_MUL_F16 / V_PK_MUL_F16 / V_CVT_F16_F32 ... #1426 semantics)", plus `heap_window_out_of_memory_falls_back_to_the_switch_form: no heap windows`). The one failure is `gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1` (seed 722: res[30] = 0x1, CPU 0x7fffffff). It is not in code this PR touches, and I reproduced the same failure and seed on `main` at `1a0bbe3` with `cargo test -p xcl --lib fuzz_validate_and_gpu_1`, so it is pre-existing on RDNA3, not caused by this PR.

Not tested

  • No game title, no scripts/smoke.ps1 regression run (synthetic GPU/unit tests only)
  • Not merged onto current main; other GPUs (NVIDIA / Intel / RDNA2 / RDNA4)
  • Whether the new tests fail without the fix; the interaction with #1284 (XCL_LOOP_BUDGET) mentioned in the comments

AI use: Claude Code (Claude Sonnet 5.5) ran the build and tests and wrote this report; the numbers are from the runs above.

<!-- greyfinch-sync:ivall/xcl:comment:7163604789 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7163604789). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-25T13:19:11Z. --- AMD RDNA3 (native wave64) test report for exact head `4bad50562dd5e1f7c3a26602367904a695296892`, as pushed (not merged onto current `main`). **Tested** - AMD Radeon RX 7800 XT (RDNA3, native wave64), driver 32.0.31035.1003; Windows 11 Pro 10.0.26200; Rust 1.100.0 (stable-x86_64-pc-windows-msvc); debug; DXC 1.9.0.5512 (dxcompiler.dll) - `cargo build --workspace`: ok - Targeted: `dispatch_loop_budget_shrinks_with_the_groups`, `only_compute_programs_with_a_loop_read_the_dispatch_loop_budget`, `gpu_compute_loop_passes_follow_the_dispatch`: 3 passed, 0 failed (the GPU one ran, not skipped) - `cargo test --workspace --no-fail-fast -- --test-threads=4`: 1156 passed, 1 failed, 46 ignored (summed over all test binaries) - SKIPPED: 7 lines in the full run (6 \`lower_dxil\` f16/f32 per-lane-form cases "refused (unsupported V_MUL_F16 / V_PK_MUL_F16 / V_CVT_F16_F32 ... #1426 semantics)", plus \`heap_window_out_of_memory_falls_back_to_the_switch_form: no heap windows\`). The one failure is \`gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1\` (seed 722: res[30] = 0x1, CPU 0x7fffffff). It is not in code this PR touches, and I reproduced the same failure and seed on \`main\` at \`1a0bbe3\` with \`cargo test -p xcl --lib fuzz_validate_and_gpu_1\`, so it is pre-existing on RDNA3, not caused by this PR. **Not tested** - No game title, no `scripts/smoke.ps1` regression run (synthetic GPU/unit tests only) - Not merged onto current `main`; other GPUs (NVIDIA / Intel / RDNA2 / RDNA4) - Whether the new tests fail without the fix; the interaction with #1284 (`XCL_LOOP_BUDGET`) mentioned in the comments **AI use**: Claude Code (Claude Sonnet 5.5) ran the build and tests and wrote this report; the numbers are from the runs above.
Lum7nt commented 2026-11-25 14:09:58 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Lum7nt on 2026-11-25T13:10:09Z.


AMD targeted tests on clean head 4bad50562dd5e1f7c3a26602367904a695296892: Windows 11 build 26300, Radeon RX 9070 XT (driver 32.0.32029.2010), Rust 1.100.0 MSVC, DXC/DXIL 1.9.2609.5, release profile. Set XCL_ADAPTER=9070 XT, XCL_REQUIRE_GPU=wave64. For each filter below I ran cargo test --offline --locked --release -p xcl --lib <filter> -- --nocapture --test-threads=1:

  • gpu_compute_loop_passes_follow_the_dispatch: 1 passed, 0 failed, 0 ignored.
  • dispatch_loop_budget_shrinks_with_the_groups: 1 passed, 0 failed, 0 ignored.
  • only_compute_programs_with_a_loop_read_the_dispatch_loop_budget: 1 passed, 0 failed, 0 ignored.

No SKIPPED messages. The first is the small single-group GPU fixture covering wave32 and wave64 program options and the different loop limits; the other two are CPU checks.

60 s retail smoke comparison: clean release builds; PR run first, then main. Same title, XCL_ADAPTER=9070 XT, XCL_HEAP_WINDOWS=1, XCL_PSO_PRELOAD=0; no automated input. The PR produced 254 frames versus main’s 1556 (16.3%, below the 80% comparison threshold), with zero recorded crashes or device removals. This single pair is order-sensitive and does not establish a cause or a reproducible regression; caches and profile state were not reset between runs. The last three PR present intervals recovered to 11, 59, 60.

Main:

xcl-smoke v1
commit: 1a0bbe3a2ba91ea8f5b6fc29130a053868d3c9e6
gpu: AMD Radeon RX 9070 XT
title: 3c290c16
seconds: 60
exit: 0x0
frames shown: 1556 (PresentX 1557)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14676 MB

PR:

xcl-smoke v1
commit: 4bad50562dd5e1f7c3a26602367904a695296892
gpu: AMD Radeon RX 9070 XT
title: 3c290c16
seconds: 60
exit: 0x0
frames shown: 254 (PresentX 254)
presents per 2 s (last 3): 11 59 60
device removals: 0
crashes: 0
peak commit: 15323 MB

Not tested: the large wind dispatch, progression past the loading hang, full workspace, or a controlled cache/profile comparison.

Repeat after main: Same settings and no reset; PR/main/PR run order. The repeated PR run showed 1577 frames, compared with 1556 on main. This makes the first result non-reproducible in this sequence but does not identify its cause.

xcl-smoke v1
commit: 4bad50562dd5e1f7c3a26602367904a695296892
gpu: AMD Radeon RX 9070 XT
title: 3c290c16
seconds: 60
exit: 0x0
frames shown: 1577 (PresentX 1577)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15041 MB

AI use: OpenAI Codex (GPT-6; exact variant unavailable) ran the tests and smoke pair and drafted this report.

<!-- greyfinch-sync:ivall/xcl:comment:7163388645 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7163388645). Originally posted by [Lum7nt](https://github.com/Lum7nt) on 2026-11-25T13:10:09Z. --- **AMD targeted tests** on clean head `4bad50562dd5e1f7c3a26602367904a695296892`: Windows 11 build 26300, Radeon RX 9070 XT (driver `32.0.32029.2010`), Rust 1.100.0 MSVC, DXC/DXIL 1.9.2609.5, release profile. Set `XCL_ADAPTER=9070 XT`, `XCL_REQUIRE_GPU=wave64`. For each filter below I ran `cargo test --offline --locked --release -p xcl --lib <filter> -- --nocapture --test-threads=1`: - `gpu_compute_loop_passes_follow_the_dispatch`: 1 passed, 0 failed, 0 ignored. - `dispatch_loop_budget_shrinks_with_the_groups`: 1 passed, 0 failed, 0 ignored. - `only_compute_programs_with_a_loop_read_the_dispatch_loop_budget`: 1 passed, 0 failed, 0 ignored. No SKIPPED messages. The first is the small single-group GPU fixture covering wave32 and wave64 program options and the different loop limits; the other two are CPU checks. **60 s retail smoke comparison:** clean release builds; PR run first, then main. Same title, `XCL_ADAPTER=9070 XT`, `XCL_HEAP_WINDOWS=1`, `XCL_PSO_PRELOAD=0`; no automated input. The PR produced 254 frames versus main’s 1556 (16.3%, below the 80% comparison threshold), with zero recorded crashes or device removals. This single pair is order-sensitive and does not establish a cause or a reproducible regression; caches and profile state were not reset between runs. The last three PR present intervals recovered to 11, 59, 60. Main: ``` xcl-smoke v1 commit: 1a0bbe3a2ba91ea8f5b6fc29130a053868d3c9e6 gpu: AMD Radeon RX 9070 XT title: 3c290c16 seconds: 60 exit: 0x0 frames shown: 1556 (PresentX 1557) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14676 MB ``` PR: ``` xcl-smoke v1 commit: 4bad50562dd5e1f7c3a26602367904a695296892 gpu: AMD Radeon RX 9070 XT title: 3c290c16 seconds: 60 exit: 0x0 frames shown: 254 (PresentX 254) presents per 2 s (last 3): 11 59 60 device removals: 0 crashes: 0 peak commit: 15323 MB ``` Not tested: the large wind dispatch, progression past the loading hang, full workspace, or a controlled cache/profile comparison. **Repeat after main:** Same settings and no reset; PR/main/PR run order. The repeated PR run showed 1577 frames, compared with 1556 on main. This makes the first result non-reproducible in this sequence but does not identify its cause. ``` xcl-smoke v1 commit: 4bad50562dd5e1f7c3a26602367904a695296892 gpu: AMD Radeon RX 9070 XT title: 3c290c16 seconds: 60 exit: 0x0 frames shown: 1577 (PresentX 1577) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15041 MB ``` AI use: OpenAI Codex (GPT-6; exact variant unavailable) ran the tests and smoke pair and drafted this report.
nnonno91 commented 2026-11-25 15:08:01 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by nnonno91 on 2026-11-25T14:52:59Z.


Independent Radeon iGPU and RTX 5090 check of 4bad50562dd5e1f7c3a26602367904a695296892, including the first two budgets on either side of the floor at 1,024 passes.

Tested

  • Windows 11 25H2 build 26200.9974, Ryzen 7 9800X3D, Rust 1.100.0 MSVC, SDK DXC/DXIL 1.8.2502.11, unoptimized profile. AMD Radeon(TM) Graphics driver 32.0.21042.62 and RTX 5090 driver 32.0.16.1742.
  • cargo test --locked -p xcl --lib -- dispatch_loop_budget --nocapture --test-threads=1 gave 2 passed, 0 failed on the unchanged head.
  • I added two cases to the GPU fixture: with 64 threads per group, slot values 65,599 and 65,600 had to end the loop after 1,024 and 1,025 passes respectively. cargo test --locked -p xcl --lib gpu_compute_loop_passes_follow_the_dispatch -- --nocapture --test-threads=1 gave 1 passed, 0 failed on each adapter selected by XCL_ADAPTER. The cases ran in wave32 and logical wave64 on both GPUs. All other cases in the fixture also passed, including repeated loop entry. Zero ignores or skips in all runs. The two temporary cases were removed.

Not tested

A retail dispatch, indirect dispatch behavior in an end-to-end run, the parent and the full workspace suite.

AI use

OpenAI Codex (GPT-6.2 Sol) added the temporary boundary cases, ran the checks and wrote this report.

<!-- greyfinch-sync:ivall/xcl:comment:7165962953 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7165962953). Originally posted by [nnonno91](https://github.com/nnonno91) on 2026-11-25T14:52:59Z. --- Independent Radeon iGPU and RTX 5090 check of `4bad50562dd5e1f7c3a26602367904a695296892`, including the first two budgets on either side of the floor at 1,024 passes. **Tested** - Windows 11 25H2 build 26200.9974, Ryzen 7 9800X3D, Rust 1.100.0 MSVC, SDK DXC/DXIL 1.8.2502.11, unoptimized profile. AMD Radeon(TM) Graphics driver 32.0.21042.62 and RTX 5090 driver 32.0.16.1742. - `cargo test --locked -p xcl --lib -- dispatch_loop_budget --nocapture --test-threads=1` gave 2 passed, 0 failed on the unchanged head. - I added two cases to the GPU fixture: with 64 threads per group, slot values 65,599 and 65,600 had to end the loop after 1,024 and 1,025 passes respectively. `cargo test --locked -p xcl --lib gpu_compute_loop_passes_follow_the_dispatch -- --nocapture --test-threads=1` gave 1 passed, 0 failed on each adapter selected by `XCL_ADAPTER`. The cases ran in wave32 and logical wave64 on both GPUs. All other cases in the fixture also passed, including repeated loop entry. Zero ignores or skips in all runs. The two temporary cases were removed. **Not tested** A retail dispatch, indirect dispatch behavior in an end-to-end run, the parent and the full workspace suite. **AI use** OpenAI Codex (GPT-6.2 Sol) added the temporary boundary cases, ran the checks and wrote this report.
Prime1997 commented 2026-11-25 17:07:23 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Prime1997 on 2026-11-25T16:33:56Z.


@upipibi agreed, and thanks for reading both diffs. The two compose the way you describe: the cap's default and the clamp's upper bound are the prelude's literal 65 536 only because loop_budget() is not on main. If #1284 lands first I rebase and take loop_budget() in both places; if this one lands first, that is the same two-line change in your rebase.

Thanks @Lum7nt, @oni-swr and @nnonno91 for the runs on AMD (native wave64 included) and the boundary cases at 1024 / 1025 passes.

Two updates from my side:

  • Rebase. main moved under this (3f4495a, #2080 changed translated_dispatch), so the PR shows a conflict. The rebased commit is ready (bind_abi(…, Some([x, y, z])), then the dispatch chain as main has it; targeted tests 3 passed, workspace suite 1278 passed, 0 failed, 46 ignored on the RTX 3060 Ti). I push it together with its regression run so the description never names a head it was not run on.
  • Timing with the final form (the earlier 485 ms was measured with a first version that cut the lane's total): in the translation of a build that carries this commit, with the slot as bind_abi writes it for 16 x 16 x 16 groups, one a542 dispatch with a count that never comes takes 511 ms (271 ms for 2048 groups, 121 ms for 1024). Counts of 0 / 64 / 256 take 1.0 / 6.8 / 23 ms as before.
  • A limit I measured the hard way: the cap bounds one dispatch. Five of those 511 ms dispatches back to back in one command list were removed on this card (0x887a0006); one alone was not. So if a title issues several runaway dispatches in a row, this is not enough on its own. The same reasoning says a dispatch that main now runs in slabs (#2080) should keep the whole dispatch's size for the slot, which the rebase does.

AI use: Claude Code (Claude Fable 5.2) wrote this and ran the measurements on Prime's machine.

<!-- greyfinch-sync:ivall/xcl:comment:7168182494 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7168182494). Originally posted by [Prime1997](https://github.com/Prime1997) on 2026-11-25T16:33:56Z. --- @upipibi agreed, and thanks for reading both diffs. The two compose the way you describe: the cap's default and the clamp's upper bound are the prelude's literal 65 536 only because `loop_budget()` is not on `main`. If #1284 lands first I rebase and take `loop_budget()` in both places; if this one lands first, that is the same two-line change in your rebase. Thanks @Lum7nt, @oni-swr and @nnonno91 for the runs on AMD (native wave64 included) and the boundary cases at 1024 / 1025 passes. Two updates from my side: - **Rebase.** `main` moved under this (3f4495a, #2080 changed `translated_dispatch`), so the PR shows a conflict. The rebased commit is ready (`bind_abi(…, Some([x, y, z]))`, then the dispatch chain as `main` has it; targeted tests 3 passed, workspace suite 1278 passed, 0 failed, 46 ignored on the RTX 3060 Ti). I push it together with its regression run so the description never names a head it was not run on. - **Timing with the final form** (the earlier 485 ms was measured with a first version that cut the lane's total): in the translation of a build that carries this commit, with the slot as `bind_abi` writes it for 16 x 16 x 16 groups, one a542 dispatch with a count that never comes takes 511 ms (271 ms for 2048 groups, 121 ms for 1024). Counts of 0 / 64 / 256 take 1.0 / 6.8 / 23 ms as before. - **A limit I measured the hard way:** the cap bounds one dispatch. Five of those 511 ms dispatches back to back in one command list were removed on this card (`0x887a0006`); one alone was not. So if a title issues several runaway dispatches in a row, this is not enough on its own. The same reasoning says a dispatch that `main` now runs in slabs (#2080) should keep the whole dispatch's size for the slot, which the rebase does. AI use: Claude Code (Claude Fable 5.2) wrote this and ran the measurements on Prime's machine.
DavidM1911 commented 2026-11-25 18:04:35 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-25T17:29:47Z.


Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)

Thanks!

<!-- greyfinch-sync:ivall/xcl:comment:7169585915 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7169585915). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-25T17:29:47Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.) Thanks!
thehollowedone commented 2026-11-29 04:36:17 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by thehollowedone on 2026-11-29T04:36:17Z.


Independent synthetic RTX 3080 Ti check of #2291 head 4bad505 and its exact parent 1a0bbe3. Windows 11 build 26300, NVIDIA 621.35, Ryzen 7 9800X3D, rustc 1.99.1, DXC 1.8.2502.11. A finite synthetic RDNA2 compute loop increments until its own target of 1,025, then stores the count. On the PR head, the GPU returned 1,025 with slot 113 = 0 and 1,024 with slot 113 = dispatch_loop_budget([16,16,16]). The same test on the parent returned 1,025 with both slot values. Command on each: cargo test --offline --locked -j 4 -p xcl --lib gpu_finite_loop_keeps_its_result_above_the_dispatch_share -- --test-threads=1 --nocapture; head 0 passed, 1 failed, parent 1 passed, 0 failed, no ignores or skips.

The fixture launches only one group and supplies the slot value that production calculates for a 16×16×16-group, 64-thread dispatch. It verifies the per-lane HLSL behavior without making a large dispatch or claiming a title result. This demonstrates a valid finite loop can silently produce a different output under the new default cap. The existing endless-loop test proves the cutoff works, but cannot establish output parity for valid counts above it. I would keep the dispatch-sized cutoff out of the default correctness path. For the reported world-load hang, #2205 can help trace the count passed to the affected dispatch; the value the GPU actually consumes and its producer ordering still need verification. A general threshold cannot distinguish stale input from a valid long loop. Current-main integration, the full suite and clean-head smoke still need rechecking.

Failing PR-head GPU regression (passes on its parent with slot 113 = 65,536)
diff --git a/crates/xcl/src/gpu/recomp/tests.rs b/crates/xcl/src/gpu/recomp/tests.rs
index 3433d5f8..1df211d9 100644
--- a/crates/xcl/src/gpu/recomp/tests.rs
+++ b/crates/xcl/src/gpu/recomp/tests.rs
@@ -7306,6 +7306,37 @@ fn gpu_compute_loop_passes_follow_the_dispatch() {
     }
 }
 
+/// A finite console loop must finish at its own exit, even when dispatched in many groups.
+#[test]
+fn gpu_finite_loop_keeps_its_result_above_the_dispatch_share() {
+    if !gpu_ready() {
+        return;
+    }
+    let p = prog(&[
+        ("S_MOV_B32", "ENC_SOP1", &[("SDST", 11), ("SSRC0", 255)], Some(1025)),
+        ("S_MOV_B32", "ENC_SOP1", &[("SDST", 10), ("SSRC0", 128)], None),
+        ("S_ADD_U32", "ENC_SOP2", &[("SDST", 10), ("SSRC0", 10), ("SSRC1", 129)], None),
+        ("S_CMP_LG_U32", "ENC_SOPC", &[("SSRC0", 10), ("SSRC1", 11)], None),
+        ("S_CBRANCH_SCC1", "ENC_SOPP", &[("SIMM16", 0xFFFD)], None),
+        ("V_MOV_B32", "ENC_VOP1", &[("VDST", 4), ("SRC0", 10)], None),
+        ("V_LSHLREV_B32", "ENC_VOP2", &[("VDST", 6), ("SRC0", 130), ("VSRC1", 0)], None),
+        ("V_MOV_B32", "ENC_VOP1", &[("VDST", 7), ("SRC0", 128)], None),
+        ("GLOBAL_STORE_DWORD", "ENC_FLAT_GLBL", &[("ADDR", 6), ("DATA", 4), ("SADDR", 0x7D)], None),
+    ]);
+    let cs = super::CsInterface { threads: [64, 1, 1], user_sgprs: 2, tgid: [false; 3], tg_size: false, tid_components: 1 };
+    let opt = on_gpu(Options { mode: Mode::Compute(cs), wave64: false, ..Default::default() });
+    let t = translate(&p, &opt).unwrap();
+    assert!(t.complete(), "{:?}", t.unsupported_why);
+    let dxil = super::dxc::compile(&t.hlsl, "main", "cs_6_6", &[]).unwrap();
+    let mut io = [0u32; 128];
+    let input = vec![0xffff_ffff; 64];
+    let uncapped = runner::dispatch(&dxil, [1, 1, 1], &io, &input).unwrap();
+    assert_eq!(uncapped[0], 1025, "control: finite loop exits by its own count");
+    io[super::IO_LOOP_BUDGET] = super::dispatch_loop_budget([16, 16, 16]);
+    let capped = runner::dispatch(&dxil, [1, 1, 1], &io, &input).unwrap();
+    assert_eq!(capped[0], 1025, "the dispatch size must not truncate a finite loop");
+}
+
 /// v_fract_f32 at the edges, as RDNA computes it (x - floor(x) kept below 1.0): ±inf gives
 /// NaN and a NaN stays NaN – a `min()` clamp returned 0.99999994 there on NVIDIA (HLSL min
 /// returns its non-NaN operand); a tiny negative value rounds to the largest float below 1.

AI use: Codex (GPT-6.2 Sol) built and ran both GPU checks and wrote this report; Codex (GPT-6.2 Astra) independently traced the loop-cap and dispatch paths.

<!-- greyfinch-sync:ivall/xcl:comment:7250752360 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7250752360). Originally posted by [thehollowedone](https://github.com/thehollowedone) on 2026-11-29T04:36:17Z. --- Independent synthetic RTX 3080 Ti check of [#2291 head `4bad505`](https://github.com/xcl-dev/xcl/commit/4bad50562dd5e1f7c3a26602367904a695296892) and its [exact parent `1a0bbe3`](https://github.com/xcl-dev/xcl/commit/1a0bbe3a2ba91ea8f5b6fc29130a053868d3c9e6). Windows 11 build 26300, NVIDIA 621.35, Ryzen 7 9800X3D, rustc 1.99.1, DXC 1.8.2502.11. A finite synthetic RDNA2 compute loop increments until its own target of 1,025, then stores the count. On the PR head, the GPU returned **1,025 with slot 113 = 0** and **1,024 with slot 113 = `dispatch_loop_budget([16,16,16])`**. The same test on the parent returned 1,025 with both slot values. Command on each: `cargo test --offline --locked -j 4 -p xcl --lib gpu_finite_loop_keeps_its_result_above_the_dispatch_share -- --test-threads=1 --nocapture`; head **0 passed, 1 failed**, parent **1 passed, 0 failed**, no ignores or skips. The fixture launches only one group and supplies the slot value that production calculates for a 16×16×16-group, 64-thread dispatch. It verifies the per-lane HLSL behavior without making a large dispatch or claiming a title result. This demonstrates a valid finite loop can silently produce a different output under the new default cap. The existing endless-loop test proves the cutoff works, but cannot establish output parity for valid counts above it. I would keep the dispatch-sized cutoff out of the default correctness path. For the reported world-load hang, [#2205](https://github.com/xcl-dev/xcl/pull/2205) can help trace the count passed to the affected dispatch; the value the GPU actually consumes and its producer ordering still need verification. A general threshold cannot distinguish stale input from a valid long loop. Current-main integration, the full suite and clean-head smoke still need rechecking. <details><summary>Failing PR-head GPU regression (passes on its parent with slot 113 = 65,536)</summary> ```diff diff --git a/crates/xcl/src/gpu/recomp/tests.rs b/crates/xcl/src/gpu/recomp/tests.rs index 3433d5f8..1df211d9 100644 --- a/crates/xcl/src/gpu/recomp/tests.rs +++ b/crates/xcl/src/gpu/recomp/tests.rs @@ -7306,6 +7306,37 @@ fn gpu_compute_loop_passes_follow_the_dispatch() { } } +/// A finite console loop must finish at its own exit, even when dispatched in many groups. +#[test] +fn gpu_finite_loop_keeps_its_result_above_the_dispatch_share() { + if !gpu_ready() { + return; + } + let p = prog(&[ + ("S_MOV_B32", "ENC_SOP1", &[("SDST", 11), ("SSRC0", 255)], Some(1025)), + ("S_MOV_B32", "ENC_SOP1", &[("SDST", 10), ("SSRC0", 128)], None), + ("S_ADD_U32", "ENC_SOP2", &[("SDST", 10), ("SSRC0", 10), ("SSRC1", 129)], None), + ("S_CMP_LG_U32", "ENC_SOPC", &[("SSRC0", 10), ("SSRC1", 11)], None), + ("S_CBRANCH_SCC1", "ENC_SOPP", &[("SIMM16", 0xFFFD)], None), + ("V_MOV_B32", "ENC_VOP1", &[("VDST", 4), ("SRC0", 10)], None), + ("V_LSHLREV_B32", "ENC_VOP2", &[("VDST", 6), ("SRC0", 130), ("VSRC1", 0)], None), + ("V_MOV_B32", "ENC_VOP1", &[("VDST", 7), ("SRC0", 128)], None), + ("GLOBAL_STORE_DWORD", "ENC_FLAT_GLBL", &[("ADDR", 6), ("DATA", 4), ("SADDR", 0x7D)], None), + ]); + let cs = super::CsInterface { threads: [64, 1, 1], user_sgprs: 2, tgid: [false; 3], tg_size: false, tid_components: 1 }; + let opt = on_gpu(Options { mode: Mode::Compute(cs), wave64: false, ..Default::default() }); + let t = translate(&p, &opt).unwrap(); + assert!(t.complete(), "{:?}", t.unsupported_why); + let dxil = super::dxc::compile(&t.hlsl, "main", "cs_6_6", &[]).unwrap(); + let mut io = [0u32; 128]; + let input = vec![0xffff_ffff; 64]; + let uncapped = runner::dispatch(&dxil, [1, 1, 1], &io, &input).unwrap(); + assert_eq!(uncapped[0], 1025, "control: finite loop exits by its own count"); + io[super::IO_LOOP_BUDGET] = super::dispatch_loop_budget([16, 16, 16]); + let capped = runner::dispatch(&dxil, [1, 1, 1], &io, &input).unwrap(); + assert_eq!(capped[0], 1025, "the dispatch size must not truncate a finite loop"); +} + /// v_fract_f32 at the edges, as RDNA computes it (x - floor(x) kept below 1.0): ±inf gives /// NaN and a NaN stays NaN – a `min()` clamp returned 0.99999994 there on NVIDIA (HLSL min /// returns its non-NaN operand); a tiny negative value rounds to the largest float below 1. ``` </details> AI use: Codex (GPT-6.2 Sol) built and ran both GPU checks and wrote this report; Codex (GPT-6.2 Astra) independently traced the loop-cap and dispatch paths.
bmjask commented 2026-11-29 22:46:03 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by bmjask on 2026-11-29T22:46:03Z.

Review: COMMENTED


Critical review of current head 4bad5056. Blocking semantic regression: the dispatch-size cap can terminate a valid finite loop before its expected 1,025th iteration in a 16×16×16 dispatch. The independent GPU fixture passed on the parent and failed on this head when the per-dispatch budget was active. A watchdog heuristic must not change a shader's correct result based on dispatch size. Please make the reduced cap opt-in/diagnostic or prove a safe bound for the affected program, and retain the finite-loop regression. This branch also conflicts with main. No local GPU run.

<!-- greyfinch-sync:ivall/xcl:review:6105201009 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#pullrequestreview-6105201009). Originally posted by [bmjask](https://github.com/bmjask) on 2026-11-29T22:46:03Z. **Review:** COMMENTED --- Critical review of current head `4bad5056`. **Blocking semantic regression:** the dispatch-size cap can terminate a *valid finite loop* before its expected 1,025th iteration in a 16×16×16 dispatch. The [independent GPU fixture](https://github.com/xcl-dev/xcl/pull/2291) passed on the parent and failed on this head when the per-dispatch budget was active. A watchdog heuristic must not change a shader's correct result based on dispatch size. Please make the reduced cap opt-in/diagnostic or prove a safe bound for the affected program, and retain the finite-loop regression. This branch also conflicts with main. No local GPU run.
Foniass commented 2026-12-01 06:17:02 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T06:17:02Z.


Review (head 4bad5056, diff read, not a merge-check; it conflicts with main, so not built or run):

  • Superseded: this commit is on main as 2536d2ff (cherry-picked via #3203). Em::loop_guard, IO_LOOP_BUDGET (slot 113), dispatch_loop_budget and the three tests are on main as written here; main then added the same budget to the direct DXIL translator (d9a247bd) and an off switch, XCL_DISPATCH_LOOP_BUDGET=0 (a0b82da2).
  • A point for main, not this PR (reasoned, not measured): every compute loop now has a per-entry limit by default, down to the 1024 minimum for large dispatches (a 1920x1080 pass in 8x8 groups gets 128, raised to 1024). A real loop longer than that, such as a long ray-tracing traversal, would end early with wrong output and nothing logged; a once-only log line when the limit cuts a loop would make it visible.

Fine: the per-entry counter leaves nested loops the lane's full budget, and indirect dispatches keep 65,536. Recommendation: close as superseded by 2536d2ff.

AI review: Claude Code (Claude Opus 5.5), posted by Foniass without a human check of each point.

<!-- greyfinch-sync:ivall/xcl:comment:7302696589 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7302696589). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T06:17:02Z. --- Review (head 4bad5056, diff read, not a merge-check; it conflicts with main, so not built or run): - **Superseded: this commit is on main as 2536d2ff** (cherry-picked via #3203). `Em::loop_guard`, `IO_LOOP_BUDGET` (slot 113), `dispatch_loop_budget` and the three tests are on main as written here; main then added the same budget to the direct DXIL translator (d9a247bd) and an off switch, `XCL_DISPATCH_LOOP_BUDGET=0` (a0b82da2). - A point for main, not this PR (reasoned, not measured): every compute loop now has a per-entry limit by default, down to the 1024 minimum for large dispatches (a 1920x1080 pass in 8x8 groups gets 128, raised to 1024). A real loop longer than that, such as a long ray-tracing traversal, would end early with wrong output and nothing logged; a once-only log line when the limit cuts a loop would make it visible. Fine: the per-entry counter leaves nested loops the lane's full budget, and indirect dispatches keep 65,536. Recommendation: close as superseded by 2536d2ff. AI review: Claude Code (Claude Opus 5.5), posted by Foniass without a human check of each point.
throny commented 2026-12-01 12:51:53 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-12-01T12:51:53Z.


Closing as superseded: this change is already on main (2536d2ff). PR's changed lines are identical to main 2536d2ff 'a compute loop's passes shrink with the dispatch's size' (compared line by line, no difference)

Two independent checks found this: Foniass's close list on #1607 and ours against current main. If something here is still missing on main, say so and reopen it, or ask and I will.

AI use: Claude Code (Claude Opus 5.5); the per-PR comparison was done by Claude Sonnet 5.5 sub-agents.

<!-- greyfinch-sync:ivall/xcl:comment:7311758001 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2291#issuecomment-7311758001). Originally posted by [throny](https://github.com/throny) on 2026-12-01T12:51:53Z. --- Closing as superseded: this change is already on `main` (2536d2ff). PR's changed lines are identical to main 2536d2ff 'a compute loop's passes shrink with the dispatch's size' (compared line by line, no difference) Two independent checks found this: Foniass's close list on #1607 and ours against current `main`. If something here is still missing on `main`, say so and reopen it, or ask and I will. AI use: Claude Code (Claude Opus 5.5); the per-PR comparison was done by Claude Sonnet 5.5 sub-agents.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
xcl-dev/xcl!2281
No description provided.