已合并
refactor(matmul_recipes): rename QuantMatmulTilingData to QuantMatmulMxTilingData #393
refactor(matmul_recipes): rename QuantMatmulTilingData to QuantMatmulMxTilingData #393
已合并
tangweiwei2创建于 7 天前
tangweiwei2
7 天前

描述

matmul_recipes 目录下 MX 量化矩阵乘算子使用的 QuantMatmulTilingData 重命名为 QuantMatmulMxTilingData

该 TilingData 结构体仅用于 MX 量化格式(MXFP8/MXFP4)的矩阵乘算子,原命名 QuantMatmulTilingData 过于宽泛,容易与 INT8、HiFP8 等其他量化类型的 TilingData 混淆。新命名 QuantMatmulMxTilingData 与现有文件命名 quant_matmul_mx_tiling_*.h 保持一致。

涉及 14 个文件共 28 处引用,均为纯文本替换,不涉及逻辑变更。

关联的Issue

关联Issue #264

测试

使用 CANN 9.1.0 toolkit(dav-3510 架构)编译验证通过:

  • quant_matmul_mxfp8_swat ✅
  • quant_matmul_mxfp8_swat_4_buffer ✅
  • quant_matmul_mxfp8_swat_weight_nz ✅
  • quant_matmul_mxfp8_a_full_load ✅

全仓库搜索确认 QuantMatmulTilingData 无残留。

文档更新

不涉及文档更新。

类型标签


此 PR 由 AI Agent 辅助生成。

likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 tangweiwei2 的贡献)
Ttangweiwei2
7 天前 创建了 pull request,commit 3fabb74b
Ttangweiwei2
7 天前 关联了issue:[Requirement|需求建议]: matmul_recipes 中 QuantMatmulTilingData 命名过于宽泛,建议重命名为 QuantMatmulMxTilingData
atomgit-bot
atomgit-bot
7 天前 评论:

变更摘要

该 PR 对 matmul_recipes 目录下的 MX 量化矩阵乘算子进行了纯命名重构:将用于 MX 格式(MXFP8/MXFP4)矩阵乘算子的 QuantMatmulTilingData 统一重命名为 QuantMatmulMxTilingData,以避免与 INT8、HiFP8 等其他量化类型的 TilingData 命名混淆,并与现有 quant_matmul_mx_tiling_*.h 文件命名保持一致。改动覆盖 14 个文件、28 处引用,均为文本替换,不涉及逻辑变更。

主要改动

  • 结构体定义重命名: 在 quant_matmul_tiling_data.h 中将 struct alignas(8) QuantMatmulTilingData 重命名为 struct alignas(8) QuantMatmulMxTilingData,字段布局与 host-device 契约保持不变。
  • 基类接口签名同步更新: 在 quant_matmul_tiling_base.h 中,GetTilingData 的两个重载、纯虚函数 DoOpTiling 以及私有方法 PrintTilingData 的参数类型均由 QuantMatmulTilingData 更新为 QuantMatmulMxTilingData
  • 派生 Tiling 类 override 更新: quant_matmul_mx_tiling_a_full_load.hquant_matmul_mx_tiling_swat.hquant_matmul_mx_tiling_swat_4_buffer.h 中的 DoOpTilingBuildTilingData 参数类型同步替换为 QuantMatmulMxTilingData
  • 示例算子文件更新: mxfp4 与 mxfp8 的 a_full_loadswatswat_4_bufferswat_weight_nz.asc 示例中,kernel 形参类型及 tilingData 局部变量声明均替换为 QuantMatmulMxTilingData
  • 注释同步: common_utils.hCheckUint32Shape 附近的注释由 QuantMatmulTilingData 更新为 QuantMatmulMxTilingData,与实际结构体命名保持一致。
likedislike
atomgit-bot
atomgit-bot
7 天前 评论:

代码审查

✅ 未发现问题

likedislike
CANN-robotCANN-robot成员
7 天前 添加了label:cann-cla/yes
CANN-robot
CANN-robot成员
7 天前 评论:

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
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
repo-cann/cann-samples 杨阳, zhangzijie (2/2) 杨阳, zhangzijie (2/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)

CLA Signature Pass

tangweiwei2, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robot
CANN-robot成员
7 天前 评论:

CLA Signature Pass

