Report a named skip when the SDK validator refuses module-only validation #113

Merged
bosseurdinternet merged 4 commits from upstream-pr/114 into main 2026-11-21 17:22:59 +00:00
bosseurdinternet commented 2026-11-21 16:24:47 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by bosseurdinternet on 2026-11-21T16:24:47Z.


Change

Fixes #98. On a clean build with the DXC 1.7.2308 shipped in the original Windows SDK 10.0.26100, shader_metadata_probe fails: that dxil.dll returns E_INVALIDARG from IDxcValidator::Validate for DxcValidatorFlags_ModuleOnly, and validate_shader raises before the remaining checks.

  • validate_shader takes optional_modes. A refused optional mode keeps its call_hr record without a status. Required modes still raise, so probe_roots.py --controls behaves as before.
  • The test still runs the root signature, container and disassembly checks on both control shaders. It exits with CTest skip code 77 only when both module calls return 0x80070057 and the dxil.dll next to the configured dxc has a 101.x file version. Any other refusal, a mixed result or a refusal from a 1.x validator fails.
  • CMake passes ${DXC_BIN_DIR}/dxil.dll, the file root_probe loads, and sets SKIP_RETURN_CODE 77.
  • README first build: one sentence on the skip and on configuring a newer DXC. docs/experiments.md: the per-release results.

Verification

Bisection. root_probe's two validator calls (DxcUtils::CreateBlobFromPinned, then Validate with default flags on the container and ModuleOnly on the bare bitcode) were repeated through ctypes with the dxcompiler.dll and dxil.dll of each official x64 release. Inputs: compute_root, compute_tables and triangle_vs built from the repository HLSL by DXC 1.7.2308. Run under Wine 11.0 on Linux. Every release accepted the three containers.

DXC release dxil.dll file version IDxcVersionInfo Module-only call
1.7.2308 101.7.2308.12 1.7 0x80070057, no status
1.8.2403 / 2405 / 2407 101.8.2403.18 / 101.8.2405.17 / 101.8.2407.12 1.8 0x80070057, no status
1.8.2502 1.8.2502.8 1.8 status 0
1.8.2505, 1.8.2505.1, 1.9.2602, 1.9.2602.24, 1.9.2607, 1.9.2609 1.x 1.9 status 0

The boundary falls between 1.8.2407 and 1.8.2502, where the dxil.dll file version changes from 101.x to 1.x. IDxcVersionInfo reports 1.8 on both sides, so the test gates on the file version. The 1.7.2308 and 1.9.2609 outcomes match the native Windows 10 results in #98.

End to end. The real tests/shader_probe_check.py ran under Windows Python 3.12 in Wine. A stand-in for root_probe.exe called the real DLLs for --container, --module and --disassemble. The root signature mode was scripted, and that path is unchanged.

Validator main This branch
1.7.2308 ValueError: Validator operation unavailable for module: {'call_hr': '0x80070057'} exit 77: Module-only validation skipped: dxil.dll 101.7.2308.12 returned 0x80070057. Configure with DXC 1.8.2502 or newer to run it.
1.8.2407 not run exit 77
1.8.2502 not run exit 0
1.9.2609 exit 0 exit 0

Negative controls used a scripted probe on Linux. Each of these fails: a refusal with a 1.8.2502 or 1.9.2609 dxil.dll, another call_hr, one module refused and the other accepted (in either order), a failing module status and a failing container status.

The Linux CI Python checks pass, and pyflakes is clean on both changed Python files. I have not built this with MSVC. No C++ changed. The Windows job covers the CMake change and the passing path with the runner's DXC.

Evidence and follow-up

No new fixtures. The release table comes from the official DXC GitHub releases. A native Windows run of the skip path with the SDK's DXC 1.7.2308 is still welcome. The reporter's configuration in #98 is the reference.

AI-assisted (Claude Code). The bisection and the end-to-end runs used Wine on Linux; see Verification.

