[PR #468] [CLOSED] [DeepGEMM] retire actlize v0.5.0 and use v1.0.0 only #471

Closed
opened 2026-10-26 21:18:15 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/deepseek-ai/DeepGEMM/pull/468
Author: @chenchu-zs
Created: 10/12/2026
Status: ❌ Closed

Base: main ← Head: feature/chenchu.zs-dev


📝 Commits (10+)

  • a741d37 Deepgemm for PPU
  • 203be8f [DeepGemm]: fix mqa_logits kv stride
  • 728e997 [DeepGemm]: Optimize fp4 TP GEMM2 performance
  • 1900ec2 [mqa_logits]: fix nan in int8 with bf16 output
  • 116bfad [fused moe]: compile-time topk for moe_align, 7-item fused config
  • f9255c3 Fix einsum compilation error
  • 7130433 [FP4] Fine-tune dynamic tile logic to optimize Qwen3.8 gemm1/gemm2 EP performance
  • 4e519b5 docs: add PPU overview to README
  • cb4e42f [mqa_logits]: multiple updates and refactorings
  • 6bdbd2f feat(densegemm): adaptive tile select for bf16/int8, split dense gemm from moe gemm

📊 Changes

236 files changed (+141499 additions, -3158 deletions)

View changed files

➕ .github/workflows/ci-deepgemm.yml (+49 -0)
➕ .github/workflows/deepgemm-ut-test-ppu.yml (+156 -0)
➕ .github/workflows/scripts/casecmd_810e.list (+14 -0)
➕ .github/workflows/scripts/casecmd_890p.list (+16 -0)
➕ .github/workflows/scripts/display-test-summary.py (+180 -0)
➕ .github/workflows/scripts/generate-env-info.py (+66 -0)
➕ .github/workflows/scripts/pr-deepgemm-ut.py (+212 -0)
📝 .gitignore (+11 -2)
📝 .gitmodules (+8 -3)
➕ CHANGELOG.md (+44 -0)
➖ CMakeLists.txt (+0 -44)
📝 LICENSE (+20 -0)
📝 README.md (+147 -98)
➕ csrc/apis/attention.hpp (+641 -0)
➕ csrc/apis/einsum.hpp (+175 -0)
➕ csrc/apis/gemm.hpp (+1727 -0)
➕ csrc/apis/hyperconnection.hpp (+64 -0)
➕ csrc/apis/layout.hpp (+69 -0)
➕ csrc/apis/runtime.hpp (+71 -0)
➕ csrc/indexing/main.cu (+9 -0)

...and 80 more files

📄 Description

Summary

This PR removes the legacy actlize_v0.5.0 implementation and makes
actlize_v1.0.0 the only PPU implementation in DeepGEMM-for-sail.

It removes approximately 2,900 lines of legacy code and configuration while
preserving the existing v1.0.0 behavior on PPU1.0 and PPU1.5.

Motivation

All migration-scope actlize_v1.0.0 paths have passed correctness and
performance qualification on ZW810E:

  • BF16 Dense and Grouped GEMM
  • INT8 Dense and Grouped GEMM
  • INT8 Einsum / BatchGemm

Maintaining v0.5.0 requires duplicated kernels, compiler include routing,
packaging logic, and an environment-variable selector.

The old implementation also cannot support functionality such as the plain
[B, M, N] Einsum output layout.

Changes

Remove actlize v0.5.0

  • Remove the third-party/actlize_v0.5.0 submodule.
  • Remove its setup, package-data, symlink, and include-path configuration.
  • Remove the legacy BF16 and INT8 implementation headers and runtimes.
  • Remove the obsolete predicated-tile iterator parameter helper.

Remove version selection

  • Remove DG_USE_ACTLIZE_V100 and use_actlize_v100.
  • Remove ActlizeLib and per-kernel actlize include selection.
  • Make the Python and C++ JIT compilers use actlize_v1.0.0 by default.

Preserve device-specific v1.0.0 routing

  • PPU1.0 uses the general v1.0.0 BF16 and INT8 runtime.
  • PPU1.5 keeps the specialized Dense v1.0.0 runtime.
  • Grouped GEMM and Einsum use v1.0.0 directly.
  • Standalone GEMV, FP8, DynamicTile, and other independent paths are
    preserved.

Preserve recent main-branch behavior

The branch was rebased onto main@356e9a7 and preserves:

  • the latest stream handling
  • INT8 Einsum bhr,hdr->hbd output-layout support
  • recent MQA and paged-MQA changes

Behavior change

DG_USE_ACTLIZE_V100 is no longer supported or required.

actlize_v1.0.0 is now selected unconditionally. There is no v0.5.0
fallback.

No public Python API is changed.

Validation

Static checks

Confirmed that tracked source files no longer reference:

  • actlize_v0.5.0
  • DG_USE_ACTLIZE_V100
  • use_actlize_v100
  • ActlizeLib
  • the removed BF16 and INT8 legacy runtimes

Additional checks:

  • Python source compilation passed.
  • Grouped JIT format unit test passed.
  • Patch formatting checks passed.

ZW810E correctness

Validated from commit bd07b6b after rebuilding, with
DG_USE_ACTLIZE_V100 unset:

Workload Result
BF16 Dense + Grouped 136/136
INT8 Dense + Grouped 386/386
INT8 Einsum 10/10

No test reported an execution error, traceback, assertion failure, numerical
mismatch, segmentation fault, or invalid test dispatch.

Performance qualification

The v1.0.0 implementation was qualified against v0.5.0 before removing the
legacy implementation:

Workload Cases Median delta Worst delta
BF16 Dense + Grouped 136 -0.97% +2.92%
INT8 Dense + Grouped 376 profiled -5.19% +1.28%
INT8 Einsum bhr,hdr->bhd 5 -3.33% -1.58%

The cleanup does not change the selected v1.0.0 kernels. Performance was not
remeasured after deleting the unused v0.5.0 implementation.

Reviewer notes

Please focus on:

  1. PPU1.0 routing to the general v1.0.0 runtime.
  2. PPU1.5 routing to the specialized Dense v1.0.0 runtime.
  3. Removal of all v0.5.0 build and packaging dependencies.
  4. Preservation of the Einsum plain-output layout.
  5. Preservation of standalone GEMV, FP8, and DynamicTile paths.

Out of scope

The pending actlize epilogue R2S-copy optimization is not included in this
PR and should be reviewed separately in the actlize repository.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/deepseek-ai/DeepGEMM/pull/468 **Author:** [@chenchu-zs](https://github.com/chenchu-zs) **Created:** 10/12/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `feature/chenchu.zs-dev` --- ### 📝 Commits (10+) - [`a741d37`](https://github.com/deepseek-ai/DeepGEMM/commit/a741d37ab7cd4189425b56ffc2d020bbafd52f0e) Deepgemm for PPU - [`203be8f`](https://github.com/deepseek-ai/DeepGEMM/commit/203be8f2127ce19e28bdc4a4b37cdd54f385c60a) [DeepGemm]: fix mqa_logits kv stride - [`728e997`](https://github.com/deepseek-ai/DeepGEMM/commit/728e997c2d0daca11876baf4c64a58e3b44f2138) [DeepGemm]: Optimize fp4 TP GEMM2 performance - [`1900ec2`](https://github.com/deepseek-ai/DeepGEMM/commit/1900ec29bdb0cc1f7b7baddb76f210931b71b4a3) [mqa_logits]: fix nan in int8 with bf16 output - [`116bfad`](https://github.com/deepseek-ai/DeepGEMM/commit/116bfad622b224aa227f8e4a15714fab83c93e1b) [fused moe]: compile-time topk for moe_align, 7-item fused config - [`f9255c3`](https://github.com/deepseek-ai/DeepGEMM/commit/f9255c3e44efd809bb334b0691dbc0c6a4dc439e) Fix einsum compilation error - [`7130433`](https://github.com/deepseek-ai/DeepGEMM/commit/7130433fee76e94bd8a7ccdffbbb57b674a29715) [FP4] Fine-tune dynamic tile logic to optimize Qwen3.8 gemm1/gemm2 EP performance - [`4e519b5`](https://github.com/deepseek-ai/DeepGEMM/commit/4e519b541b30feff160aed68baccd25e26165afa) docs: add PPU overview to README - [`cb4e42f`](https://github.com/deepseek-ai/DeepGEMM/commit/cb4e42f4125be15d9ff1186aecef0f9bdd1e0523) [mqa_logits]: multiple updates and refactorings - [`6bdbd2f`](https://github.com/deepseek-ai/DeepGEMM/commit/6bdbd2fb7d3391d07f0eb05ed869eb054b7de7b9) feat(densegemm): adaptive tile select for bf16/int8, split dense gemm from moe gemm ### 📊 Changes **236 files changed** (+141499 additions, -3158 deletions) <details> <summary>View changed files</summary> ➕ `.github/workflows/ci-deepgemm.yml` (+49 -0) ➕ `.github/workflows/deepgemm-ut-test-ppu.yml` (+156 -0) ➕ `.github/workflows/scripts/casecmd_810e.list` (+14 -0) ➕ `.github/workflows/scripts/casecmd_890p.list` (+16 -0) ➕ `.github/workflows/scripts/display-test-summary.py` (+180 -0) ➕ `.github/workflows/scripts/generate-env-info.py` (+66 -0) ➕ `.github/workflows/scripts/pr-deepgemm-ut.py` (+212 -0) 📝 `.gitignore` (+11 -2) 📝 `.gitmodules` (+8 -3) ➕ `CHANGELOG.md` (+44 -0) ➖ `CMakeLists.txt` (+0 -44) 📝 `LICENSE` (+20 -0) 📝 `README.md` (+147 -98) ➕ `csrc/apis/attention.hpp` (+641 -0) ➕ `csrc/apis/einsum.hpp` (+175 -0) ➕ `csrc/apis/gemm.hpp` (+1727 -0) ➕ `csrc/apis/hyperconnection.hpp` (+64 -0) ➕ `csrc/apis/layout.hpp` (+69 -0) ➕ `csrc/apis/runtime.hpp` (+71 -0) ➕ `csrc/indexing/main.cu` (+9 -0) _...and 80 more files_ </details> ### 📄 Description ## Summary This PR removes the legacy `actlize_v0.5.0` implementation and makes `actlize_v1.0.0` the only PPU implementation in DeepGEMM-for-sail. It removes approximately 2,900 lines of legacy code and configuration while preserving the existing v1.0.0 behavior on PPU1.0 and PPU1.5. ## Motivation All migration-scope `actlize_v1.0.0` paths have passed correctness and performance qualification on ZW810E: - BF16 Dense and Grouped GEMM - INT8 Dense and Grouped GEMM - INT8 Einsum / BatchGemm Maintaining v0.5.0 requires duplicated kernels, compiler include routing, packaging logic, and an environment-variable selector. The old implementation also cannot support functionality such as the plain `[B, M, N]` Einsum output layout. ## Changes ### Remove actlize v0.5.0 - Remove the `third-party/actlize_v0.5.0` submodule. - Remove its setup, package-data, symlink, and include-path configuration. - Remove the legacy BF16 and INT8 implementation headers and runtimes. - Remove the obsolete predicated-tile iterator parameter helper. ### Remove version selection - Remove `DG_USE_ACTLIZE_V100` and `use_actlize_v100`. - Remove `ActlizeLib` and per-kernel actlize include selection. - Make the Python and C++ JIT compilers use `actlize_v1.0.0` by default. ### Preserve device-specific v1.0.0 routing - PPU1.0 uses the general v1.0.0 BF16 and INT8 runtime. - PPU1.5 keeps the specialized Dense v1.0.0 runtime. - Grouped GEMM and Einsum use v1.0.0 directly. - Standalone GEMV, FP8, DynamicTile, and other independent paths are preserved. ### Preserve recent main-branch behavior The branch was rebased onto `main@356e9a7` and preserves: - the latest stream handling - INT8 Einsum `bhr,hdr->hbd` output-layout support - recent MQA and paged-MQA changes ## Behavior change `DG_USE_ACTLIZE_V100` is no longer supported or required. `actlize_v1.0.0` is now selected unconditionally. There is no v0.5.0 fallback. No public Python API is changed. ## Validation ### Static checks Confirmed that tracked source files no longer reference: - `actlize_v0.5.0` - `DG_USE_ACTLIZE_V100` - `use_actlize_v100` - `ActlizeLib` - the removed BF16 and INT8 legacy runtimes Additional checks: - Python source compilation passed. - Grouped JIT format unit test passed. - Patch formatting checks passed. ### ZW810E correctness Validated from commit `bd07b6b` after rebuilding, with `DG_USE_ACTLIZE_V100` unset: | Workload | Result | |---|---:| | BF16 Dense + Grouped | 136/136 | | INT8 Dense + Grouped | 386/386 | | INT8 Einsum | 10/10 | No test reported an execution error, traceback, assertion failure, numerical mismatch, segmentation fault, or invalid test dispatch. ### Performance qualification The v1.0.0 implementation was qualified against v0.5.0 before removing the legacy implementation: | Workload | Cases | Median delta | Worst delta | |---|---:|---:|---:| | BF16 Dense + Grouped | 136 | -0.97% | +2.92% | | INT8 Dense + Grouped | 376 profiled | -5.19% | +1.28% | | INT8 Einsum `bhr,hdr->bhd` | 5 | -3.33% | -1.58% | The cleanup does not change the selected v1.0.0 kernels. Performance was not remeasured after deleting the unused v0.5.0 implementation. ## Reviewer notes Please focus on: 1. PPU1.0 routing to the general v1.0.0 runtime. 2. PPU1.5 routing to the specialized Dense v1.0.0 runtime. 3. Removal of all v0.5.0 build and packaging dependencies. 4. Preservation of the Einsum plain-output layout. 5. Preservation of standalone GEMV, FP8, and DynamicTile paths. ## Out of scope The pending actlize epilogue R2S-copy optimization is not included in this PR and should be reviewed separately in the actlize repository. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-26 21:18:15 +00:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
deepseek-ai/DeepGEMM#471
No description provided.