kernelx: GetThreadName/SetThreadName set the Win32 error of NT failures #1674

Merged
emirduran707 merged 1 commit from upstream-pr/1684 into main 2026-11-30 02:49:41 +00:00
emirduran707 commented 2026-11-24 19:15:06 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by emirduran707 on 2026-11-24T19:15:06Z.


SetThreadName and GetThreadName pass on the failure of SetThreadDescription / GetThreadDescription as a Win32 error through hresult_to_win32. That function only understood HRESULT_FROM_WIN32 codes (0x8007xxxx) and set ERROR_INVALID_PARAMETER for everything else. Both functions fail with HRESULT_FROM_NT of the NT status instead: on Windows 11 26300, a null handle gives 0xD0000008, i.e. STATUS_INVALID_HANDLE with the NT facility bit. So a bad handle set error 87 instead of ERROR_INVALID_HANDLE (6), and a handle without access set 87 instead of ERROR_ACCESS_DENIED.

hresult_to_win32 now maps an HRESULT_FROM_NT code back through RtlNtStatusToDosError.

What is in it

  • crates/xcl/src/hle/kernelx.rs: the NT case in hresult_to_win32, and RtlNtStatusToDosError in the existing ntdll import block. Test get_thread_name_sizing_truncation_and_errors now expects ERROR_INVALID_HANDLE for a null handle from both functions; before, it only checked that some error was set.

Tested

  • AMD Radeon RX 9060 XT (driver 32.0.31044.16), Ryzen 5 5600, Windows 11 Pro 26300, Rust 1.100.0; tests debug, smoke release
  • cargo test --workspace -- --test-threads=4 on bb6f91b: 858 passed, 0 failed, 42 ignored; SKIPPED: heap_window_out_of_memory_falls_back_to_the_switch_form (no heap windows)
  • the test without the change: left: 87, right: 6 (ERROR_INVALID_PARAMETER instead of ERROR_INVALID_HANDLE)

Regression run

main:

xcl-smoke v1
commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0
gpu: AMD Radeon RX 9060 XT
title: retail-title
seconds: 60
exit: 0x0
frames shown: 1321 (PresentX 1323)
presents per 2 s (last 3): 44 22 24
device removals: 0
crashes: 0
peak commit: 47832 MB

this PR:

xcl-smoke v1
commit: bb6f91b58e8d9942abe80a3ff4f88f218e447581
gpu: AMD Radeon RX 9060 XT
title: retail-title
seconds: 60
exit: 0x0
frames shown: 1248 (PresentX 1250)
presents per 2 s (last 3): 31 29 27
device removals: 0
crashes: 0
peak commit: 49691 MB

Not tested

  • What the console's own GetThreadName sets; this follows the existing function's intent of turning the HRESULT back into the Win32 error. The smoke title's run is a regression check only.
  • NVIDIA and Intel GPUs.

AI use

  • Claude Code with Claude Opus 5.5: found the problem, wrote the change, the test and this description; I reviewed the diff and ran the tests and smoke runs above.

🤖 Generated with Claude Code

