Recompiler: split 64-bit atomics into 32-bit ones where the host drops them #1491

Open
us3r40456 wants to merge 4 commits from upstream-pr/1501 into main
us3r40456 commented 2026-11-24 17:00:31 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by us3r40456 on 2026-11-24T17:00:31Z.


On D3DMetal, a program with a 64-bit atomic writes nothing at all (#983, #258), so a title shader with a global / buffer *_x2 atomic computes or draws nothing. This PR emits 32-bit atomics instead where they leave the same memory, on a host where a start-up probe finds 64-bit atomics dropped. Part of #258: it was proposed there, and Ahmet-Dedeler and vakaobr gave it a +1.

What is in it

  • rmw64_split (emit.rs), used when Options::split_int64_atomics is set and the old value is not returned (no GLC):
    • add_x2 / sub_x2 become the low dword's InterlockedAdd, then the high dword's with the carry (or borrow) that the low one's old value shows. Adds commute, so the end state is exact.
    • and_x2 / or_x2 / xor_x2 become one 32-bit op per dword.
    • umin_x2 / umax_x2 become the 64-bit atomic without a returned value, which D3DMetal runs.
    • With GLC every one keeps its 64-bit form: two 32-bit old values are not one 64-bit snapshot, and another lane's update between them can give a value memory never held (gut0to's review below).
    • swap, cmpswap, signed min / max, inc / dec and the float ones keep the 64-bit form.
  • runner::probe_int64_atomics: once, on the title's device, under Wine only, it runs InterlockedAdd64 and a plain store. Where neither lands, it sets the option. XCL_SPLIT_INT64_ATOMICS=1 / =0 overrides it.
  • The option is part of the translated-shader disk cache identity (pso.rs). With it off, the HLSL is unchanged.
  • The window accessors get the non-returning 64-bit min / max overloads that the split forms call.
  • Two tests:
    • split_int64_atomics_emit_32_bit_atomics: the HLSL with and without the option, with GLC (unchanged by the option), with two memory windows and with the windows in the descriptor heap (heap_windows), compiled with DXC.
    • gpu_split_int64_atomics: 64 lanes on one cell per op, covering carries, borrows, one bit per lane through and / or / xor, and the largest of 64 values.