tangweiwei2, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robotCANN-robot成员
7 天前 将yangyang016,zhou-qilong,rxtfeng,loov1,zhangzijie,zl_hw,pingchuantang,llimwang,gubaocheng设为评审人
CANN-robotCANN-robot成员
7 天前 将yangyang016,zhou-qilong,rxtfeng,loov1,zhangzijie,zl_hw,pingchuantang,llimwang,gubaocheng设为审查人
tangweiwei2
7 天前 评论:

/compile

likedislike
Ttangweiwei2
7 天前 update merge request[project id: 8788227, iid: 393, commit_id: c905da3d18115bface111a54a0222f21280fd823] virtual merging success
CANN-robotCANN-robot成员
7 天前 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
7 天前 评论:

流水线任务触发成功
任务链接 [3abb6bf9f61a46a0a45465f538bd2154][流水线指导]

任务名称状态日志下载链接
codecheck ✅ SUCCESS >>>>>
SCA ✅ SUCCESS >>>>>
antipoison ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Check_pr ✅ SUCCESS
Compile_Ascend_X86_910c ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_910c ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
codecheck_codestyle ⚠️ WARNING >>>>>
precommit ✅ SUCCESS >>>>>
pre_comment ✅ SUCCESS >>>>>

[2026-08-13 21:40:12]    CI执行结束

likedislike
CANN-robotCANN-robot成员
7 天前 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
7 天前 添加了label:ci-pipeline-passed
yangyang016成员6 天前进行代码检视2
Samples/2_Performance/matmul_story/matmul_recipes/include/tiling/quant_matmul_tiling_data.h
已过期
@@ -9,7 +9,7 @@
99 */
1010 
1111/*!
1212 * \file quant_matmul_tiling_data.h
yangyang0166 天前评论:

【建议】本次重命名的目的是明确该 TilingData 仅适用于 MX,并避免与其他量化类型混淆;但类型改为 QuantMatmulMxTilingData 后,定义文件仍保留泛化名称 quant_matmul_tiling_data.h,文件中的 \file 和 brief 也没有体现 MX 范围。

同目录已有 quant_matmul_hifp8_tiling_data.h 对应 QuantMatmulHifp8TilingDataweight_quant_matmul_mxfp8fp4_tiling_data.h 对应 WeightQuantMatmulMxfp8Fp4TilingData。建议同步将本文件重命名为 quant_matmul_mx_tiling_data.h,并更新相关 include 及文件说明,避免后续增加其他 QuantMatmul TilingData 时仍在文件层面产生歧义。

likedislike
System
系统消息系统
6 天前 评论:

changed this line on 2526ab20 view diff detail

Ttangweiwei2
6 天前 update merge request[project id: 8788227, iid: 393, commit_id: 1f0e398abaa7cc9be1696e73796cccbbf2f416f3] virtual merging success
此处折叠了5条事件消息 查看更多
CANN-robotCANN-robot成员
6 天前 添加了label:cann-cla/yes
CANN-robot
CANN-robot成员
6 天前 评论:

Notification

This pull request has been changed(code update) or closed, so removes the following label(s): ci-pipeline-passed.

likedislike
tangweiwei2
6 天前 评论:

/compile

likedislike
Ttangweiwei2
6 天前 update merge request[project id: 8788227, iid: 393, commit_id: 40398a4c75f0fc408b957eeda588e696ba0496a4] virtual merging success
CANN-robotCANN-robot成员
6 天前 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
6 天前 评论:

流水线任务触发成功
任务链接 [122163315c97457d999249f189b1a83a][流水线指导]

任务名称状态日志下载链接
codecheck ✅ SUCCESS >>>>>
SCA ✅ SUCCESS >>>>>
antipoison ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Check_pr ✅ SUCCESS
Compile_Ascend_X86_910c ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_910c ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
codecheck_codestyle ⚠️ WARNING >>>>>
precommit ✅ SUCCESS >>>>>
pre_comment ✅ SUCCESS >>>>>

[2026-08-14 16:27:01]    CI执行结束

likedislike
CANN-robotCANN-robot成员
6 天前 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
6 天前 添加了label:ci-pipeline-passed
yangyang016成员
6 天前 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
6 天前 添加了label:approved
zhangzijie成员
6 天前 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
6 天前 添加了label:lgtm
CANN-robot
CANN-robot成员
6 天前 评论:

The MR can not be merged, because of CodeReview discussion not resolved

If you want to solve this problem, you can click here to do it in the FAQs.

likedislike
Yyangyang016成员
6 天前 解决了最后一个问题
CANN-robotCANN-robot成员
6 天前 关闭了关联的issue
CANN-robotCANN-robot成员
6 天前 合入了pull request