docs/testing.md: three more KosmicKrisp failures from its (NAN) constant printing #2229

Merged
Tauwni merged 4 commits from upstream-pr/2229 into main 2026-12-01 12:45:44 +00:00
Tauwni commented 2026-11-26 08:27:35 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Tauwni on 2026-11-26T08:27:35Z.


Three fixtures fail on a Mac with KosmicKrisp and pass with MoltenVK 1.4.2 and llvmpipe on the same machine: ps_cndmask_sign_mods, ps_valu16_mad_sel and cs_fmt_all (word 293). I reported them in #1608 without a cause. This PR adds a row to the Known problems table in docs/testing.md, docs only.

The cause is the (NAN) constant printing that the cs_bvh and RGBA32F rows already describe, and it is still in Mesa main. emit_src_component in src/kosmickrisp/compiler/msl_type_inference.c writes every float-typed NaN constant as (NAN), so its payload and sign are lost. MESA_KK_DEBUG=msl on an Apple M3 (macOS 26.5.1, Mesa 26.3.1, main a73a57e13) shows where each one comes from:

Fixture What KosmicKrisp emits Read back Expected
ps_cndmask_sign_mods NIR folds the export to float4((NAN), (NAN), float(-1.40129846432481707e-45), (NAN)) 0x7fc00000 0x7fc00000 0x80000001 0x7fc00000 0xff800001 0x7f800001 0x80000001 0x7f800001
ps_valu16_mad_sel the export folds to float4(..., (NAN), float(-0.0)) channel 2 0x7fc00000 0xffffffff
cs_fmt_all as_type<uint>(float((NAN))) for the input 0x7f800001 of a 16-bit float store word 293 0x80007e00 0x80007c01

The row says the failures are expected with KosmicKrisp and that the expected words should not be weakened, as the cs_bvh row does. The translator is not changed.

AI-assisted (Claude Code). No game data.

🤖 Generated with Claude Code

Red checks: from main, not this change