<!-- greyfinch-sync:ivall/xcl:issue:5478687570 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684). Originally posted by [emirduran707](https://github.com/emirduran707) on 2026-11-24T19:15:06Z. --- `SetThreadName` and `GetThreadName` pass on the failure of `SetThreadDescription` / `GetThreadDescription` as a Win32 error through `hresult_to_win32`. That function only understood `HRESULT_FROM_WIN32` codes (0x8007xxxx) and set `ERROR_INVALID_PARAMETER` for everything else. Both functions fail with `HRESULT_FROM_NT` of the NT status instead: on Windows 11 26300, a null handle gives 0xD0000008, i.e. STATUS_INVALID_HANDLE with the NT facility bit. So a bad handle set error 87 instead of `ERROR_INVALID_HANDLE` (6), and a handle without access set 87 instead of `ERROR_ACCESS_DENIED`. `hresult_to_win32` now maps an `HRESULT_FROM_NT` code back through `RtlNtStatusToDosError`. **What is in it** - `crates/xcl/src/hle/kernelx.rs`: the NT case in `hresult_to_win32`, and `RtlNtStatusToDosError` in the existing ntdll import block. Test `get_thread_name_sizing_truncation_and_errors` now expects `ERROR_INVALID_HANDLE` for a null handle from both functions; before, it only checked that some error was set. **Tested** - AMD Radeon RX 9060 XT (driver 32.0.31044.16), Ryzen 5 5600, Windows 11 Pro 26300, Rust 1.100.0; tests debug, smoke release - `cargo test --workspace -- --test-threads=4` on bb6f91b: 858 passed, 0 failed, 42 ignored; SKIPPED: `heap_window_out_of_memory_falls_back_to_the_switch_form` (no heap windows) - the test without the change: `left: 87`, `right: 6` (ERROR_INVALID_PARAMETER instead of ERROR_INVALID_HANDLE) **Regression run** main: ``` xcl-smoke v1 commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0 gpu: AMD Radeon RX 9060 XT title: retail-title seconds: 60 exit: 0x0 frames shown: 1321 (PresentX 1323) presents per 2 s (last 3): 44 22 24 device removals: 0 crashes: 0 peak commit: 47832 MB ``` this PR: ``` xcl-smoke v1 commit: bb6f91b58e8d9942abe80a3ff4f88f218e447581 gpu: AMD Radeon RX 9060 XT title: retail-title seconds: 60 exit: 0x0 frames shown: 1248 (PresentX 1250) presents per 2 s (last 3): 31 29 27 device removals: 0 crashes: 0 peak commit: 49691 MB ``` **Not tested** - What the console's own `GetThreadName` sets; this follows the existing function's intent of turning the HRESULT back into the Win32 error. The smoke title's run is a regression check only. - NVIDIA and Intel GPUs. **AI use** - Claude Code with Claude Opus 5.5: found the problem, wrote the change, the test and this description; I reviewed the diff and ran the tests and smoke runs above. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
MiharaxD commented 2026-11-24 22:06:49 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by MiharaxD on 2026-11-24T21:44:16Z.


Test report on an NVIDIA card, head bb6f91b (on main c160d86), which covers the "NVIDIA" line.

Tested

  • RTX 3070 Ti 8 GB (driver 621.01), Intel i5-14400F, 32 GB RAM, Windows 11 Pro 10.0.26300, Rust 1.100.0, DXC 1.9.2602.17.
  • cargo build --workspace, then cargo test --workspace --no-fail-fast -- --test-threads=4 (debug) on bb6f91b: 858 passed, 0 failed, 42 ignored (lib tests 809 / 0 / 22).
  • SKIPPED: gpu_geometry_wave32_prefix_count_over_a_mask (no wave64), gpu_wave32_program_in_wave64_hardware (no wave64).

Regression run
scripts/smoke.ps1 -Game <game folder> -Seconds 60 (release builds, start screen, no input). main is c160d86:

main:

xcl-smoke v1
commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0
gpu: NVIDIA GeForce RTX 3070 Ti
title: game
seconds: 60
exit: 0x0
frames shown: 1586 (PresentX 1586)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15055 MB

this PR's head:

xcl-smoke v1
commit: bb6f91b58e8d9942abe80a3ff4f88f218e447581
gpu: NVIDIA GeForce RTX 3070 Ti
title: game
seconds: 60
exit: 0x0
frames shown: 1595 (PresentX 1595)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15802 MB

Not tested

  • A title that reads the Win32 error of a failed GetThreadName / SetThreadName: the smoke run is a regression check only.
  • AMD / Intel, gameplay past the start screen.

AI use: Claude Code (Claude Opus 5.5) built the PR, ran the tests and both smoke runs, read the logs and wrote this report; I checked it before posting.

<!-- greyfinch-sync:ivall/xcl:comment:7145321975 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7145321975). Originally posted by [MiharaxD](https://github.com/MiharaxD) on 2026-11-24T21:44:16Z. --- Test report on an NVIDIA card, head `bb6f91b` (on `main` `c160d86`), which covers the "NVIDIA" line. **Tested** - RTX 3070 Ti 8 GB (driver 621.01), Intel i5-14400F, 32 GB RAM, Windows 11 Pro 10.0.26300, Rust 1.100.0, DXC 1.9.2602.17. - `cargo build --workspace`, then `cargo test --workspace --no-fail-fast -- --test-threads=4` (debug) on `bb6f91b`: **858 passed, 0 failed, 42 ignored** (lib tests 809 / 0 / 22). - SKIPPED: `gpu_geometry_wave32_prefix_count_over_a_mask` (no wave64), `gpu_wave32_program_in_wave64_hardware` (no wave64). **Regression run** `scripts/smoke.ps1 -Game <game folder> -Seconds 60` (release builds, start screen, no input). `main` is `c160d86`: main: ``` xcl-smoke v1 commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0 gpu: NVIDIA GeForce RTX 3070 Ti title: game seconds: 60 exit: 0x0 frames shown: 1586 (PresentX 1586) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15055 MB ``` this PR's head: ``` xcl-smoke v1 commit: bb6f91b58e8d9942abe80a3ff4f88f218e447581 gpu: NVIDIA GeForce RTX 3070 Ti title: game seconds: 60 exit: 0x0 frames shown: 1595 (PresentX 1595) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15802 MB ``` **Not tested** - A title that reads the Win32 error of a failed `GetThreadName` / `SetThreadName`: the smoke run is a regression check only. - AMD / Intel, gameplay past the start screen. **AI use:** Claude Code (Claude Opus 5.5) built the PR, ran the tests and both smoke runs, read the logs and wrote this report; I checked it before posting.
DavidM1911 commented 2026-11-24 22:06:51 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-24T21:47:33Z.


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

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

Thanks!

<!-- greyfinch-sync:ivall/xcl:comment:7145393871 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7145393871). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-24T21:47:33Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~22 ignored. (Intermittent single-test flake under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified `main`.) Thanks!
JJAutoCompare commented 2026-11-25 05:08:25 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by JJAutoCompare on 2026-11-25T04:44:27Z.


