= SemanticCompute

SemanticCompute — KernelBench loop closed

A generated softmax kernel diverged (∞/∞ → NaN); the prescribed max-shift fixed it, re-verified compatible.

verification report · 2 checks · DIVERGENCE FOUND

1/2 Generated softmax kernel — naive form (before) DIVERGED ✗
ulp(2)
tolerance
3
compared
3
diverged
1.798e+308
max abs err
1.798e+308
max rel err

2 special-value divergence(s) (NaN/∞ on one side) — structural, not a rounding tail.

Showing 3 element(s) that are not bit-identical: 3 fail ulp(2), 0 differ but agree under it. Select any row to see its diagnosis and the prescribed fix.

indexreferencecandidateΔdiagnosed cause

Prescribed fixes

numeric divergence (reassociation / precision / algorithmic)

A large gap beyond rounding: pin the reduction/accumulation order to the reference, use compensated or higher-precision accumulation, and check for an algorithmic difference (naive vs stable form). Re-verify — and if the gap is legitimate approximation, state it as an explicit tolerance instead of treating the kernel as wrong.

NaN generation

Guard the step that produces NaN: mask before the divide (avoid 0/0), clamp the domain of sqrt/log, or add the masked-position guard (the FlashAttention/vLLM masked-softmax fix). Then re-verify.

2/2 Same kernel — max-shift applied (after re-verify) COMPATIBLE ✓
default (abs 1e-6 or rel 1e-5)
tolerance
3
compared
0
diverged
0
max abs err
0
max rel err

Every compared element agrees under this tolerance. Nothing to prescribe.