Merged
feat: add M-RoPE MX quantization support #10557
xubinglinAdd on Aug 25
feat: add M-RoPE MX quantization support #10557
Merged
Pull Request has been successfully merged by CANN-robot.
(Thank you for xubinglin's contribution.)atomgit-bot
Aug 25 Comments:
Aug 25 Comments:
🤖 正在生成合并请求摘要,请稍候…


Incorrect?
Aug 25 Added label: cann-cla/yes
CANN-robot
Aug 25 Comments:
Aug 25 Comments:
CANN-robot
Aug 25 Comments:
Aug 25 Comments:
Thanks for your pull-request.
The full list of commands accepted by me can be found at here.
You can get sig-info at here.
You can self-configure the PR merge rules for this repository. For more details, please refer to Here.
For more, you also can visit HICANN.
PR Approval Progress
✅ Congratulations! All modules have met the lgtm and approve requirements.
Module Approval Details
| module | lgtm status | approve status |
|---|---|---|
| */*/README.md | ✅ 冯英, 蔡雯雯, 蒋礼锐, 刘丹 (4/2) | ✅ 冯英, 蔡雯雯 (2/1) |
| */*/docs/acl*.md | ✅ 冯英, 蔡雯雯, 刘丹, 蒋礼锐 (4/2) | ✅ 蔡雯雯, 冯英 (2/1) |
| */*/op_host/*_def.cpp | ✅ 王永光, 蒋礼锐, 刘丹 (3/2) | ✅ 王永光 (1/1) |
| */*/op_host/op_api/aclnn*.h | ✅ 刘丹, 蒋礼锐, 王永光 (3/2) | ✅ 王永光 (1/1) |
| docs | ✅ 刘丹, 蒋礼锐 (2/2) | ✅ 刘丹, 蒋礼锐 (2/1) |
| posembedding | ✅ 刘丹, 蒋礼锐 (2/2) | ✅ 蒋礼锐, 刘丹 (2/1) |
| sig-ops-transformer | ✅ 刘丹, 蒋礼锐 (2/2) | ✅ 刘丹, 蒋礼锐 (2/1) |
| tests | ✅ 刘丹, 蒋礼锐 (2/2) | ✅ 刘丹, 蒋礼锐 (2/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
xubinglin, thanks for your pull request. All authors of the commits have signed the CLA. 👍


338 messages are collapsed here。 See more
caiwenwen
Sep 1 Comments:
Sep 1 Comments:
/lgtm
/approve


liudan12
Sep 1 Comments:
Sep 1 Comments:
/lgtm
/approve


Sep 1 Added label: lgtm
Sep 1 Closed associated issue
Sep 1 Merged pull request
描述
为
QkvRmsNormRopeCacheWithKScale增加 Ascend 950 上的 M-RoPE MX 场景。功能
RMSNorm -> M-RoPE -> Dynamic MX Quant,每个 D32 block 生成 FP8 E4M3FN 数据和 FLOAT8_E8M0 scale。[Nv, D]的 per-head-per-channel scale 写入 FP8 cache。接口
kQuantMode,Q/K 的 MX 量化模式取值为Mx。qScaleOptional为可选输出:[T, Nq, ceil(D/32)],必须存在。q_out, q_scale;functional 接口额外返回三个更新后的 cache。optionalOutputMode=gen_placeholder,同时包含q_scalepresent/absent 的 simplified key。约束
D=128、1 <= T <= 262144。head_nums=[Nq,Nk,Nv]满足0 < Nq <= 64、Nq=8*Nk、Nk=Nv。layout_qkv=layout_q_out="TND",qQuantMode=kQuantMode="Mx",且不传rotation。实现
V -> K -> Q串行调度。关联的Issue
测试
q_scale为 optional,optionalInputMode/optionalOutputMode均为gen_placeholder,present/absent simplified key 均存在。文档更新
类型标签