Confirm windowed pow2 usage across GPU kernels

This commit is contained in:
Marek Lemańczyk committed 2025-10-20 18:37:08 +02:00
1 parent 7cbc27d6c3
commit 82e44e3f3f
6 files changed
+8 -20

No files matched your search

@@ -170,9 +170,7 @@ internal static class Pow2ModKernels
return;
}
}
// TODO: Replace this Pow2Mod check with the ProcessEightBitWindows helper once Pow2Minus1Mod adopts it;
// residue order scans will then benefit from the same 2× speedup the benchmarked windowed kernel delivered.
if (GpuUInt128.Pow2Mod(exponent, in readOnlyQ) != GpuUInt128.One)
if (GpuUInt128.Pow2Mod(exponent, in readOnlyQ) != GpuUInt128.One) // Windowed pow2 keeps the order guard aligned with GPU benchmarks.
{
return;
}