Repository navigation
Changes since 0.3.0.
Install
pip install flashlibno longer pulls innvidia-cutlass-dslornumba. Every op has a path that runs without them. (#25, #26, #28)- The CuTe DSL backends move to an extra:
pip install 'flashlib[cutedsl]'(nvidia-cutlass-dsl>=4.4,<4.7, Linux). (#25)- Without it, auto-routed ops use their Triton or torch path.
- Explicit CuTe requests (
backend="cutedsl",*_cutedslentry points) raise anImportErrorthat names the op and the install command. A fewcutedslbackends that have a non-CuTe path (for example pca, linear_regression and random_forest) keep working. - If
nvidia-cutlass-dslis installed but cannot be used (version out of range, broken import), flashlib warns once. (#26)
- numba is gone: the HDBSCAN tree helpers are C, built on first use with the compiler Triton already uses (
CC, gcc or clang) and cached (set$FLASHLIB_CACHE_DIRto move the cache). Without a compiler they fall back to pure Python. (#28) flashlib.diagnose()shows whether the CuTe DSL backend and the HDBSCAN C helpers are available.- Supports
nvidia-cutlass-dsl4.6.
Blackwell
- k-means: a tcgen05 CuTe DSL assignment kernel for bf16 input with D in {64, 128, 256, 512, 768, 1024} (needs
[cutedsl]), and tuned Triton k-means configs for B200 (#8). Faster assignment reduction (#22). - KNN search: a tcgen05 CuTe DSL kernel that
flash_knnpicks automatically for bf16 input with D a multiple of 64 up to 512, k <= 16 and at least 4096 database rows (needs[cutedsl]) (#21). Without the CuTe DSL, small-query KNN runs on Triton (#28).
Fixes
- GEMM:
- CuTe 3xbf16 / fp16x9 returned wrong results unless
K % 8 == 0andN % 4 == 0, and a second same-shape call overwrote the previous result. (#26) - The Triton INT8 GEMM behind
gemm_ozaki2_tritonand thefp16x3_kahankernel had no bounds masks, so unaligned shapes gave wrong results or NaN.gemm(tol=1e-6)picksfp16x3_kahan. (#26, #30) gemm_tf32_x6lefttorch.backends.cuda.matmul.allow_tf32on, which turned every later fp32 matmul in the process into TF32. (#30)
- CuTe 3xbf16 / fp16x9 returned wrong results unless
- The sm_90-only CuTe kernels (3xbf16 / fp16x9 / ozaki2 GEMMs, IVF-PQ search) were also selected on GPUs newer than Hopper. They are now used on Hopper only. (#26)
LogisticRegression.fit()andTruncatedSVD.fit()always raised. (#30)backend="cutedsl"raised forflash_standard_scaler,flash_umapandflash_logistic_regression. (#26, #30)flash_standard_scalerfailed on non-contiguous input. (#30)- HDBSCAN auto dispatch uses the sparse path when the dense mutual-reachability matrix does not fit in GPU memory. (#26)
Release process
Releases are now built and published to PyPI by GitHub Actions when a v* tag is pushed. (#32)
Full Changelog: v0.3.0...v0.4.0