upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/tools/f64_diff.py
AgeCommit message (Collapse)Author
11 daysf64_diff: v_div_fixup_f64 reference follows the gfx1036 measurement ↵thesubtleties
(F64-DIFF-DIV-FIXUP-REF)
12 daysMerge remote-tracking branch 'origin/pr/8996'ItsNotRexed
12 daysrdna2spirv: an f64 literal's printed width picks the one-dword ruleevilclanker9000
A literal source is one ISA dword (bits 63:32 of the constant) only when its printed spelling fits one dword. LLVM pads nothing, so such a literal prints in at most 8 hex digits; a 16-digit spelling is the whole binary64 value. The magnitude check from the previous commit read 0x0000000012345678 as the high word 0x12345678 instead of the low one, and tools/f64_diff.py's CPU reference made the same mistake, so a generated program could agree with the translator on the wrong operand. tools/shader_ir.py records the literal's hex-digit count next to f64_literal (and now marks v_ldexp_f64's sources too); tools/rdna2spirv.py decides with it at all three literal readers, and tools/f64_diff.py's read_source mirrors the rule. Tests: tests/semantic/test_f64_literal_whole.py gains the padded-width case (0x0000000012345678 -> low word 0x12345678, high word 0) next to the 8-digit control, and tests/test_f64_diff.py checks the reference reads both spellings the same way.
12 daysf64_diff: the hw oracle's reference starts with one lane in EXECevilclanker9000
ref_program began with EXEC = 0xffffffff, but the hardware kernel runs one lane, so EXEC is 1 there. Every v_cmpx case (the program reads exec_lo back with s_mov_b32 s22, exec_lo) therefore differed in one word, --oracle hw stopped at the first such case with a false mismatch, and the shrinker reduced it to an unrelated program. ref_program takes exec_lo (default unchanged for the translator and gpu oracles) and run_one passes 1 for hw; the FakeHW test double answers as a one-lane kernel. On gfx1036 the run now gives 294 match, 0 mismatch (it stopped at the first v_cmpx before).
12 daysdocs: point f64_diff at its --help usage line (#6540)凉开水
Squash-merged after diff review of PR #6540
12 daysRepo rules after round 44: stdout guards on 13 programs, newline= on four ↵ItsNotRexed
text writes Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
12 daysFUZZ-55: Route --oracle hw through hw_oracle, fix zero-sum sign, pin the ↵iurysf
reference Review follow-up on #4536 (CHANGES_REQUESTED by Flyander; coverage note by kapitche). - --oracle hw no longer always exits 77. It opens tools/hw_oracle (same pattern as tools/fmisc_diff.py), runs each program as a one-lane wave32 raw kernel in the game's inferred MODE, honours --hw-arch, and compares the four words with the reference. 77 is returned only when the oracle is unavailable. v_rcp/v_rsq/v_sqrt_f64 are counted skips there (native results are approximations, PROC-216); the translator-only known-divergence exclusions do not apply to hardware. - add_bits: an exact zero sum now follows IEEE 754-2019 6.3. +0 + +0 stays +0 in every mode; only opposite-signed zeros and x + (-x) give -0 when rounding toward negative. Before, every exact zero was -0 in that mode. - tests: direct table tests for compare (16 conditions x 28 operand pairs), class (10 classes plus boundaries), div_fixup, frexp and add_bits (NaN, inf, zero signs in all four modes), plus fake-oracle tests for hw routing, --hw-arch, exit 77, skips and shrinking. Mutating lt to <=, add_bits NaN to 0, or dropping the signed-zero rule now fails them. - docs/shader_validation.md describes the hw contract. No AMD hardware run has been done. KNOWN_DIVERGENCES keeps div-fixup-nan-s0 (it waits for TEST-983 to reach main). AI-assisted (OpenBot team). Co-authored-by: OpenBot <335604065+openbotgit[bot]@users.noreply.github.com>
13 daysFUZZ-55: Harden binary64 differential probesiurysf
AI-assisted (OpenBot team). Explicitly count FTZ and implementation-defined GPU precision skips, execute known divergence probes, correct compare modeling, and reuse prepared GPU context when shrinking. CPU campaigns and RTX 4070 Vulkan shaderFloat64 campaigns finished with zero unexpected mismatches. Co-authored-by: OpenBot <335604065+openbotgit[bot]@users.noreply.github.com>