diff options
| author | DeSunShine <87091315+DeSunShine@users.noreply.github.com> | 2026-11-23 20:10:12 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-11-23 11:10:12 -0600 |
| commit | f6a00fc4d8de321b3abafa51192261b392e1d034 (patch) | |
| tree | e91fc57e4898de6bb81bb3096b5815eae58cf527 /scripts/run_gpu_tests.py | |
| parent | 6a429956372f4f34e3d2a42f4b3d72020db50c9c (diff) | |
rdna2spirv: --fma khr covers the f64 FMAs (v_div_fmas_f64) with OpFmaKHR on doubles (#6635)
Squash-merged after diff review of PR #6635
Diffstat (limited to 'scripts/run_gpu_tests.py')
| -rw-r--r-- | scripts/run_gpu_tests.py | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/scripts/run_gpu_tests.py b/scripts/run_gpu_tests.py index b766f2a78..3e4b17ffa 100644 --- a/scripts/run_gpu_tests.py +++ b/scripts/run_gpu_tests.py | |||
| @@ -1090,6 +1090,21 @@ def run_suite(a, work: str) -> int: | |||
| 1090 | ok, detail = judge_cs_dump(rc, msg, [0, 0x40040000], wave64=False, partial=False, emulated=False, | 1090 | ok, detail = judge_cs_dump(rc, msg, [0, 0x40040000], wave64=False, partial=False, emulated=False, |
| 1091 | hexwords=True) | 1091 | hexwords=True) |
| 1092 | results.append((name, ok, detail)) | 1092 | results.append((name, ok, detail)) |
| 1093 | elif name == "cs_div_fmas_f64": | ||
| 1094 | # One-rounding binary64 FMA: strict where the translator emitted OpFmaKHR on doubles (shaderFmaFloat64, | ||
| 1095 | # --fma khr); under the default GLSL Fma the split result (0) is allowed, as cs_fma_fused allows it. | ||
| 1096 | rc, msg = run_cmd([vk_compute, spv, "1", "dump"], env=cs_env) | ||
| 1097 | if rc == UNSUPPORTED: # no shaderFloat64, or (--fma khr) no shaderFmaFloat64 | ||
| 1098 | results.append((name, None, unsupported_skip(msg))) | ||
| 1099 | else: | ||
| 1100 | words = (dump_words(msg) or [])[:2] if rc == 0 else [] | ||
| 1101 | strict = "shaderFmaFloat64" in ((index.get(name) or {}).get("features") or ()) | ||
| 1102 | fused, split = [0, 0x3c300000], [0, 0] | ||
| 1103 | ok = rc == 0 and (words == fused or (not strict and words == split)) | ||
| 1104 | detail = " ".join(hex(x) for x in words) if words else msg | ||
| 1105 | if ok and words == split: | ||
| 1106 | detail += " (split: the driver rounds GLSL Fma on doubles twice; --fma khr fixes it)" | ||
| 1107 | results.append((name, ok, detail)) | ||
| 1093 | elif name == "cs_cvt_f32_sat": | 1108 | elif name == "cs_cvt_f32_sat": |
| 1094 | # #300's saturating float -> int conversions: one dispatch per input word in s4 (VKC_SGPRS). | 1109 | # #300's saturating float -> int conversions: one dispatch per input word in s4 (VKC_SGPRS). |
| 1095 | wrong, skip = [], None | 1110 | wrong, skip = [], None |