已合并
【fix】: code warning #4795
tang-haojie创建于 21 天前
【fix】: code warning #4795
已合并
Pull Request已成功合入, 合并人@CANN-robot
(感谢 tang-haojie 的贡献)21 天前 添加了label:enhancement
21 天前 创建了 pull request,commit fa7166ee
atomgit-bot
21 天前 评论:
21 天前 评论:
变更摘要
本 PR 主要修复代码编译告警(code warning):为 SuperKernelPass 中不修改成员状态的三个成员函数补充 const 限定(含头文件声明同步),为示例 Python 脚本补齐文件头注释以消除格式告警,并在 DeviceHbmToHostPermanent 中对新建输出增加空指针断言以消除潜在告警。
主要改动
- 成员函数声明
const: 在super_kernel_pass.h中将GetEventId、GetKernelType、FillCoreLimit三个方法的声明加上const限定。 - 成员函数定义同步
const: 在super_kernel_pass.cc中,SuperKernelPass::GetEventId、SuperKernelPass::GetKernelType、SuperKernelPass::FillCoreLimit的定义同步补充const,使声明与定义保持一致,消除 const 一致性告警。 - 示例脚本补充文件头: 为
examples/fusion_pass/graph_base_pass/1_fuse_matmul_add_pass/data/下的tensorflow_generate.py与tf_forward.py各添加 shebang(#!/usr/bin/env python3)、编码声明(# -*- coding: utf-8 -*-)及注释分隔行。 - 增加空指针断言: 在
runtime/v2/lowering/placement/placed_lowering_result.cc的DeviceHbmToHostPermanent中,对bg::DevMemValueHolder::CreateSingleDataOutput的返回值dst_address新增GE_ASSERT_NOTNULL(dst_address)校验,防止后续调用AddDependency时使用空指针。


不准确?
atomgit-bot
21 天前 评论:
21 天前 评论:
21 天前 修改了pull request 的描述
21 天前 添加了label:cann-cla/yes
21 天前 修改了pull request 的描述
21 天前 修改了pull request 的描述
CANN-robot
21 天前 评论:
21 天前 评论:
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 |
|---|---|---|
| repo-cann/ge | ✅ yangyongqiang0606, Mexyy, yuht9 (3/2) | ✅ yangyongqiang0606 (1/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
tang-haojie, thanks for your pull request. All authors of the commits have signed the CLA. 👍


21 天前 修改了pull request 的描述
21 天前 修改了pull request 的描述
21 天前 将yangyongqiang0606,kobemini,ClarkXie,tangqunzhang,xchu42,hugo111,lining23666,depeng1994,wqtshg_wt,peiyang,shengnan666,zhangfan_hanq,zhanj,zhujingjing,Mexyy,wangxiaotian995,stevenaw0,yuht9设为评审人
21 天前 将yangyongqiang0606,kobemini,ClarkXie,tangqunzhang,xchu42,hugo111,lining23666,depeng1994,wqtshg_wt,peiyang,shengnan666,zhangfan_hanq,zhanj,zhujingjing,Mexyy,wangxiaotian995,stevenaw0,yuht9设为评审人
21 天前 修改了pull request 的描述
21 天前 将yangyongqiang0606,kobemini,ClarkXie,tangqunzhang,xchu42,hugo111,lining23666,depeng1994,wqtshg_wt,peiyang,shengnan666,zhangfan_hanq,zhanj,zhujingjing,Mexyy,wangxiaotian995,stevenaw0,yuht9设为审查人
21 天前 将yangyongqiang0606,kobemini,ClarkXie,tangqunzhang,xchu42,hugo111,lining23666,depeng1994,wqtshg_wt,peiyang,shengnan666,zhangfan_hanq,zhanj,zhujingjing,Mexyy,wangxiaotian995,stevenaw0,yuht9设为审查人
tang-haojie
21 天前 评论:
21 天前 评论:
compile


21 天前 预合并成功(commit_id: e63567b892b58517eff0a37e5df57507bb0e5259)
CANN-robot
21 天前 评论:
21 天前 评论:
| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


21 天前 添加了label:ci-pipeline-running
此处折叠了6条事件消息 查看更多
21 天前 添加了label:cann-cla/yes
tang-haojie
21 天前 评论:
21 天前 评论:
compile


21 天前 预合并成功(commit_id: c100be1680ae4724d62a58dacf6fbed49592e168)
CANN-robot
21 天前 评论:
21 天前 评论:
| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


21 天前 删除了label:ci-pipeline-failed
21 天前 添加了label:ci-pipeline-running
21 天前 删除了label:ci-pipeline-running
21 天前 添加了label:ci-pipeline-passed
21 天前 添加了label:lgtm
yangyongqiang
21 天前 评论:
21 天前 评论:
/approve


21 天前 添加了label:approved
21 天前 合入了pull request
Pull Request
描述
code warning
变更类型
请选择本次引入的变更类型:
关联的Issue
如何测试
描述测试此变更的步骤和前提条件:
1.
2.
核对清单
其他信息
在此添加任何其他关于本次 PR 的说明。