The failing jobs (check, macos-python, stdlib-tests-linux, linux-gpu-tools, macos, windows) fail the same way on main d48a957bb (MEASURED on macOS for the Python tests, 1 run, with the same assertion text; GPU tests READ from this PR's CI logs). The open pull requests that fix them:

Failing on main Fixed by
test_docs_cli_flags #2536
test_make_game_preflight, test_progress_dashboard (repository URL) #2550
test_docs_repo_paths #2552 (all 14 paths; it conflicts with main, a merge is on Tauwni:fix/2552-merge-main, correction)
test_tool_stdout_encoding #2531, plus two scripts on Tauwni:fix/stdout-replace-two-new-scripts (no PR, open PR limit)
test_windows_boot_journal_seed #2514
test_docs_python_deps passes with the fixes above merged
test_build_runtime_fallback #2573 (passes with it, macOS, 1 run)
vk_bindless_dimensions (macOS) #2441
test_docs_env_vars DOC-CLWB-SETTING (fix)
test_make_game_pipelines, test_sampler_source_census, test_spirv_metal_set0_cli_errors, test_spirv_metal_set0_extra, tests/semantic/test_valu_cvt_f16_int16_mods.py, ps_exp_f32_denorm_rt (macOS) branches on Tauwni/leonida, no PR (finding)
cs_imgatomic_ext (macOS, linux-gpu-tools) #1518, closed without a comment
vk_xdxr_postbuild_readback (Windows) already passes on main: merge main

Not checked by a second agent or human yet.

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5506559361 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2229). Originally posted by [Tauwni](https://github.com/Tauwni) on 2026-11-26T08:27:35Z. --- Three fixtures fail on a Mac with KosmicKrisp and pass with MoltenVK 1.4.2 and llvmpipe on the same machine: `ps_cndmask_sign_mods`, `ps_valu16_mad_sel` and `cs_fmt_all` (word 293). I reported them in #1608 without a cause. This PR adds a row to the Known problems table in `docs/testing.md`, docs only. The cause is the `(NAN)` constant printing that the `cs_bvh` and RGBA32F rows already describe, and it is still in Mesa `main`. `emit_src_component` in `src/kosmickrisp/compiler/msl_type_inference.c` writes every `float`-typed NaN constant as `(NAN)`, so its payload and sign are lost. `MESA_KK_DEBUG=msl` on an Apple M3 (macOS 26.5.1, Mesa 26.3.1, `main` `a73a57e13`) shows where each one comes from: | Fixture | What KosmicKrisp emits | Read back | Expected | |---|---|---|---| | `ps_cndmask_sign_mods` | NIR folds the export to `float4((NAN), (NAN), float(-1.40129846432481707e-45), (NAN))` | `0x7fc00000 0x7fc00000 0x80000001 0x7fc00000` | `0xff800001 0x7f800001 0x80000001 0x7f800001` | | `ps_valu16_mad_sel` | the export folds to `float4(..., (NAN), float(-0.0))` | channel 2 `0x7fc00000` | `0xffffffff` | | `cs_fmt_all` | `as_type<uint>(float((NAN)))` for the input `0x7f800001` of a 16-bit float store | word 293 `0x80007e00` | `0x80007c01` | The row says the failures are expected with KosmicKrisp and that the expected words should not be weakened, as the `cs_bvh` row does. The translator is not changed. AI-assisted (Claude Code). No game data. 🤖 Generated with [Claude Code](https://claude.com/claude-code) ### Red checks: from `main`, not this change The failing jobs (`check`, `macos-python`, `stdlib-tests-linux`, `linux-gpu-tools`, `macos`, `windows`) fail the same way on `main` `d48a957bb` (MEASURED on macOS for the Python tests, 1 run, with the same assertion text; GPU tests READ from this PR's CI logs). The open pull requests that fix them: | Failing on `main` | Fixed by | |---|---| | `test_docs_cli_flags` | #2536 | | `test_make_game_preflight`, `test_progress_dashboard` (repository URL) | #2550 | | `test_docs_repo_paths` | #2552 (all 14 paths; it conflicts with `main`, a merge is on `Tauwni:fix/2552-merge-main`, [correction](https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7239890652)) | | `test_tool_stdout_encoding` | #2531, plus two scripts on `Tauwni:fix/stdout-replace-two-new-scripts` (no PR, open PR limit) | | `test_windows_boot_journal_seed` | #2514 | | `test_docs_python_deps` | passes with the fixes above merged | | `test_build_runtime_fallback` | #2573 (passes with it, macOS, 1 run) | | `vk_bindless_dimensions` (macOS) | #2441 | | `test_docs_env_vars` | DOC-CLWB-SETTING ([fix](https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7238921436)) | | `test_make_game_pipelines`, `test_sampler_source_census`, `test_spirv_metal_set0_cli_errors`, `test_spirv_metal_set0_extra`, `tests/semantic/test_valu_cvt_f16_int16_mods.py`, `ps_exp_f32_denorm_rt` (macOS) | branches on `Tauwni/leonida`, no PR ([finding](https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7239812627)) | | `cs_imgatomic_ext` (macOS, linux-gpu-tools) | #1518, closed without a comment | | `vk_xdxr_postbuild_readback` (Windows) | already passes on `main`: merge `main` | Not checked by a second agent or human yet.
aslan2142 commented 2026-12-01 11:00:35 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by aslan2142 on 2026-12-01T11:00:35Z.

Review: COMMENTED


Reviewed the diff against current main: adding the cs_fmt_all KosmicKrisp (NAN) constant-printing row to docs/testing.md's Known problems table is clear, well-measured, clean-room compliant, merges cleanly, and change-scope / no-game-data are green.

Ready to merge as soon as this draft is marked ready for review.

(AI-assisted review.)

<!-- greyfinch-sync:ubiquitarianism/leonida:review:6129920225 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2229#pullrequestreview-6129920225). Originally posted by [aslan2142](https://github.com/aslan2142) on 2026-12-01T11:00:35Z. **Review:** COMMENTED --- Reviewed the diff against current `main`: adding the `cs_fmt_all` KosmicKrisp `(NAN)` constant-printing row to `docs/testing.md`'s Known problems table is clear, well-measured, clean-room compliant, merges cleanly, and `change-scope` / `no-game-data` are green. Ready to merge as soon as this draft is marked ready for review. *(AI-assisted review.)*
aslan2142 commented 2026-12-01 12:26:24 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by aslan2142 on 2026-12-01T12:26:24Z.


Marking Ready for Review since no WIP/blocker reason for draft status is specified on this PR, so it can enter normal CI and review.

(AI-assisted triage.)

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7311133376 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2229#issuecomment-7311133376). Originally posted by [aslan2142](https://github.com/aslan2142) on 2026-12-01T12:26:24Z. --- Marking Ready for Review since no WIP/blocker reason for draft status is specified on this PR, so it can enter normal CI and review. *(AI-assisted triage.)*
aslan2142 commented 2026-12-01 12:45:03 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by aslan2142 on 2026-12-01T12:45:03Z.

Review: APPROVED


Now ready for review, MERGEABLE/CLEAN, and all checks are green. Clean-room verified docs/testing.md row documenting the KosmicKrisp cs_fmt_all (NAN) constant-printing failure on Mesa 26.3.1. Approving and merging.

(AI-assisted review.)

<!-- greyfinch-sync:ubiquitarianism/leonida:review:6131491004 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2229#pullrequestreview-6131491004). Originally posted by [aslan2142](https://github.com/aslan2142) on 2026-12-01T12:45:03Z. **Review:** APPROVED --- Now ready for review, `MERGEABLE`/`CLEAN`, and all checks are green. Clean-room verified `docs/testing.md` row documenting the KosmicKrisp `cs_fmt_all` `(NAN)` constant-printing failure on Mesa 26.3.1. Approving and merging. *(AI-assisted review.)*
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
ProjectLeonida/mandy!2229
No description provided.