- 上板dump用到的接口封装到adapter层


Pull Request has been successfully merged by CANN-robot.
(Thank you for dingbo929's contribution.)变更摘要
此 PR 将上板 dump 用到的 AdxDataDumpServerInit 和 AdxDataDumpServerUnInit 两个函数从直接声明 extern "C" __attribute__((weak)) 弱符号并散落在 device_launcher.cpp / device_runner.cpp 中调用的方式,统一封装到 adapter 层(adump_api),通过 AdapterManager 动态获取函数指针或回退到 stub 实现,从而解耦调用方与底层库的直接依赖。
主要改动
- 新增 adapter 层接口
AdxDumpDataDumpServerInit/AdxDumpDataDumpServerUnInit:在adump_api.h中声明、adump_api.cpp中实现,通过AdapterManager查找AdumpFunc::DataDumpServerInit/DataDumpServerUnInit对应的函数指针并调用,若未找到则回退到对应的 stub 函数。 - 扩展
AdumpFunc枚举与函数名映射:在adump_adapter_types.h中新增DataDumpServerInit和DataDumpServerUnInit两个枚举值,并在kAdumpFuncStrMap中添加对应的函数名字符串映射。 - 新增 stub 实现:在
adump_stubs.h/adump_stubs.cpp中新增StubDumpDataDumpServerInit()和StubDumpDataDumpServerUnInit(),提供空实现与日志记录。 - 重构
device_launcher.cpp中的调用方式:移除extern "C" __attribute__((weak))弱符号声明及空指针判空逻辑,DataDumpInit()和DataDumpUnInit()改为直接调用 adapter 接口AdxDumpDataDumpServerInit()和AdxDumpDataDumpServerUnInit()。 - 重构
device_runner.cpp中的调用方式:移除extern "C" __attribute__((weak))弱符号声明及判空分支,DynamicLaunchSynchronize()中改为直接调用AdxDumpDataDumpServerUnInit()。


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/pypto | ✅ DCGDDD, gaoxingwang (2/2) | ✅ DCGDDD (1/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
dingbo929, thanks for your pull request. All authors of the commits have signed the CLA. 👍


compile


流水线任务触发成功
任务链接 [dec9e3e720be4f2691f7de2028113363][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| Compile_Ascend_X86 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| pre_comment | ✅ SUCCESS | >>>>> | |
| UT_Test_Py3_ninja_simulation | ✅ SUCCESS | ||
| UT_Test_Py3_ninja | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_1 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_2 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_3 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part1 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part2 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part3 | ✅ SUCCESS | ||
| UT_Test_kirinx90 | ✅ SUCCESS | ||
| UT_Test_kirin9030 | ✅ SUCCESS | ||
| UT_Test_report | ❌ FAILED | >>>>> |


流水线任务触发成功
任务链接 [3499f32113444637b8e1259efc62a302][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| SCA | ✅ SUCCESS | >>>>> | |
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_Pr | ✅ SUCCESS | ||
| StaticCheck_codespell | ✅ SUCCESS | ||
| StaticCheck_link_validity | ✅ SUCCESS | ||
| StaticCheck_resource_existence | ✅ SUCCESS | ||
| StaticCheck_tag_closed | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_codestyle | ✅ SUCCESS | >>>>> | |
| codecheck_precommit | ✅ SUCCESS | >>>>> | |
| StaticCheck_md | ✅ SUCCESS |
[2026-08-11 16:14:58] CI执行结束


流水线任务触发成功
任务链接 [7bfa25e2c1114b35860d323e411495f8][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| get_pr_file | ✅ SUCCESS | ||
| static-check | ✅ SUCCESS | ||
| compile | ❌ FAILED |


compile


流水线任务触发成功
任务链接 [14ecfa34f14046288781a14448831daf][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| Compile_Ascend_X86 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| pre_comment | ✅ SUCCESS | >>>>> | |
| UT_Test_Py3_ninja_simulation | ✅ SUCCESS | ||
| UT_Test_Py3_ninja | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_1 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_2 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_3 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part1 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part2 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part3 | ✅ SUCCESS | ||
| UT_Test_kirinx90 | ✅ SUCCESS | ||
| UT_Test_kirin9030 | ✅ SUCCESS | ||
| UT_Test_report | ✅ SUCCESS | >>>>> | |
| PreSmoke_A900 | ✅ SUCCESS | >>>>> |
[2026-08-11 17:21:30] CI执行结束


流水线任务触发成功
任务链接 [b8db9fc00b094fd989ae95d707b9c08a][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| SCA | ✅ SUCCESS | >>>>> | |
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_Pr | ✅ SUCCESS | ||
| StaticCheck_codespell | ✅ SUCCESS | ||
| StaticCheck_link_validity | ✅ SUCCESS | ||
| StaticCheck_resource_existence | ✅ SUCCESS | ||
| StaticCheck_tag_closed | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_codestyle | ⚠️ WARNING | >>>>> | |
| codecheck_precommit | ❌ FAILED | >>>>> | >>>>> |
| StaticCheck_md | ✅ SUCCESS |


流水线任务触发成功
任务链接 [50852d53c21046069551803aa5baa67b][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| get_pr_file | ✅ SUCCESS | ||
| static-check | ❌ FAILED | ||
| compile | ✅ SUCCESS |


compile


流水线任务触发成功
任务链接 [14e3a96ece4646fe9015853d541047f7][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| Compile_Ascend_X86 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_ubuntu24 | ✅ SUCCESS | >>>>> | >>>>> |
| pre_comment | ✅ SUCCESS | >>>>> | |
| UT_Test_Py3_ninja_simulation | ✅ SUCCESS | ||
| UT_Test_Py3_ninja | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_1 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_2 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_gnu_part_3 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part1 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part2 | ✅ SUCCESS | ||
| UT_Test_Cpp_make_clang_part3 | ✅ SUCCESS | ||
| UT_Test_kirinx90 | ✅ SUCCESS | ||
| UT_Test_kirin9030 | ✅ SUCCESS | ||
| UT_Test_report | ✅ SUCCESS | >>>>> | |
| PreSmoke_A900 | ✅ SUCCESS | >>>>> |
[2026-08-11 19:33:59] CI执行结束


流水线任务触发成功
任务链接 [ec2c3efac7ca45bbbdf647dfd36c23e1][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| SCA | ✅ SUCCESS | >>>>> | |
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_Pr | ✅ SUCCESS | ||
| StaticCheck_codespell | ✅ SUCCESS | ||
| StaticCheck_link_validity | ✅ SUCCESS | ||
| StaticCheck_resource_existence | ✅ SUCCESS | ||
| StaticCheck_tag_closed | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_codestyle | ✅ SUCCESS | >>>>> | |
| codecheck_precommit | ✅ SUCCESS | >>>>> | |
| StaticCheck_md | ✅ SUCCESS |
[2026-08-11 19:07:03] CI执行结束


流水线任务触发成功
任务链接 [714a77053c5845769259a026fa55fdf1][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| get_pr_file | ✅ SUCCESS | ||
| static-check | ✅ SUCCESS | ||
| compile | ✅ SUCCESS |
[2026-08-11 19:34:35] CI执行结束


/lgtm


/approve

