Repository navigation
Conversation
…sp are the (NAN) constant printer On KosmicKrisp (Mesa 26.3.1, Apple M5) both tests read 0x7fc00000 for their NaN-pattern words. Their exports fold to one float4 constant and nir_to_msl prints every NaN component as (NAN); denormals and -0.0 print correctly and MoltenVK 1.4.2 is exact. Add a known-problems row for them, and note on the ps_nan_payload row that the RGBA32F attachment keeps payloads when the words are run-time values: only NaNs NIR folds into a constant are lost. AI-assisted: yes
|
Tested d95bf04 on Arch Linux, Python 3.14.10, CPU only: pass — docs design/table/list/repeated rows suites OK (5+2+3+2). test_docs_links 6/7: the 2 failures (dev-tools fence anchor, gpu-results missing file) exist identically at HEAD~1 and name files this docs-only diff doesn't touch — pre-existing, unrelated. No game files. AI-assisted. |
|
Tested d95bf04 on Apple M3 Pro, macOS 27.2.1 (26B131), KosmicKrisp (Mesa 26.3.1, Homebrew) and MoltenVK 1.4.2. Confirmed: with KosmicKrisp, Differs: none (M3 Pro here, M5 in the description). Not tested: the run-time-value ( Full suite with KosmicKrisp for reference: 174/241 passed, 63 skipped, 4 failed ( No game files. AI-assisted: yes (Claude Code). |
Claimed in the coordination issue as: #7599 (comment)
What and why
On KosmicKrisp,
ps_cndmask_sign_modsandps_valu16_mad_selfail, anddocs/testing.mddoesn't say why. The cause is the samenir_to_mslconstant printer as #3125 and #6623, not the translator.Measured on an Apple M5 (Mesa 26.3.1), with each test run alone through
vk_harness. All 4096 pixels give the same words:ps_cndmask_sign_modsff800001 7f800001 80000001 7f8000017fc00000 7fc00000 80000001 7fc00000ps_valu16_mad_sel00008003 db880000 ffffffff 8000000000008003 db880000 7fc00000 80000000Both shaders take only constant inputs, so NIR folds each export to a single
float4constant.MESA_KK_DEBUG=mslshows every NaN component printed as(NAN), while denormals and-0.0print correctly:float4((NAN), (NAN), float(-1.40129846432481707e-45), (NAN))float4(float(4.59e-41), float(-7.66e+16), (NAN), float(-0.0))The RGBA32F attachment itself keeps NaN payloads. When each exported word is ORed with
ud0 >> 31, which is 0 at run time but can't be folded, KosmicKrisp writes the expected words for both tests. It does the same forps_nan_payload(#3125), which returns7fc12345 ffc54321 3f800000 3f000000, the same as MoltenVK.This PR:
The fix belongs in Mesa: print a
floatNaN constant by its bits, asas_type<float>(0x...u). A translator workaround would have to stop constant folding on every pixel-shader export, so this PR doesn't change any test expectations.Tested
Docs only.
pytest tests/test_docs_*.py: 33 passed and 3 failed, the same 3 as on main (test_docs_cli_flagsx2 andtest_docs_links). The GPU measurements above are from an Apple M5 with KosmicKrisp (Mesa 26.3.1) and MoltenVK 1.4.2, no game files.Related: #7595 works around the
cs_bvhcase in the translator.AI-assisted: yes
Checklist
docs/design.md, with how it was confirmed. (No translator change.)