Pull Request已成功合入, 合并人@CANN-robot
(感谢 xinweiliu 的贡献)变更摘要
此 PR 修复了 A16W8 场景下 InnerBatch 模式的 LoadAL1 指令中 DN2NZ 操作的一个 bug。在 HW 分块模式下,DN2NZ 指令 loop4 的 dst stride 配置错误地使用了通用对齐参数 Intf::k0,应改为使用 fmap 对应 dtype 的对齐参数 Intf::k0FmapTail。此变更将两个文件中所有相关的 dstNzMatrixStride 计算及 Load3DSetFMatrixCal 调用中的 k0 统一替换为 k0FmapTail,同时附带少量代码格式化调整。
主要改动
dstNzMatrixStride对齐参数修正(conv2d_v2_instr_base_impl.h): 在SetDn2NzIntriParams、SetNd2NzC04IntriParams、SetDn2NzC04IntriParams等多个函数中,将dstNzMatrixStride计算所用的对齐基数从Intf::k0改为Intf::k0FmapTail,确保 innerBatch 与非 innerBatch 场景下 stride 均按 fmap dtype 正确对齐。Load3DSetFMatrixCal对齐参数修正(conv2d_v2_instr_base_impl.h): 在 NCHW+C04 格式的 innerBatch 分支中,Load3DSetFMatrixCal的AlignB对齐参数从Intf::k0改为Intf::k0FmapTail,使 3D Load 的 fmatrix 计算使用正确的 dtype 对齐。dstNzMatrixStride对齐参数修正(conv2d_v2_instr_impl.h): 在SetDn2NzIntriParams、SetNd2NzIntriParamsInputHWNC、SetNd2NzIntriParamsC04InputHWNC等函数中,将dstNzMatrixStride的乘数从Intf::k0改为Intf::k0FmapTail,修复 HW 模式下 DN2NZ dst stride 的对齐错误。- 代码格式化(双文件): 对部分长行进行换行对齐,修正引用符号位置(如
Nd2NzParams &intriParams→Nd2NzParams& intriParams),并修复文件末尾缺失的换行符。


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
PR Approval Progress
✅ Congratulations! All modules have met the lgtm and approve requirements.
Module Approval Details
| module | lgtm status | approve status |
|---|---|---|
| conv | ✅ 王慈孟, 郑李磊 (2/2) | ✅ 郑李磊, 王慈孟 (2/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
xinweiliu, thanks for your pull request. All authors of the commits have signed the CLA. 👍


compile


流水线任务触发成功
任务链接 [75363fa58ecd43a3818fc0c003317d8f][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| Compile_Ascend_X86_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_mobile_station | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_single | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_experimental | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Pre | ✅ SUCCESS | >>>>> | |
| pre_comment | ✅ SUCCESS | >>>>> | |
| Compile_Ascend_X86 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_mobile_station_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_single_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_experimental_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_950_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910b | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910c | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_classify | ✅ SUCCESS | >>>>> | |
| Compile_Ascend_X86_mobile_station_9030_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
[2026-07-21 18:38:29] CI执行结束


流水线任务触发成功
任务链接 [13798240d81f45ec861148d086af0d9c][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_checkpr | ✅ SUCCESS | ||
| StaticCheck_codespell | ✅ SUCCESS | ||
| StaticCheck_link_validity | ✅ SUCCESS | ||
| StaticCheck_resource_existence | ✅ SUCCESS | ||
| StaticCheck_tag_closed | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_style | ✅ SUCCESS | >>>>> | |
| codecheck_precommit | ❌ FAILED | >>>>> | >>>>> |
| SCA | ✅ SUCCESS | >>>>> |


compile


流水线任务触发成功
任务链接 [468711ff923f4c46af6cec0e1629c949][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| Compile_Ascend_X86_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_mobile_station | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_single | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_experimental | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Pre | ✅ SUCCESS | >>>>> | |
| pre_comment | ✅ SUCCESS | >>>>> | |
| Compile_Ascend_X86 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_mobile_station_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_950_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_single_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_experimental_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_950_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910b | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910c | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_classify | ✅ SUCCESS | >>>>> | |
| Compile_Ascend_X86_mobile_station_9030_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| UT_Test_ophost | ✅ SUCCESS | ||
| UT_Test_opapi | ✅ SUCCESS | ||
| UT_Test_kernel | ✅ SUCCESS | ||
| UT_Test_opgraph | ✅ SUCCESS | ||
| PreSmoke_A900 | ✅ SUCCESS | >>>>> | |
| API_Check | ✅ SUCCESS | >>>>> | |
| PreSmoke_ATK_Test_A2 | ✅ SUCCESS | >>>>> | |
| UT_Test_harmony-infer-chs-nn | ✅ SUCCESS | ||
| UT_Test_harmony-infer-chs-nn-1 | ✅ SUCCESS | ||
| UT_Test_report_lcov | ✅ SUCCESS | >>>>> |
[2026-07-21 19:13:47] CI执行结束


流水线任务触发成功
任务链接 [3a4ed26004a34801a9c39ac7ff858b34][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_checkpr | ✅ SUCCESS | ||
| StaticCheck_codespell | ✅ SUCCESS | ||
| StaticCheck_link_validity | ✅ SUCCESS | ||
| StaticCheck_resource_existence | ✅ SUCCESS | ||
| StaticCheck_tag_closed | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_style | ✅ SUCCESS | >>>>> | |
| codecheck_precommit | ✅ SUCCESS | >>>>> | |
| SCA | ✅ SUCCESS | >>>>> |
[2026-07-21 18:41:57] CI执行结束


/reject


| Time | Name | Result | Link |
|---|---|---|---|
| 2026-07-21 19:16:48 | Trigger_SC | :white_check_mark: SUCCESS | 20260721_192055537 |


| Time | Name | Result | Link |
|---|---|---|---|
| 2026-07-21 19:37:59 | Trigger_RDV | :white_check_mark: SUCCESS | 20260721_194206873 |


| Time | Name | Result | Link |
|---|---|---|---|
| 2026-07-22 10:14:36 | Trigger_SC | :white_check_mark: SUCCESS | 20260722_101844985 |


| Time | Name | Result | Link | ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2026-07-22 10:40:45 | commit | 2026-07-21T18:36:18+08:00 | 07d0c925 | ||||||||||||||||||||||||||||||||||||
| Compile_Result | :x: NOT_RUN | ||||||||||||||||||||||||||||||||||||||
| SC_Result | :x: FAILURE | >>> | |||||||||||||||||||||||||||||||||||||
| RDV_Result:ALL | :x: RUNNING | >>> | |||||||||||||||||||||||||||||||||||||
|


| Time | Name | Result | Link |
|---|---|---|---|
| 2026-07-22 11:05:40 | Trigger_SC | :white_check_mark: SUCCESS | 20260722_110948611 |


| Time | Name | Result | Link |
|---|---|---|---|
| 2026-07-22 11:34:00 | Trigger_RDV | :white_check_mark: SUCCESS | 20260722_113809282 |


| Time | Name | Result | Link | ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2026-07-22 18:14:22 | commit | 2026-07-21T18:36:18+08:00 | 07d0c925 | ||||||||||||||||||||||||||||||||||||
| Compile_Result | :x: NOT_RUN | ||||||||||||||||||||||||||||||||||||||
| SC_Result | :x: FAILURE | >>> | |||||||||||||||||||||||||||||||||||||
| RDV_Result:ALL | :white_check_mark: SUCCESS | >>> | |||||||||||||||||||||||||||||||||||||
|


/lgtm
/approve


/lgtm
/approve


描述
A16W8 场景 innerbatch,HW模式下LoadAL1的 DN2NZ指令loop4 dst stride配置使用的k0错误,需要使用fmap对应dtype的k;
关联的Issue
#4206
测试
文档更新
类型标签
AI/Agent生成声明