PR #1684 verification

Clean head bb6f91b58e8d9942abe80a3ff4f88f218e447581 on STOR-WINLAB. Windows 11 x64 (10.0.26200.9974), AMD Ryzen 7 3800X, Intel Arc A770 (16 GB, driver 32.0.101.9175), DXC 1.9.2609.5, and rustc 1.100.0 (0ef1bc386, x86_64-pc-windows-msvc).

Tested

  • cargo build --workspace and cargo test --workspace --no-run both exited 0 outside the Arc lock. Test compilation produced 19 test binaries. Dev and test profiles were unoptimized, with debug info and incremental compilation disabled.
  • cargo test -p xcl --lib hle::kernelx::tests::get_thread_name_sizing_truncation_and_errors -- --exact --nocapture with XCL_ADAPTER=NONE_CPU_ONLY outside the lock. 1 passed, 0 failed, 0 ignored, 0 explicit skips. The test in crates/xcl/src/hle/kernelx.rs verified that both GetThreadName and SetThreadName return FALSE and set ERROR_INVALID_HANDLE for a null thread handle. It also checked name round trips, empty names, buffer sizing, and null-buffer validation.
  • cargo test --workspace --no-fail-fast -- --test-threads=4 ran once inside Invoke-ArcTest.ps1 with XCL_ADAPTER=A770 and RUST_TEST_NOCAPTURE=1. Exit 101. The 20 result summaries in pr1684-suite.log (19 test binaries and one doc-test harness) totaled 840 passed, 18 failed, and 42 ignored. The thread-name test passed again.

Workspace failures and skips

  • 17 library GPU tests failed. 13 reported CreateComputePipelineState error 0x80070057. The other four reported output mismatches involving fused multiply-add, implicit mip LOD, f16 output, and wave64 pixel reductions. One end-to-end test failed because the test title's RSSetDepthBiasX check read a blue pixel where it expected green.
  • Six lines began with SKIPPED . The reasons were unavailable wave64 (2), tiled-resource tier below 2 (1), unavailable heap windows (1), and missing debug-layer support (2). These skips provide no coverage.

