已合并
merge_proto: 合并算子原型时保留REG_OP前的注释 #3635
songkai111创建于 6月29日
merge_proto: 合并算子原型时保留REG_OP前的注释 #3635
已合并
Pull Request已成功合入, 合并人@CANN-robot
(感谢 songkai111 的贡献)6月29日 创建了 pull request,commit 3527c35b
6月29日 添加了label:cann-cla/yes
CANN-robot
6月29日 评论:
6月29日 评论:
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 |
|---|---|---|
| repo-cann/ops-math | ✅ wangrui_, 王林木 (2/2) | ✅ wangrui_ (1/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
songkai111, thanks for your pull request. All authors of the commits have signed the CLA. 👍


songkai111
6月29日 评论:
6月29日 评论:
compile


Ssongkai111
6月29日 update merge request[project id: 7649531, iid: 3635, commit_id: 2f2cd23b9712901e70ec18ed574215da310b7bfe] virtual merging success
6月29日 update merge request[project id: 7649531, iid: 3635, commit_id: 2f2cd23b9712901e70ec18ed574215da310b7bfe] virtual merging success
atomgit-bot
6月29日 评论:
6月29日 评论:
变更摘要
此 PR 修改了 scripts/util/merge_proto.py 中的正则表达式 OP_DEF_PATTERN,在合并算子原型时使其能够捕获并保留 REG_OP(...) 前的 C 风格块注释(/* ... */ 或 /** ... */)。由于合并逻辑使用 match.group(0) 获取完整匹配结果,新增的注释捕获组会自动包含在合并输出中,从而确保注释不会在合并过程中丢失。
主要改动
- 正则表达式新增
comment命名捕获组:在OP_DEF_PATTERN开头添加(?P<comment>[ \t]*/\*\*?(?:[^*]|\*(?!/))*?\*/[ \t]*\n\s*)?,用于可选地匹配REG_OP前的块注释,使合并后的原型定义保留原始注释内容。


6月29日 添加了label:ci-pipeline-running
CANN-robot
6月29日 评论:
6月29日 评论:
流水线任务触发成功
任务链接 [9f61f0a24e264d019208fd83fc190904][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| pre_comment | ✅ SUCCESS | >>>>> | |
| Compile_Ascend_X86_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_mobile_station_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_experimental_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_A5_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_harmony-infer | ✅ SUCCESS | >>>>> | |
| Compile_Ascend_ARM_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_experimental_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_single_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_A5_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910b | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910c | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_harmony-infer-chs-math | ✅ SUCCESS | >>>>> | |
| UT_Test | ✅ SUCCESS | ||
| UT_Test_experimental | ✅ SUCCESS | ||
| UT_Test_kernel | ✅ SUCCESS | ||
| PreSmoke_A900 | ✅ SUCCESS | >>>>> | |
| API_Check | ✅ SUCCESS | >>>>> | |
| PreSmoke_ATK_Test_A2 | ✅ SUCCESS | >>>>> |
[2026-06-29 23:05:53] CI执行结束


CANN-robot
6月29日 评论:
6月29日 评论:
流水线任务触发成功
任务链接 [e7ce25bc44134a6d9e7711484c7687b5][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| codecheck | ✅ SUCCESS | >>>>> | |
| SCA | ✅ SUCCESS | >>>>> | |
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_Pr | ✅ SUCCESS | ||
| StaticCheck_codespell_check | ✅ SUCCESS | ||
| StaticCheck_link_validity_check | ✅ SUCCESS | ||
| StaticCheck_resource_existence_check | ✅ SUCCESS | ||
| StaticCheck_tag_closed_check | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_codestyle | ✅ SUCCESS | >>>>> | |
| codecheck_precommit | ✅ SUCCESS | >>>>> |
[2026-06-29 23:01:54] CI执行结束


atomgit-bot
6月29日 评论:
6月29日 评论:
6月29日 添加了label:api-check-pass
6月29日 删除了label:ci-pipeline-running
6月29日 添加了label:ci-pipeline-passed
6月30日 添加了label:lgtmapproved
6月30日 合入了pull request
描述
关联的Issue
测试
文档更新
类型标签