🤖 Generated with Claude Code

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6531389143 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/114). Originally posted by [bosseurdinternet](https://github.com/bosseurdinternet) on 2026-11-21T16:24:47Z. --- ## Change Fixes #98. On a clean build with the DXC 1.7.2308 shipped in the original Windows SDK 10.0.26100, `shader_metadata_probe` fails: that `dxil.dll` returns `E_INVALIDARG` from `IDxcValidator::Validate` for `DxcValidatorFlags_ModuleOnly`, and `validate_shader` raises before the remaining checks. - `validate_shader` takes `optional_modes`. A refused optional mode keeps its `call_hr` record without a status. Required modes still raise, so `probe_roots.py --controls` behaves as before. - The test still runs the root signature, container and disassembly checks on both control shaders. It exits with CTest skip code 77 only when both module calls return `0x80070057` and the `dxil.dll` next to the configured `dxc` has a 101.x file version. Any other refusal, a mixed result or a refusal from a 1.x validator fails. - CMake passes `${DXC_BIN_DIR}/dxil.dll`, the file `root_probe` loads, and sets `SKIP_RETURN_CODE 77`. - README first build: one sentence on the skip and on configuring a newer DXC. `docs/experiments.md`: the per-release results. ## Verification **Bisection.** `root_probe`'s two validator calls (`DxcUtils::CreateBlobFromPinned`, then `Validate` with default flags on the container and `ModuleOnly` on the bare bitcode) were repeated through ctypes with the `dxcompiler.dll` and `dxil.dll` of each official x64 release. Inputs: `compute_root`, `compute_tables` and `triangle_vs` built from the repository HLSL by DXC 1.7.2308. Run under Wine 11.0 on Linux. Every release accepted the three containers. | DXC release | `dxil.dll` file version | `IDxcVersionInfo` | Module-only call | |---|---|---|---| | 1.7.2308 | 101.7.2308.12 | 1.7 | `0x80070057`, no status | | 1.8.2403 / 2405 / 2407 | 101.8.2403.18 / 101.8.2405.17 / 101.8.2407.12 | 1.8 | `0x80070057`, no status | | 1.8.2502 | 1.8.2502.8 | 1.8 | status 0 | | 1.8.2505, 1.8.2505.1, 1.9.2602, 1.9.2602.24, 1.9.2607, 1.9.2609 | 1.x | 1.9 | status 0 | The boundary falls between 1.8.2407 and 1.8.2502, where the `dxil.dll` file version changes from 101.x to 1.x. `IDxcVersionInfo` reports 1.8 on both sides, so the test gates on the file version. The 1.7.2308 and 1.9.2609 outcomes match the native Windows 10 results in #98. **End to end.** The real `tests/shader_probe_check.py` ran under Windows Python 3.12 in Wine. A stand-in for `root_probe.exe` called the real DLLs for `--container`, `--module` and `--disassemble`. The root signature mode was scripted, and that path is unchanged. | Validator | `main` | This branch | |---|---|---| | 1.7.2308 | `ValueError: Validator operation unavailable for module: {'call_hr': '0x80070057'}` | exit 77: `Module-only validation skipped: dxil.dll 101.7.2308.12 returned 0x80070057. Configure with DXC 1.8.2502 or newer to run it.` | | 1.8.2407 | not run | exit 77 | | 1.8.2502 | not run | exit 0 | | 1.9.2609 | exit 0 | exit 0 | **Negative controls** used a scripted probe on Linux. Each of these fails: a refusal with a 1.8.2502 or 1.9.2609 `dxil.dll`, another `call_hr`, one module refused and the other accepted (in either order), a failing module status and a failing container status. The Linux CI Python checks pass, and pyflakes is clean on both changed Python files. I have not built this with MSVC. No C++ changed. The Windows job covers the CMake change and the passing path with the runner's DXC. ## Evidence and follow-up No new fixtures. The release table comes from the official DXC GitHub releases. A native Windows run of the skip path with the SDK's DXC 1.7.2308 is still welcome. The reporter's configuration in #98 is the reference. _AI-assisted (Claude Code). The bisection and the end-to-end runs used Wine on Linux; see Verification._ 🤖 Generated with [Claude Code](https://claude.com/claude-code)
upstream-sync closed this pull request 2026-11-24 06:41:22 +00:00
R0Y00 commented 2026-11-24 06:47:37 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-21T16:31:13Z.


Thanks for the version comparison. Please reconcile your README text with #110 once it lands, including the intermediate versions you have now tested. Please keep the newer-validator failure and mixed-result controls visible in the test results.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065707159 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/114#issuecomment-7065707159). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-21T16:31:13Z. --- Thanks for the version comparison. Please reconcile your README text with #110 once it lands, including the intermediate versions you have now tested. Please keep the newer-validator failure and mixed-result controls visible in the test results.
bosseurdinternet commented 2026-11-24 06:47:37 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by bosseurdinternet on 2026-11-21T16:37:13Z.


Thanks for the review. Both points are addressed, and the branch is rebased on 63fc71c.

README. The paragraph from #110 is kept and updated in place. It now says that 1.7.2308 and 1.8.2403 through 1.8.2407 refuse module-only validation and that the test then reports a skip, that 1.8.2502 is the first release that passes, and that the later 1.8 and 1.9 releases through 1.9.2609 pass. The -DDXC_EXECUTABLE command and the #98 link from #110 are unchanged. The per-release table is in docs/experiments.md.

Controls. The skip rule is now a function, module_outcome, and its controls run as a separate CTest entry, shader_metadata_controls, and in the Linux Python job. Each case prints one line:

control validated_by_newer_validator: validated
control refused_by_101_validator: refused
control newer_validator_refusal: rejected
control first_accepting_release_refusal: rejected
control refused_then_validated: rejected
control validated_then_refused: rejected
control other_call_failure: rejected
control failed_module_status: rejected
control single_record: rejected

shader_metadata_probe also prints what it measured, for example validator=dxil.dll file_version=1.9.2609.5 module_only=validated.

Two manual mutants, not in CI: without the 101.x condition the controls fail at newer_validator_refusal, and with "any shader refused" instead of "both refused" they fail at refused_then_validated.

Rerun under Wine 11.0 with the real DLLs and a stand-in for root_probe.exe (root signature mode scripted): 1.7.2308 and 1.8.2407 exit 77 with module_only=refused, 1.8.2502 and 1.9.2609 exit 0 with module_only=validated. A native Windows run of the skip path is still open.

AI-assisted (Claude Code).

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065781585 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/114#issuecomment-7065781585). Originally posted by [bosseurdinternet](https://github.com/bosseurdinternet) on 2026-11-21T16:37:13Z. --- Thanks for the review. Both points are addressed, and the branch is rebased on `63fc71c`. **README.** The paragraph from #110 is kept and updated in place. It now says that 1.7.2308 and 1.8.2403 through 1.8.2407 refuse module-only validation and that the test then reports a skip, that 1.8.2502 is the first release that passes, and that the later 1.8 and 1.9 releases through 1.9.2609 pass. The `-DDXC_EXECUTABLE` command and the #98 link from #110 are unchanged. The per-release table is in `docs/experiments.md`. **Controls.** The skip rule is now a function, `module_outcome`, and its controls run as a separate CTest entry, `shader_metadata_controls`, and in the Linux Python job. Each case prints one line: ```text control validated_by_newer_validator: validated control refused_by_101_validator: refused control newer_validator_refusal: rejected control first_accepting_release_refusal: rejected control refused_then_validated: rejected control validated_then_refused: rejected control other_call_failure: rejected control failed_module_status: rejected control single_record: rejected ``` `shader_metadata_probe` also prints what it measured, for example `validator=dxil.dll file_version=1.9.2609.5 module_only=validated`. Two manual mutants, not in CI: without the 101.x condition the controls fail at `newer_validator_refusal`, and with "any shader refused" instead of "both refused" they fail at `refused_then_validated`. Rerun under Wine 11.0 with the real DLLs and a stand-in for `root_probe.exe` (root signature mode scripted): 1.7.2308 and 1.8.2407 exit 77 with `module_only=refused`, 1.8.2502 and 1.9.2609 exit 0 with `module_only=validated`. A native Windows run of the skip path is still open. _AI-assisted (Claude Code)._
rasptum commented 2026-11-24 06:47:37 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by rasptum on 2026-11-21T16:40:38Z.


Native Windows run on the #98 reference machine: Windows 10 22H2 (19045.6466), VS Build Tools 17.14, MSVC 14.44.35207, original Windows SDK 10.0.26100 with DXC 1.7.2308.16 (dxil.dll 101.7.2308.24).

#114 at 079e069 with the SDK's DXC (clean worktree, README first build, full suite):

73/76 Test #73: shader_metadata_probe ............***Skipped   0.26 sec
Module-only validation skipped: dxil.dll 101.7.2308.24 returned 0x80070057. Configure with DXC 1.8.2502 or newer to run it.

The SDK's dxil.dll is build .24, not the .12 from the release zip in your table. It is still 101.x, so the gate covers it. The only other failures were the seven bvh_*_warp tests, because this branch predates #99 (ed242e5 is not an ancestor of 079e069). On current main those skip.

Native boundary check. One root_probe build per DXC release, each run through tests/shader_probe_check.py on the same .cso files from the SDK-DXC build:

DXC dxil.dll Result
SDK 1.7.2308 101.7.2308.24 call_hr 0x80070057
1.8.2407 101.8.2407.12 call_hr 0x80070057
1.8.2502 1.8.2502.8 pass
1.9.2609 1.9.2609.5 pass

This matches your Wine bisection and @Leyukaka's reading of the source: the first passing release is 1.8.2502.

#110 instructions. On the #110 head, the full suite had only shader_metadata_probe failing. Reconfiguring the existing build directory as the README says (cmake --preset dev -DDXC_EXECUTABLE=<1.8.2502>/bin/x64/dxc.exe), then building, gave 76 of 76 passed or skipped, with shader_metadata_probe passing. With this result the README's "Versions in between have not been tested" could name 1.8.2502 as the minimum.

AI-assisted (Claude Code); all runs above on the configuration listed.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065824339 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/114#issuecomment-7065824339). Originally posted by [rasptum](https://github.com/rasptum) on 2026-11-21T16:40:38Z. --- Native Windows run on the #98 reference machine: Windows 10 22H2 (19045.6466), VS Build Tools 17.14, MSVC 14.44.35207, original Windows SDK 10.0.26100 with DXC 1.7.2308.16 (`dxil.dll` 101.7.2308.24). **#114 at `079e069` with the SDK's DXC** (clean worktree, README first build, full suite): ```text 73/76 Test #73: shader_metadata_probe ............***Skipped 0.26 sec Module-only validation skipped: dxil.dll 101.7.2308.24 returned 0x80070057. Configure with DXC 1.8.2502 or newer to run it. ``` The SDK's `dxil.dll` is build `.24`, not the `.12` from the release zip in your table. It is still 101.x, so the gate covers it. The only other failures were the seven `bvh_*_warp` tests, because this branch predates #99 (`ed242e5` is not an ancestor of `079e069`). On current main those skip. **Native boundary check.** One `root_probe` build per DXC release, each run through `tests/shader_probe_check.py` on the same `.cso` files from the SDK-DXC build: | DXC | `dxil.dll` | Result | |---|---|---| | SDK 1.7.2308 | 101.7.2308.24 | `call_hr 0x80070057` | | 1.8.2407 | 101.8.2407.12 | `call_hr 0x80070057` | | 1.8.2502 | 1.8.2502.8 | pass | | 1.9.2609 | 1.9.2609.5 | pass | This matches your Wine bisection and @Leyukaka's reading of the source: the first passing release is 1.8.2502. **#110 instructions.** On the #110 head, the full suite had only `shader_metadata_probe` failing. Reconfiguring the existing build directory as the README says (`cmake --preset dev -DDXC_EXECUTABLE=<1.8.2502>/bin/x64/dxc.exe`), then building, gave 76 of 76 passed or skipped, with `shader_metadata_probe` passing. With this result the README's "Versions in between have not been tested" could name 1.8.2502 as the minimum. _AI-assisted (Claude Code); all runs above on the configuration listed._
rasptum commented 2026-11-24 06:47:38 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by rasptum on 2026-11-21T16:42:25Z.


Retested at the new head 9c9523f on the same machine (SDK DXC 1.7.2308, dxil.dll 101.7.2308.24), clean build and full suite: 77 of 77 passed or skipped, 0 failed.

  • shader_metadata_probe: skipped, Module-only validation skipped: the validator returned 0x80070057. Configure with DXC 1.8.2502 or newer to run it.
  • shader_metadata_controls: passed.
  • The seven bvh_*_warp tests now skip at their shader-model cap, since the branch includes #99.

AI-assisted (Claude Code).

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7065849132 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/114#issuecomment-7065849132). Originally posted by [rasptum](https://github.com/rasptum) on 2026-11-21T16:42:25Z. --- Retested at the new head `9c9523f` on the same machine (SDK DXC 1.7.2308, `dxil.dll` 101.7.2308.24), clean build and full suite: **77 of 77 passed or skipped, 0 failed.** - `shader_metadata_probe`: skipped, `Module-only validation skipped: the validator returned 0x80070057. Configure with DXC 1.8.2502 or newer to run it.` - `shader_metadata_controls`: passed. - The seven `bvh_*_warp` tests now skip at their shader-model cap, since the branch includes #99. _AI-assisted (Claude Code)._
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
R0Y00/Xbox2Windows!113
No description provided.