Not tested

Matched main run, retail title smoke, and other GPUs. XCL_SAMPLE_* inputs were unset. The workspace failures have no matched baseline for comparison.

AI use

T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high) ran the build and verification. Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against pr1684-suite.log and published.

<!-- greyfinch-sync:ivall/xcl:comment:7153120587 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7153120587). Originally posted by [JJAutoCompare](https://github.com/JJAutoCompare) on 2026-11-25T04:44:27Z. --- # PR #1684 verification Clean head `bb6f91b58e8d9942abe80a3ff4f88f218e447581` on STOR-WINLAB. Windows 11 x64 (10.0.26200.9974), AMD Ryzen 7 3800X, Intel Arc A770 (16 GB, driver 32.0.101.9175), DXC 1.9.2609.5, and rustc 1.100.0 (0ef1bc386, x86_64-pc-windows-msvc). **Tested** - `cargo build --workspace` and `cargo test --workspace --no-run` both exited 0 outside the Arc lock. Test compilation produced 19 test binaries. Dev and test profiles were unoptimized, with debug info and incremental compilation disabled. - `cargo test -p xcl --lib hle::kernelx::tests::get_thread_name_sizing_truncation_and_errors -- --exact --nocapture` with `XCL_ADAPTER=NONE_CPU_ONLY` outside the lock. 1 passed, 0 failed, 0 ignored, 0 explicit skips. The test in `crates/xcl/src/hle/kernelx.rs` verified that both `GetThreadName` and `SetThreadName` return FALSE and set `ERROR_INVALID_HANDLE` for a null thread handle. It also checked name round trips, empty names, buffer sizing, and null-buffer validation. - `cargo test --workspace --no-fail-fast -- --test-threads=4` ran once inside `Invoke-ArcTest.ps1` with `XCL_ADAPTER=A770` and `RUST_TEST_NOCAPTURE=1`. Exit 101. The 20 result summaries in `pr1684-suite.log` (19 test binaries and one doc-test harness) totaled 840 passed, 18 failed, and 42 ignored. The thread-name test passed again. **Workspace failures and skips** - 17 library GPU tests failed. 13 reported `CreateComputePipelineState` error `0x80070057`. The other four reported output mismatches involving fused multiply-add, implicit mip LOD, f16 output, and wave64 pixel reductions. One end-to-end test failed because the test title's `RSSetDepthBiasX` check read a blue pixel where it expected green. - Six lines began with `SKIPPED `. The reasons were unavailable wave64 (2), tiled-resource tier below 2 (1), unavailable heap windows (1), and missing debug-layer support (2). These skips provide no coverage. **Not tested** Matched `main` run, retail title smoke, and other GPUs. `XCL_SAMPLE_*` inputs were unset. The workspace failures have no matched baseline for comparison. **AI use** T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high) ran the build and verification. Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against `pr1684-suite.log` and published.
Decodere commented 2026-11-27 13:38:05 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Decodere on 2026-11-27T13:38:05Z.


Independent desktop NVIDIA verification of PR #1684 at head bb6f91b58e8d9942abe80a3ff4f88f218e447581 (1 commit; exact parent & merge-base: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0, pre-#2555 ancestor of main).

Environment

  • GPU: NVIDIA GeForce RTX 4060 (8 GB / 7956 MiB reported by D3D12, Wave32-only Ada), driver 32.0.16.2114 (NVIDIA 621.14, WDDM 3.2)
  • CPU / RAM / OS: Intel Core i5-11400F (6C / 12T), 32 GB RAM (31.9 GiB usable), Windows 11 Home 26200 (Developer Mode off)
  • Toolchain: rustc 1.100.0 (0ef1bc386 2026-11-09) MSVC, DXC 1.9.2609.5, --release

Targeted tests & build (bb6f91b5)

Command Result
cargo test --release -p xcl --lib -- --nocapture get_thread_name_sizing_truncation_and_errors (3 consecutive runs) 1 passed; 0 failed; 0 ignored; 830 filtered out × 3 (0.00s, 0.00s, 0.00s, 0 skipped)
cargo test --release -p xcl --lib -- --nocapture hle::kernelx:: (3 consecutive runs) 31 passed; 0 failed; 1 ignored; 799 filtered out × 3 (0.21s, 0.21s, 0.22s, 0 runtime skips; 1 pre-existing #[ignore] timing harness scatter_timing)
cargo build --release -p xcl Clean build (1m 25s, exit 0, 0 new warnings in kernelx.rs)

Paired quiet 60 s retail smoke (title: 29640639)

(Note: scripts/smoke.ps1 at c160d86e predates 9683e7a6 and printed the local folder basename on title:; replaced below with the standard 9683e7a6 title hash 29640639, with all measured fields verbatim.)

Exact parent & merge-base (c160d86ef2efe3a07e4dfb473e4fa72eafb413c0, cached baseline on the same machine):

xcl-smoke v1
commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0
gpu: NVIDIA GeForce RTX 4060
title: 29640639
seconds: 60
exit: 0x0
frames shown: 1533 (PresentX 1533)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14721 MB

PR #1684 (bb6f91b58e8d9942abe80a3ff4f88f218e447581):

xcl-smoke v1
commit: bb6f91b58e8d9942abe80a3ff4f88f218e447581
gpu: NVIDIA GeForce RTX 4060
title: 29640639
seconds: 60
exit: 0x0
frames shown: 1555 (PresentX 1555)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14716 MB

Limits of coverage

  • get_thread_name_sizing_truncation_and_errors and all 31 active hle::kernelx:: tests (31/31 executed, 0 runtime skips; 1 pre-existing #[ignore] scatter_timing) passed 3/3 on native Windows 11 26200, directly verifying that hresult_to_win32 maps HRESULT_FROM_NT failures from GetThreadDescription/SetThreadDescription via RtlNtStatusToDosError to ERROR_INVALID_HANDLE on null handles.
  • Other HRESULT_FROM_NT failure codes beyond invalid thread handles were not individually probed, and the 60 s retail smoke confirms overall runtime stability (0 device removals, 0 crashes, steady 60 Hz); single-run frame/commit delta vs. the cached parent reflects normal startup variance.

AI disclosure: test execution and report drafting assisted by Google Antigravity (Gemini 4 Neon).

<!-- greyfinch-sync:ivall/xcl:comment:7219741310 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7219741310). Originally posted by [Decodere](https://github.com/Decodere) on 2026-11-27T13:38:05Z. --- Independent desktop NVIDIA verification of **PR #1684** at head `bb6f91b58e8d9942abe80a3ff4f88f218e447581` (`1` commit; exact parent & merge-base: `c160d86ef2efe3a07e4dfb473e4fa72eafb413c0`, pre-`#2555` ancestor of `main`). ### Environment - **GPU:** NVIDIA GeForce RTX 4060 (8 GB / `7956 MiB` reported by D3D12, Wave32-only Ada), driver `32.0.16.2114` (NVIDIA `621.14`, WDDM 3.2) - **CPU / RAM / OS:** Intel Core i5-11400F (6C / 12T), 32 GB RAM (`31.9 GiB` usable), Windows 11 Home `26200` (Developer Mode off) - **Toolchain:** `rustc 1.100.0 (0ef1bc386 2026-11-09)` MSVC, DXC `1.9.2609.5`, `--release` ### Targeted tests & build (`bb6f91b5`) | Command | Result | | --- | --- | | `cargo test --release -p xcl --lib -- --nocapture get_thread_name_sizing_truncation_and_errors` (3 consecutive runs) | `1 passed; 0 failed; 0 ignored; 830 filtered out` × 3 (`0.00s`, `0.00s`, `0.00s`, `0` skipped) | | `cargo test --release -p xcl --lib -- --nocapture hle::kernelx::` (3 consecutive runs) | `31 passed; 0 failed; 1 ignored; 799 filtered out` × 3 (`0.21s`, `0.21s`, `0.22s`, `0` runtime skips; `1` pre-existing `#[ignore]` timing harness `scatter_timing`) | | `cargo build --release -p xcl` | Clean build (`1m 25s`, exit `0`, `0` new warnings in `kernelx.rs`) | ### Paired quiet 60 s retail smoke (`title: 29640639`) *(Note: `scripts/smoke.ps1` at `c160d86e` predates `9683e7a6` and printed the local folder basename on `title:`; replaced below with the standard `9683e7a6` title hash `29640639`, with all measured fields verbatim.)* Exact parent & merge-base (`c160d86ef2efe3a07e4dfb473e4fa72eafb413c0`, cached baseline on the same machine): ``` xcl-smoke v1 commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0 gpu: NVIDIA GeForce RTX 4060 title: 29640639 seconds: 60 exit: 0x0 frames shown: 1533 (PresentX 1533) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14721 MB ``` PR #1684 (`bb6f91b58e8d9942abe80a3ff4f88f218e447581`): ``` xcl-smoke v1 commit: bb6f91b58e8d9942abe80a3ff4f88f218e447581 gpu: NVIDIA GeForce RTX 4060 title: 29640639 seconds: 60 exit: 0x0 frames shown: 1555 (PresentX 1555) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14716 MB ``` ### Limits of coverage - `get_thread_name_sizing_truncation_and_errors` and all `31` active `hle::kernelx::` tests (`31/31` executed, `0` runtime skips; `1` pre-existing `#[ignore]` `scatter_timing`) passed `3/3` on native Windows 11 `26200`, directly verifying that `hresult_to_win32` maps `HRESULT_FROM_NT` failures from `GetThreadDescription`/`SetThreadDescription` via `RtlNtStatusToDosError` to `ERROR_INVALID_HANDLE` on null handles. - Other `HRESULT_FROM_NT` failure codes beyond invalid thread handles were not individually probed, and the 60 s retail smoke confirms overall runtime stability (`0` device removals, `0` crashes, steady 60 Hz); single-run frame/commit delta vs. the cached parent reflects normal startup variance. *AI disclosure: test execution and report drafting assisted by Google Antigravity (Gemini 4 Neon).*
throny commented 2026-11-28 14:12:36 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-11-28T14:12:36Z.


merge-check claim
head: bb6f91b58e

<!-- greyfinch-sync:ivall/xcl:comment:7240499514 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7240499514). Originally posted by [throny](https://github.com/throny) on 2026-11-28T14:12:36Z. --- merge-check claim head: bb6f91b58e8d9942abe80a3ff4f88f218e447581
throny commented 2026-11-28 14:26:28 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-11-28T14:26:28Z.


merge-check
base: b937fbab
head: bb6f91b58e
merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2140 passed, 1 failed, 48 ignored (26 SKIPPED lines). The one failure is gpu::dxil::msaa_tests::direct_msaa_loads_precede_get_dimensions, which fails on main without this PR too (reported on #3093) and in every tree of this batch; the nine failures main had since #2959 are gone at b937fbab. I did not run b937fbab alone: the last base-only run is e13d6250 (2130 passed, 10 failed, 48 ignored).
review: none. For an HRESULT that carries an NT status the helper now clears the marker bit and maps the status through RtlNtStatusToDosError, so an invalid handle comes out as ERROR_INVALID_HANDLE; the import joins the existing ntdll block, and the helper is used by SetThreadName and GetThreadName only.
performance: none (error path only).
verdict: safe to merge
hardware / tool and model: RTX 4080 16 GB (621.40), i9-12900K, Windows 11 26300, Rust 1.100.0, debug. Claude Code; merge, build and suite run by Claude Fable 5.2, diff review by Claude Opus 5.5 (every hunk read; nothing run on the GPU beyond the suite).

<!-- greyfinch-sync:ivall/xcl:comment:7240671790 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7240671790). Originally posted by [throny](https://github.com/throny) on 2026-11-28T14:26:28Z. --- merge-check base: b937fbab head: bb6f91b58e8d9942abe80a3ff4f88f218e447581 merge: clean build: cargo build --workspace -> ok tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2140 passed, 1 failed, 48 ignored (26 SKIPPED lines). The one failure is gpu::dxil::msaa_tests::direct_msaa_loads_precede_get_dimensions, which fails on main without this PR too (reported on #3093) and in every tree of this batch; the nine failures main had since #2959 are gone at b937fbab. I did not run b937fbab alone: the last base-only run is e13d6250 (2130 passed, 10 failed, 48 ignored). review: none. For an HRESULT that carries an NT status the helper now clears the marker bit and maps the status through RtlNtStatusToDosError, so an invalid handle comes out as ERROR_INVALID_HANDLE; the import joins the existing ntdll block, and the helper is used by SetThreadName and GetThreadName only. performance: none (error path only). verdict: safe to merge hardware / tool and model: RTX 4080 16 GB (621.40), i9-12900K, Windows 11 26300, Rust 1.100.0, debug. Claude Code; merge, build and suite run by Claude Fable 5.2, diff review by Claude Opus 5.5 (every hunk read; nothing run on the GPU beyond the suite).
fromthemoonx commented 2026-11-30 01:04:34 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by fromthemoonx on 2026-11-30T01:04:34Z.


merge-check
base: 53e85fb124
head: bb6f91b58e
merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2792 passed, 1 failed, 49 ignored; SKIPPED: 29 (mostly "no wave64"); failing: hle::d3d12x::standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline, which fails on the base 53e85fb alone too (#2369's test against late_release, see #2369), not this PR
review: none blocking, after reading the whole diff (kernelx.rs). HRESULT_FROM_NT sets bit 28, so clearing it gives the NTSTATUS back for RtlNtStatusToDosError (in ntdll with the other Rtl* imports). In Rust & binds tighter than !=, so the test is (hr & 0x1000_0000) != 0. An unknown status maps to ERROR_MR_MID_NOT_FOUND, still a nonzero error. get_thread_name_sizing_truncation_and_errors passes 3/3; with the new branch disabled (scratch) it fails (left: 87, ERROR_INVALID_PARAMETER instead of ERROR_INVALID_HANDLE).
performance: none (error path only).
verdict: safe to merge
hardware / tool and model: RTX 3060 12 GB (driver 610.88), Ryzen 7 5700X, Windows 11 Pro 26300, Rust 1.100.0 MSVC, debug / Claude Code (Claude Opus 5.5)

<!-- greyfinch-sync:ivall/xcl:comment:7265819822 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1684#issuecomment-7265819822). Originally posted by [fromthemoonx](https://github.com/fromthemoonx) on 2026-11-30T01:04:34Z. --- merge-check base: 53e85fb124eae624641e9884517e4f3c4a7d8794 head: bb6f91b58e8d9942abe80a3ff4f88f218e447581 merge: clean build: cargo build --workspace -> ok tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2792 passed, 1 failed, 49 ignored; SKIPPED: 29 (mostly "no wave64"); failing: `hle::d3d12x::standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline`, which fails on the base `53e85fb` alone too (#2369's test against `late_release`, see #2369), not this PR review: none blocking, after reading the whole diff (`kernelx.rs`). `HRESULT_FROM_NT` sets bit 28, so clearing it gives the NTSTATUS back for `RtlNtStatusToDosError` (in ntdll with the other `Rtl*` imports). In Rust `&` binds tighter than `!=`, so the test is `(hr & 0x1000_0000) != 0`. An unknown status maps to `ERROR_MR_MID_NOT_FOUND`, still a nonzero error. `get_thread_name_sizing_truncation_and_errors` passes 3/3; with the new branch disabled (scratch) it fails (`left: 87`, `ERROR_INVALID_PARAMETER` instead of `ERROR_INVALID_HANDLE`). performance: none (error path only). verdict: safe to merge hardware / tool and model: RTX 3060 12 GB (driver 610.88), Ryzen 7 5700X, Windows 11 Pro 26300, Rust 1.100.0 MSVC, debug / Claude Code (Claude Opus 5.5)
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!1674
No description provided.