[BugFix] Bind symbolic coordinate ranges in FragmentThreadIndexProbe (#3096)
The probe inverts a candidate loop layout into symbolic per-thread coordinates plus a symbolic thread variable, then checks whether any fragment physical index still contains the thread variable. Proving a strided distribution thread-free is range-dependent (e.g. `(o0*512 + t*4 + o1) // 512 -> o0` only holds for t*4 + o1 < 512), so with unbound ranges Simplify keeps the thread term and even an identity access (loop layout == fragment layout) is falsely charged as a register spill. The spill pricing then steers layout inference away from conflict-free strided shared-memory loads toward chunk-contiguous layouts whose 16-word stride bank-conflicts on every shared load, observed as a 1.23-1.29x latency regression on a production KL-divergence kernel (8.8ms vs 6.8ms at n=8192, d=262144 on H800). Bind every per-thread output coordinate to its output-shape range and the thread variable to the loop's thread range/extent so the legitimate cancellations go through. Genuine thread dependence is unaffected: range information only enables valid simplification, it cannot remove a real thread term. Regression test distilled from the affected kernel.
L
Lei Wang committed
39a1a0bbee3676ea54feb9640f34facae27e7cac
Parent: 6279e73
Committed by GitHub <noreply@github.com>
on 8/27/2026, 7:26:21 AM