Tested

  • MacBook Pro, Apple M5 Pro (20-core GPU), 24 GB, macOS 27.2.1, Rosetta 2. CrossOver 26.3.0.39832 with D3DMetal 3.0. MSVC debug build, cross-built with cargo-xwin 0.24.1 (Rust 1.100.0, clang-cl / lld 23.1.6). DXC 1.9.2609.

  • lib unit tests, head 26105de against base main b7aa9f3, one module group at a time; a group that hangs or crashes is rerun one test per process:

    • every one of the 743 tests on both gives the same outcome;
    • both new tests pass, and gpu_split_int64_atomics gets every value right on D3DMetal.
  • The 16 integration binaries give the same outcome on both.

  • gpu::recomp with XCL_SPLIT_INT64_ATOMICS=1, every test one per process: the same outcomes as without it. The tests whose programs also hold a cmpswap / inc / dec / float *_x2 still write nothing on D3DMetal (#983 skips them).

  • The probe at start-up (tests/e2e.rs, the test title on D3DMetal) logs recompiler: a program with a 64-bit atomic writes nothing on this GPU (probe: [ffffffff, 1, 0]) – add / sub / and / or / xor and unsigned min / max without a returned value become 32-bit atomics; …. The title gets the same 29 [PASS] as on the base.

  • After merging main 9e3831e (its heap_windows option, #680) and the GLC change: both tests pass on D3DMetal, and so does gpu::recomp::heap_window_tests.

Regression run
By @mikebuckets171 on a Mac (M5 Pro, CrossOver 26.3 / D3DMetal / Rosetta 2, release x86_64-pc-windows-gnullvm, the same retail title for 60 s each), https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7140488384. Plain main on a Mac shows no frame of this title, so these show the probe and start-up, not the split atomics in a frame: on this PR's head the probe logs probe: [ffffffff, 1, 0] and turns the split on, on main it does not run. No crash, no device removal in any of the four. Windows does not take this path (the probe runs under Wine only), and the HLSL there is unchanged.

main 9e3831e:

xcl-smoke v1
commit: 9e3831e1f570d3646e53ab753b19ec07eb8f1485
gpu: AMD Compatibility Mode
title: retail (Xbox Series X|S package, private drive)
seconds: 60
exit: 0x0
frames shown: 0 (PresentX 0)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 0 MB

PR b24436b:

xcl-smoke v1
commit: b24436b3770344f4db3bc5349b85481f96d85523
gpu: AMD Compatibility Mode
title: retail (Xbox Series X|S package, private drive)
seconds: 60
exit: 0x0
frames shown: 0 (PresentX 0)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 0 MB

The same on a stack of seven Mac PRs (476c325) and that stack with this PR's diff (7fd3a25): the same blocks, 0 frames, no crash; the probe as above.

Not tested

  • Windows. The probe does not run there (under_wine()), so the option stays off.
  • Linux / Wine with vkd3d-proton. The probe runs there; I expect it to find 64-bit atomics working and change nothing, but I have not checked.
  • A title, and a release build.

AI use

  • Claude Code, Claude Opus 5.5 wrote the change, the tests and this description, and ran the tests on this machine.
<!-- greyfinch-sync:ivall/xcl:issue:5476678127 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501). Originally posted by [us3r40456](https://github.com/us3r40456) on 2026-11-24T17:00:31Z. --- On D3DMetal, a program with a 64-bit atomic writes nothing at all (#983, #258), so a title shader with a global / buffer `*_x2` atomic computes or draws nothing. This PR emits 32-bit atomics instead where they leave the same memory, on a host where a start-up probe finds 64-bit atomics dropped. Part of #258: it was proposed there, and Ahmet-Dedeler and vakaobr gave it a +1. **What is in it** - `rmw64_split` (`emit.rs`), used when `Options::split_int64_atomics` is set and the old value is not returned (no GLC): - `add_x2` / `sub_x2` become the low dword's `InterlockedAdd`, then the high dword's with the carry (or borrow) that the low one's old value shows. Adds commute, so the end state is exact. - `and_x2` / `or_x2` / `xor_x2` become one 32-bit op per dword. - `umin_x2` / `umax_x2` become the 64-bit atomic without a returned value, which D3DMetal runs. - With GLC every one keeps its 64-bit form: two 32-bit old values are not one 64-bit snapshot, and another lane's update between them can give a value memory never held (gut0to's review below). - `swap`, `cmpswap`, signed min / max, `inc` / `dec` and the float ones keep the 64-bit form. - `runner::probe_int64_atomics`: once, on the title's device, under Wine only, it runs `InterlockedAdd64` and a plain store. Where neither lands, it sets the option. `XCL_SPLIT_INT64_ATOMICS=1` / `=0` overrides it. - The option is part of the translated-shader disk cache identity (`pso.rs`). With it off, the HLSL is unchanged. - The window accessors get the non-returning 64-bit min / max overloads that the split forms call. - Two tests: - `split_int64_atomics_emit_32_bit_atomics`: the HLSL with and without the option, with GLC (unchanged by the option), with two memory windows and with the windows in the descriptor heap (`heap_windows`), compiled with DXC. - `gpu_split_int64_atomics`: 64 lanes on one cell per op, covering carries, borrows, one bit per lane through and / or / xor, and the largest of 64 values. **Tested** - MacBook Pro, Apple M5 Pro (20-core GPU), 24 GB, macOS 27.2.1, Rosetta 2. CrossOver 26.3.0.39832 with D3DMetal 3.0. MSVC debug build, cross-built with cargo-xwin 0.24.1 (Rust 1.100.0, clang-cl / lld 23.1.6). DXC 1.9.2609. - lib unit tests, head 26105de against base `main` b7aa9f3, one module group at a time; a group that hangs or crashes is rerun one test per process: - every one of the 743 tests on both gives the same outcome; - both new tests pass, and `gpu_split_int64_atomics` gets every value right on D3DMetal. - The 16 integration binaries give the same outcome on both. - `gpu::recomp` with `XCL_SPLIT_INT64_ATOMICS=1`, every test one per process: the same outcomes as without it. The tests whose programs also hold a `cmpswap` / `inc` / `dec` / float `*_x2` still write nothing on D3DMetal (#983 skips them). - The probe at start-up (`tests/e2e.rs`, the test title on D3DMetal) logs `recompiler: a program with a 64-bit atomic writes nothing on this GPU (probe: [ffffffff, 1, 0]) – add / sub / and / or / xor and unsigned min / max without a returned value become 32-bit atomics; …`. The title gets the same 29 `[PASS]` as on the base. - After merging `main` 9e3831e (its `heap_windows` option, #680) and the GLC change: both tests pass on D3DMetal, and so does `gpu::recomp::heap_window_tests`. **Regression run** By @mikebuckets171 on a Mac (M5 Pro, CrossOver 26.3 / D3DMetal / Rosetta 2, release `x86_64-pc-windows-gnullvm`, the same retail title for 60 s each), https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7140488384. Plain `main` on a Mac shows no frame of this title, so these show the probe and start-up, not the split atomics in a frame: on this PR's head the probe logs `probe: [ffffffff, 1, 0]` and turns the split on, on `main` it does not run. No crash, no device removal in any of the four. Windows does not take this path (the probe runs under Wine only), and the HLSL there is unchanged. main `9e3831e`: ``` xcl-smoke v1 commit: 9e3831e1f570d3646e53ab753b19ec07eb8f1485 gpu: AMD Compatibility Mode title: retail (Xbox Series X|S package, private drive) seconds: 60 exit: 0x0 frames shown: 0 (PresentX 0) presents per 2 s (last 3): 0 0 0 device removals: 0 crashes: 0 peak commit: 0 MB ``` PR `b24436b`: ``` xcl-smoke v1 commit: b24436b3770344f4db3bc5349b85481f96d85523 gpu: AMD Compatibility Mode title: retail (Xbox Series X|S package, private drive) seconds: 60 exit: 0x0 frames shown: 0 (PresentX 0) presents per 2 s (last 3): 0 0 0 device removals: 0 crashes: 0 peak commit: 0 MB ``` The same on a stack of seven Mac PRs (`476c325`) and that stack with this PR's diff (`7fd3a25`): the same blocks, 0 frames, no crash; the probe as above. **Not tested** - Windows. The probe does not run there (`under_wine()`), so the option stays off. - Linux / Wine with vkd3d-proton. The probe runs there; I expect it to find 64-bit atomics working and change nothing, but I have not checked. - A title, and a release build. **AI use** - Claude Code, Claude Opus 5.5 wrote the change, the tests and this description, and ran the tests on this machine.
gut0to commented 2026-11-24 17:05:03 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by gut0to on 2026-11-24T17:05:03Z.

Review: COMMENTED


AI-assisted review; I verified the split-atomic interleaving described in the inline comment against the generated sequence.

<!-- greyfinch-sync:ivall/xcl:review:6043825098 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#pullrequestreview-6043825098). Originally posted by [gut0to](https://github.com/gut0to) on 2026-11-24T17:05:03Z. **Review:** COMMENTED --- AI-assisted review; I verified the split-atomic interleaving described in the inline comment against the generated sequence.
us3r40456 commented 2026-11-24 17:06:44 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by us3r40456 on 2026-11-24T17:01:05Z.


@mikebuckets171: this is the split-forms PR from #258. When you have the time, both pairs would help: on plain main (base b7aa9f3, head 26105de), and stacked with the Mac port pieces you used there. As you said, the first shows nothing regressed; the second is where a wrong split or the torn GLC return would show up in the frames and draws. With this PR the start-up log should have recompiler: a program with a 64-bit atomic writes nothing on this GPU on that host.

<!-- greyfinch-sync:ivall/xcl:comment:7138558582 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7138558582). Originally posted by [us3r40456](https://github.com/us3r40456) on 2026-11-24T17:01:05Z. --- @mikebuckets171: this is the split-forms PR from #258. When you have the time, both pairs would help: on plain `main` (base b7aa9f3, head 26105de), and stacked with the Mac port pieces you used there. As you said, the first shows nothing regressed; the second is where a wrong split or the torn GLC return would show up in the frames and draws. With this PR the start-up log should have `recompiler: a program with a 64-bit atomic writes nothing on this GPU` on that host.
gut0to commented 2026-11-24 17:06:50 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by gut0to on 2026-11-24T17:05:03Z.

Code review location: crates/xcl/src/gpu/recomp/emit.rs; line 5087

@@ -5064,6 +5068,33 @@ fn rmw64(op: &str, a: &str, v: &str, cmp: &str, old: &str, t: &str) -> Option<St
     Some(format!("mem.{f}({a}, {val}, {old});"))
 }
 
+/// `rmw64` as 32-bit atomics that leave the same memory (`Options::split_int64_atomics`): add /
+/// sub as the low dword's add, then the high dword's with the carry the low one's old value shows
+/// (adds commute, so the end state is exact); and / or / xor per dword; unsigned min / max as the
+/// 64-bit atomic without a returned value. With `glc`, the old value is the two dwords' old values,
+/// which another lane's update can come between. None: no such form (swap, cmpswap, signed min /
+/// max, inc / dec, float min / max, unsigned min / max with a returned value).
+fn rmw64_split(op: &str, a: &str, v: &str, old: &str, glc: bool, t: &str) -> Option<String> {
+    let halves = |f: &str, n: &str| {
+        format!(
+            "uint {t}_l = 0u, {t}_h = 0u; mem.{f}({a}, (uint){n}, {t}_l); mem.{f}({a} + 4u, (uint)({n} >> 32), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);"
+        )
+    };
+    Some(match op {
+        "add" | "sub" => {
+            let n = if op == "sub" { format!("((uint64_t)0 - {v})") } else { v.to_string() };
+            format!(
+                "uint64_t {t}_n = {n}; uint {t}_l = 0u, {t}_h = 0u; mem.InterlockedAdd({a}, (uint){t}_n, {t}_l); mem.InterlockedAdd({a} + 4u, (uint)({t}_n >> 32) + (({t}_l + (uint){t}_n < {t}_l) ? 1u : 0u), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);"

When glc requests the old value, these two 32-bit return values are not one atomic 64-bit snapshot. For example, starting at 0x00000000_FFFFFFFF, interleaving add 1 with add 0x1_00000000 can make the first operation return 0x00000001_FFFFFFFF, although that value never existed. Please disable this split path when the old result is requested (or provide a truly atomic implementation) and cover the interleaving. AI-assisted review; I verified the generated sequence and interleaving.

<!-- greyfinch-sync:ivall/xcl:review-comment:4683641563 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#discussion_r4683641563). Originally posted by [gut0to](https://github.com/gut0to) on 2026-11-24T17:05:03Z. **Code review location:** `crates/xcl/src/gpu/recomp/emit.rs`; line 5087 ~~~~diff @@ -5064,6 +5068,33 @@ fn rmw64(op: &str, a: &str, v: &str, cmp: &str, old: &str, t: &str) -> Option<St Some(format!("mem.{f}({a}, {val}, {old});")) } +/// `rmw64` as 32-bit atomics that leave the same memory (`Options::split_int64_atomics`): add / +/// sub as the low dword's add, then the high dword's with the carry the low one's old value shows +/// (adds commute, so the end state is exact); and / or / xor per dword; unsigned min / max as the +/// 64-bit atomic without a returned value. With `glc`, the old value is the two dwords' old values, +/// which another lane's update can come between. None: no such form (swap, cmpswap, signed min / +/// max, inc / dec, float min / max, unsigned min / max with a returned value). +fn rmw64_split(op: &str, a: &str, v: &str, old: &str, glc: bool, t: &str) -> Option<String> { + let halves = |f: &str, n: &str| { + format!( + "uint {t}_l = 0u, {t}_h = 0u; mem.{f}({a}, (uint){n}, {t}_l); mem.{f}({a} + 4u, (uint)({n} >> 32), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);" + ) + }; + Some(match op { + "add" | "sub" => { + let n = if op == "sub" { format!("((uint64_t)0 - {v})") } else { v.to_string() }; + format!( + "uint64_t {t}_n = {n}; uint {t}_l = 0u, {t}_h = 0u; mem.InterlockedAdd({a}, (uint){t}_n, {t}_l); mem.InterlockedAdd({a} + 4u, (uint)({t}_n >> 32) + (({t}_l + (uint){t}_n < {t}_l) ? 1u : 0u), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);" ~~~~ --- When `glc` requests the old value, these two 32-bit return values are not one atomic 64-bit snapshot. For example, starting at `0x00000000_FFFFFFFF`, interleaving `add 1` with `add 0x1_00000000` can make the first operation return `0x00000001_FFFFFFFF`, although that value never existed. Please disable this split path when the old result is requested (or provide a truly atomic implementation) and cover the interleaving. AI-assisted review; I verified the generated sequence and interleaving.
us3r40456 commented 2026-11-24 18:07:53 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by us3r40456 on 2026-11-24T17:10:36Z.

Review: COMMENTED


No description provided.

<!-- greyfinch-sync:ivall/xcl:review:6043911665 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#pullrequestreview-6043911665). Originally posted by [us3r40456](https://github.com/us3r40456) on 2026-11-24T17:10:36Z. **Review:** COMMENTED --- _No description provided._
us3r40456 commented 2026-11-24 18:09:24 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by us3r40456 on 2026-11-24T17:10:36Z.

Code review location: crates/xcl/src/gpu/recomp/emit.rs; line 5087

@@ -5064,6 +5068,33 @@ fn rmw64(op: &str, a: &str, v: &str, cmp: &str, old: &str, t: &str) -> Option<St
     Some(format!("mem.{f}({a}, {val}, {old});"))
 }
 
+/// `rmw64` as 32-bit atomics that leave the same memory (`Options::split_int64_atomics`): add /
+/// sub as the low dword's add, then the high dword's with the carry the low one's old value shows
+/// (adds commute, so the end state is exact); and / or / xor per dword; unsigned min / max as the
+/// 64-bit atomic without a returned value. With `glc`, the old value is the two dwords' old values,
+/// which another lane's update can come between. None: no such form (swap, cmpswap, signed min /
+/// max, inc / dec, float min / max, unsigned min / max with a returned value).
+fn rmw64_split(op: &str, a: &str, v: &str, old: &str, glc: bool, t: &str) -> Option<String> {
+    let halves = |f: &str, n: &str| {
+        format!(
+            "uint {t}_l = 0u, {t}_h = 0u; mem.{f}({a}, (uint){n}, {t}_l); mem.{f}({a} + 4u, (uint)({n} >> 32), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);"
+        )
+    };
+    Some(match op {
+        "add" | "sub" => {
+            let n = if op == "sub" { format!("((uint64_t)0 - {v})") } else { v.to_string() };
+            format!(
+                "uint64_t {t}_n = {n}; uint {t}_l = 0u, {t}_h = 0u; mem.InterlockedAdd({a}, (uint){t}_n, {t}_l); mem.InterlockedAdd({a} + 4u, (uint)({t}_n >> 32) + (({t}_l + (uint){t}_n < {t}_l) ? 1u : 0u), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);"

Right, thanks. 6a1fae4 drops the split for every atomic whose old value is returned: with GLC the 64-bit form stays, so no value memory never held can come back. The split is now only for add / sub / and / or / xor and unsigned min / max without a returned value, where the end state is exact. split_int64_atomics_emit_32_bit_atomics checks that with GLC the option leaves the HLSL unchanged. AI-assisted (Claude Code, Claude Opus 5.5).

<!-- greyfinch-sync:ivall/xcl:review-comment:4683714533 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#discussion_r4683714533). Originally posted by [us3r40456](https://github.com/us3r40456) on 2026-11-24T17:10:36Z. **Code review location:** `crates/xcl/src/gpu/recomp/emit.rs`; line 5087 ~~~~diff @@ -5064,6 +5068,33 @@ fn rmw64(op: &str, a: &str, v: &str, cmp: &str, old: &str, t: &str) -> Option<St Some(format!("mem.{f}({a}, {val}, {old});")) } +/// `rmw64` as 32-bit atomics that leave the same memory (`Options::split_int64_atomics`): add / +/// sub as the low dword's add, then the high dword's with the carry the low one's old value shows +/// (adds commute, so the end state is exact); and / or / xor per dword; unsigned min / max as the +/// 64-bit atomic without a returned value. With `glc`, the old value is the two dwords' old values, +/// which another lane's update can come between. None: no such form (swap, cmpswap, signed min / +/// max, inc / dec, float min / max, unsigned min / max with a returned value). +fn rmw64_split(op: &str, a: &str, v: &str, old: &str, glc: bool, t: &str) -> Option<String> { + let halves = |f: &str, n: &str| { + format!( + "uint {t}_l = 0u, {t}_h = 0u; mem.{f}({a}, (uint){n}, {t}_l); mem.{f}({a} + 4u, (uint)({n} >> 32), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);" + ) + }; + Some(match op { + "add" | "sub" => { + let n = if op == "sub" { format!("((uint64_t)0 - {v})") } else { v.to_string() }; + format!( + "uint64_t {t}_n = {n}; uint {t}_l = 0u, {t}_h = 0u; mem.InterlockedAdd({a}, (uint){t}_n, {t}_l); mem.InterlockedAdd({a} + 4u, (uint)({t}_n >> 32) + (({t}_l + (uint){t}_n < {t}_l) ? 1u : 0u), {t}_h); {old} = (uint64_t){t}_l | ((uint64_t){t}_h << 32);" ~~~~ --- Right, thanks. 6a1fae4 drops the split for every atomic whose old value is returned: with GLC the 64-bit form stays, so no value memory never held can come back. The split is now only for add / sub / and / or / xor and unsigned min / max without a returned value, where the end state is exact. `split_int64_atomics_emit_32_bit_atomics` checks that with GLC the option leaves the HLSL unchanged. AI-assisted (Claude Code, Claude Opus 5.5).
mikebuckets171 commented 2026-11-24 19:07:24 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by mikebuckets171 on 2026-11-24T18:19:44Z.


Mac xcl-smoke pairs (M5 Pro, CrossOver 26.3 / D3DMetal / Rosetta 2; release cross-build cargo build --release --locked -p xcl --target x86_64-pc-windows-gnullvm; same retail title, 60 s each). The first pair is current base 9e3831e vs this PR's head b24436b. The second is the seven-PR Mac test stack vs that stack with this PR's current diff applied.

Current main 9e3831e:

xcl-smoke v1
commit: 9e3831e1f570d3646e53ab753b19ec07eb8f1485
gpu: AMD Compatibility Mode
title: retail (Xbox Series X|S package, private drive)
seconds: 60
exit: 0x0
frames shown: 0 (PresentX 0)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 0 MB

This PR b24436b:

xcl-smoke v1
commit: b24436b3770344f4db3bc5349b85481f96d85523
gpu: AMD Compatibility Mode
title: retail (Xbox Series X|S package, private drive)
seconds: 60
exit: 0x0
frames shown: 0 (PresentX 0)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 0 MB

Seven-PR stack base 476c325 (#890 76d2ff7, #957 3c43506, #982 3a6f95a, #983 ab7ce43, #996 f242ea8, #1024 699975b, #787 46695ab):

xcl-smoke v1
commit: 476c3257d0f927483e27637b338aaeaaa5a462dd
gpu: AMD Compatibility Mode
title: retail (Xbox Series X|S package, private drive)
seconds: 60
exit: 0x0
frames shown: 0 (PresentX 0)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 0 MB

Stack plus #1501's current diff, temporary test tree 7fd3a25 (not an upstream commit):

xcl-smoke v1
commit: 7fd3a2586f6c9fd8d114ca7737e7af4ab2d1ecbc
gpu: AMD Compatibility Mode
title: retail (Xbox Series X|S package, private drive)
seconds: 60
exit: 0x0
frames shown: 0 (PresentX 0)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 0 MB

On both PR heads the startup probe logged probe: [ffffffff, 1, 0] and enabled the documented split for eligible atomics; neither baseline logged it. All four bounded runs exited cleanly, but showed 0 frames, so this verifies probe detection and startup only—not rendered atomic behavior or gameplay. peak commit: 0 MB was reported by the harness and is unavailable as a memory measurement here.

AI use: OpenCode, GPT-6 Luna ran the builds/smokes and wrote this report.

<!-- greyfinch-sync:ivall/xcl:comment:7140488384 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7140488384). Originally posted by [mikebuckets171](https://github.com/mikebuckets171) on 2026-11-24T18:19:44Z. --- **Mac `xcl-smoke` pairs** (M5 Pro, CrossOver 26.3 / D3DMetal / Rosetta 2; release cross-build `cargo build --release --locked -p xcl --target x86_64-pc-windows-gnullvm`; same retail title, 60 s each). The first pair is current base `9e3831e` vs this PR's head `b24436b`. The second is the seven-PR Mac test stack vs that stack with this PR's current diff applied. Current `main` `9e3831e`: ``` xcl-smoke v1 commit: 9e3831e1f570d3646e53ab753b19ec07eb8f1485 gpu: AMD Compatibility Mode title: retail (Xbox Series X|S package, private drive) seconds: 60 exit: 0x0 frames shown: 0 (PresentX 0) presents per 2 s (last 3): 0 0 0 device removals: 0 crashes: 0 peak commit: 0 MB ``` This PR `b24436b`: ``` xcl-smoke v1 commit: b24436b3770344f4db3bc5349b85481f96d85523 gpu: AMD Compatibility Mode title: retail (Xbox Series X|S package, private drive) seconds: 60 exit: 0x0 frames shown: 0 (PresentX 0) presents per 2 s (last 3): 0 0 0 device removals: 0 crashes: 0 peak commit: 0 MB ``` Seven-PR stack base `476c325` (#890 `76d2ff7`, #957 `3c43506`, #982 `3a6f95a`, #983 `ab7ce43`, #996 `f242ea8`, #1024 `699975b`, #787 `46695ab`): ``` xcl-smoke v1 commit: 476c3257d0f927483e27637b338aaeaaa5a462dd gpu: AMD Compatibility Mode title: retail (Xbox Series X|S package, private drive) seconds: 60 exit: 0x0 frames shown: 0 (PresentX 0) presents per 2 s (last 3): 0 0 0 device removals: 0 crashes: 0 peak commit: 0 MB ``` Stack plus #1501's current diff, temporary test tree `7fd3a25` (not an upstream commit): ``` xcl-smoke v1 commit: 7fd3a2586f6c9fd8d114ca7737e7af4ab2d1ecbc gpu: AMD Compatibility Mode title: retail (Xbox Series X|S package, private drive) seconds: 60 exit: 0x0 frames shown: 0 (PresentX 0) presents per 2 s (last 3): 0 0 0 device removals: 0 crashes: 0 peak commit: 0 MB ``` On both PR heads the startup probe logged `probe: [ffffffff, 1, 0]` and enabled the documented split for eligible atomics; neither baseline logged it. All four bounded runs exited cleanly, but showed 0 frames, so this verifies probe detection and startup only—not rendered atomic behavior or gameplay. `peak commit: 0 MB` was reported by the harness and is unavailable as a memory measurement here. **AI use:** OpenCode, GPT-6 Luna ran the builds/smokes and wrote this report.
DavidM1911 commented 2026-11-24 19:07:46 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-24T18:53:40Z.


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

  • cargo test -p xcl --lib: all passed, 0 failed, ~21 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified main.)

Thanks!

<!-- greyfinch-sync:ivall/xcl:comment:7141300926 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7141300926). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-24T18:53:40Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~21 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified `main`.) Thanks!
github-actions[bot] commented 2026-11-28 08:00:13 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by github-actions[bot] on 2026-11-28T08:00:13Z.


Nothing has happened on this PR for 3 days, so it is marked stale and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto main if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.

<!-- greyfinch-sync:ivall/xcl:comment:7236297697 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7236297697). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-28T08:00:13Z. --- Nothing has happened on this PR for 3 days, so it is marked `stale` and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto `main` if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.
Foniass commented 2026-12-01 05:56:30 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T05:56:30Z.


Triage (#1607) – head b24436b

No open or merged PR splits 64-bit buffer atomics; #983 only skips the GPU tests where 64-bit atomics write nothing.
The add/sub split with the carry from the low dword's old value gives the exact end state, and returning atomics (glc) are left alone. Two points: in runner.rs probe_int64_atomics is inserted between dispatch_on's doc comment and dispatch_on, so that doc now belongs to the probe; and umin/umax still use a 64-bit atomic (only without a return value), and the probe only tests InterlockedAdd64 with a return value, so it does not show that form works on D3DMetal.
The PR conflicts with main.
Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7302302878 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1501#issuecomment-7302302878). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T05:56:30Z. --- **Triage (#1607)** – head b24436b No open or merged PR splits 64-bit buffer atomics; #983 only skips the GPU tests where 64-bit atomics write nothing. The add/sub split with the carry from the low dword's old value gives the exact end state, and returning atomics (glc) are left alone. Two points: in runner.rs `probe_int64_atomics` is inserted between `dispatch_on`'s doc comment and `dispatch_on`, so that doc now belongs to the probe; and umin/umax still use a 64-bit atomic (only without a return value), and the probe only tests `InterlockedAdd64` with a return value, so it does not show that form works on D3DMetal. The PR conflicts with main. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/1501:upstream-pr/1501'
git switch 'upstream-pr/1501'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/1501'
git switch 'upstream-pr/1501'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/1501'
git switch 'upstream-pr/1501'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/1501'
git switch 'main'
git merge --squash 'upstream-pr/1501'
git switch 'main'
git merge --ff-only 'upstream-pr/1501'
git switch 'main'
git merge 'upstream-pr/1501'
git push origin 'main'
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!1491
No description provided.