Pull Request has been successfully merged by CANN-robot.
(Thank you for TangPC's contribution.)变更摘要
本 PR 属于纯注释修正,不涉及业务逻辑、接口行为或配置默认值的变化。改动集中在修正多处注释与代码实际内容不一致的问题:包括文件头 \file 注释中的文件名拼写或命名错误,以及头文件 #endif 尾部注释中与真实包含保护宏不符的宏名。涉及 concat 的 infershape UT、diag_v2 的 B32 kernel 头文件、dynamic_stitch 的 arch35 SIMT 头文件,以及 fill 的两个 op_api 头文件。
主要改动
- 修正
concatUT 文件头注释:test_concat_infershape.cpp中的\file注释由拼写错误的test_concat_infershpe.cpp改为与实际文件名一致的test_concat_infershape.cpp。 - 修正
diag_v2头文件保护宏尾注释:diag_v2_b32.h末尾的#endif注释由DIAG_V2_B64_H更正为实际保护宏DIAG_V2_B32_H。 - 修正
dynamic_stitchSIMT 头文件注释:arch35/dynamic_stitch_scatter_simt.h的\file注释由dynamic_stitch_simt.h更正为dynamic_stitch_scatter_simt.h。 - 修正
fillop_api 头文件保护宏尾注释:aclnn_fill_scalar.h的#endif注释由OP_API_INC_FILL_H_更正为OP_API_ACLNN_FILL_SCALAR_H_,aclnn_fill_tensor.h的#endif注释由OP_API_INC_LEVEL2_ACLNN_FILL_TENSOR_H_更正为OP_API_ACLNN_FILL_TENSOR_H_。
🧩 本次 Review 已使用自定义 Skill:




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 |
|---|---|---|
| */*/op_api/*.h | ✅ 王永光, 王林木, 顾宝成 (3/2) | ✅ 王永光 (1/1) |
| conversion/concat | ✅ 顾宝成, 王林木 (2/2) | ✅ 顾宝成, 王林木 (2/1) |
| repo-cann/ops-math | ✅ 王林木, 顾宝成 (2/2) | ✅ 王林木, 顾宝成 (2/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
pingchuantang, thanks for your pull request. All authors of the commits have signed the CLA. 👍


compile


| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


流水线分析报告 — ops-math run#5536
流水线: https://gitcode.com/CANN/ops-math/actions/runs/a8d51e42df924b909bd44b69758f35b1 | PR#6598 | 2026-10-22 15:58:29 ~ 2026-10-22 16:09:34 | 失败 Job 1 个
定界结论: 代码问题 / 代码检查错误 — pre-commit 格式检查不通过
- 失败类型: 代码问题
- 根因: PR 变更文件未通过 pre-commit 格式检查, 3 个 hook 失败: clang-format、trim trailing whitespace、fix end of files, 共涉及 5 个文件
- 处置建议: 通知 PR 提交者修复 —— 本地执行
pre-commit run --files <变更文件>(或pre-commit run --all-files) 自动修复格式后重新提交推送- 参考链接: 本地执行 pre-commit 指导
- 排除项: codespell、OAT Compliance Check、check for merge conflicts、detect private key 等其余检查项均 Passed; 非 CI 环境/工具问题
失败根因分析
根因 #1: 代码问题 / 代码检查错误 — clang-format 等 3 项格式 hook 失败
- 判据: pre-commit 检查项不通过: clang-format / trailing-whitespace / end-of-file-fixer (均属格式类, 同因归组)
- 定位步骤:
3_precommit.log - 影响 Job: CodeCheck_precommit
- 涉及文件:
- clang-format 重排:
conversion/diag_v2/op_kernel/diag_v2_b32.h,conversion/concat/tests/ut/op_host/test_concat_infershape.cpp,conversion/dynamic_stitch/op_kernel/arch35/dynamic_stitch_scatter_simt.h,conversion/fill/op_api/aclnn_fill_scalar.h,conversion/fill/op_api/aclnn_fill_tensor.h - 行尾空白:
conversion/dynamic_stitch/op_kernel/arch35/dynamic_stitch_scatter_simt.h - 文件末尾换行:
conversion/fill/op_api/aclnn_fill_tensor.h
- clang-format 重排:
- 根因证据(日志原文):
[2026-10-22 15:59:54.243+08:00] trim trailing whitespace.................................................Failed
[2026-10-22 15:59:54.251+08:00] fix end of files.........................................................Failed
[2026-10-22 15:59:54.265+08:00] clang-format.............................................................Failed
[2026-10-22 15:59:54.276+08:00] Formatting [1/1] conversion/fill/op_api/aclnn_fill_tensor.h
[2026-10-22 15:59:54.331+08:00] [py stderr] ❌ 存在部分文件格式错误
[2026-10-22 15:59:54.341+08:00] ::error::precommit.py 异常退出: exit code=1, signal=null
结构化定界摘要
[{"repo": "ops-math", "run_number": 5536, "Failed_Type": "代码问题",
"Failed_Sub_Type": "代码检查错误", "Failed_Reason": "PR 变更文件未通过 pre-commit 格式检查: clang-format、trim trailing whitespace、fix end of files 三项 hook 失败, 涉及 diag_v2/concat/dynamic_stitch/fill 共 5 个文件",
"evidence": "clang-format.............................................................Failed",
"suggestion": "提交者本地执行 pre-commit run --files <变更文件> 自动修复格式后重新推送",
"jobs": "CodeCheck_precommit"}]
由门禁失败定界分析自动生成 | repo: ops-math | run: a8d51e42df924b909bd44b69758f35b1 | PR#6598


compile


| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


/lgtm
/approve
by agent


您好,PR已满足合入指标,请尽快联系Committer进行合入。如暂时不需要合入,请在PR标题前加[WIP]


/approve


描述
修正以下文件的注释与实际代码不一致问题:
conversion/concat/tests/ut/op_host/test_concat_infershape.cpp:\file注释由test_concat_infershpe.cpp修正为test_concat_infershape.cpp。conversion/diag_v2/op_kernel/diag_v2_b32.h:#endif尾注释由DIAG_V2_B64_H修正为实际保护宏DIAG_V2_B32_H。conversion/dynamic_stitch/op_kernel/arch35/dynamic_stitch_scatter_simt.h:\file注释由dynamic_stitch_simt.h修正为dynamic_stitch_scatter_simt.h。conversion/fill/op_api/aclnn_fill_scalar.h:#endif尾注释由OP_API_INC_FILL_H_修正为实际保护宏OP_API_ACLNN_FILL_SCALAR_H_。conversion/fill/op_api/aclnn_fill_tensor.h:#endif尾注释由OP_API_INC_LEVEL2_ACLNN_FILL_TENSOR_H_修正为实际保护宏OP_API_ACLNN_FILL_TENSOR_H_。此外,按仓库 pre-commit 要求,对被修改文件应用了文件末尾换行/空白/clang-format 修复(仅格式调整,不涉及业务逻辑、接口行为或配置默认值)。
关联的Issue
测试
文档更新
无独立文档文件更新;本次修正源文件注释,并同步仓库要求的格式问题。
类型标签
待确认项
无。