| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[fix] examples样例补齐缺失的 #include <cstdio> Co-authored-by: zhangxp1030<zhangxingping4@huawei.com> # message auto-generated for no-merge-commit merge: !3791 merge fix-examples-cstdio into master [fix] examples样例补齐缺失的 #include <cstdio> Created-by: zhangxp1030 Commit-by: zhangxp1030 Merged-by: cann-robot Description: ### 问题背景 关联 issue: https://gitcode.com/cann/hccl/issues/871 examples/ 下 17 个 main.cc(01_point_to_point ×2、02_collectives ×11、04/05/06 custom_ops 系列 testcase ×4)在 ACLCHECK/HCCLCHECK 宏中调用 printf,但均未包含 <cstdio>。 当前能编译依赖两条无标准保证的兜底链: - <iostream> → <cstdio>:libstdc++ 实现的传递包含,C++ 标准不保证; - hccl.h → securec.h → securectype.h → <stdio.h>:CANN 侧头文件内部包含。 两条链均不在本仓控制范围内,且 CI 编译门禁不覆盖 examples,兜底失效时将直接编译报错且无预警。 ### 修改内容 为 17 个 main.cc 各补一行 #include <cstdio>,插入位置与本仓 test/ut/common 既有写法(alg_parse、prepare_ut_env 均在标准头块首位包含 <cstdio>)保持一致。 ### 验证 - g++ 13.3.0 + CANN 9.1.0 头文件,-std=c++17 -fsyntax-only 逐文件编译,17/17 通过; - diff 仅 17 行新增,无逻辑改动,零风险。 See merge request: cann/hccl!3791 | 8 天前 | |
[fix] examples样例补齐缺失的 #include <cstdio> Co-authored-by: zhangxp1030<zhangxingping4@huawei.com> # message auto-generated for no-merge-commit merge: !3791 merge fix-examples-cstdio into master [fix] examples样例补齐缺失的 #include <cstdio> Created-by: zhangxp1030 Commit-by: zhangxp1030 Merged-by: cann-robot Description: ### 问题背景 关联 issue: https://gitcode.com/cann/hccl/issues/871 examples/ 下 17 个 main.cc(01_point_to_point ×2、02_collectives ×11、04/05/06 custom_ops 系列 testcase ×4)在 ACLCHECK/HCCLCHECK 宏中调用 printf,但均未包含 <cstdio>。 当前能编译依赖两条无标准保证的兜底链: - <iostream> → <cstdio>:libstdc++ 实现的传递包含,C++ 标准不保证; - hccl.h → securec.h → securectype.h → <stdio.h>:CANN 侧头文件内部包含。 两条链均不在本仓控制范围内,且 CI 编译门禁不覆盖 examples,兜底失效时将直接编译报错且无预警。 ### 修改内容 为 17 个 main.cc 各补一行 #include <cstdio>,插入位置与本仓 test/ut/common 既有写法(alg_parse、prepare_ut_env 均在标准头块首位包含 <cstdio>)保持一致。 ### 验证 - g++ 13.3.0 + CANN 9.1.0 头文件,-std=c++17 -fsyntax-only 逐文件编译,17/17 通过; - diff 仅 17 行新增,无逻辑改动,零风险。 See merge request: cann/hccl!3791 | 8 天前 | |
非产品名称去空格。增加architeture对应的英文文档 Co-authored-by: yuwang-<yuwang11@h-partners.com> # message auto-generated for no-merge-commit merge: !3367 merge master into master 非产品名称去空格。增加architeture对应的英文文档 Created-by: yuwang- Commit-by: yuwang- Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。--> <!-- 如果这个PR不涉及Issue,可填写"NA"。--> ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于构造对应xx测试用例、二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/hccl!3367 | 1 个月前 | |
[fix] examples样例补齐缺失的 #include <cstdio> Co-authored-by: zhangxp1030<zhangxingping4@huawei.com> # message auto-generated for no-merge-commit merge: !3791 merge fix-examples-cstdio into master [fix] examples样例补齐缺失的 #include <cstdio> Created-by: zhangxp1030 Commit-by: zhangxp1030 Merged-by: cann-robot Description: ### 问题背景 关联 issue: https://gitcode.com/cann/hccl/issues/871 examples/ 下 17 个 main.cc(01_point_to_point ×2、02_collectives ×11、04/05/06 custom_ops 系列 testcase ×4)在 ACLCHECK/HCCLCHECK 宏中调用 printf,但均未包含 <cstdio>。 当前能编译依赖两条无标准保证的兜底链: - <iostream> → <cstdio>:libstdc++ 实现的传递包含,C++ 标准不保证; - hccl.h → securec.h → securectype.h → <stdio.h>:CANN 侧头文件内部包含。 两条链均不在本仓控制范围内,且 CI 编译门禁不覆盖 examples,兜底失效时将直接编译报错且无预警。 ### 修改内容 为 17 个 main.cc 各补一行 #include <cstdio>,插入位置与本仓 test/ut/common 既有写法(alg_parse、prepare_ut_env 均在标准头块首位包含 <cstdio>)保持一致。 ### 验证 - g++ 13.3.0 + CANN 9.1.0 头文件,-std=c++17 -fsyntax-only 逐文件编译,17/17 通过; - diff 仅 17 行新增,无逻辑改动,零风险。 See merge request: cann/hccl!3791 | 8 天前 | |
[fix] examples样例补齐缺失的 #include <cstdio> Co-authored-by: zhangxp1030<zhangxingping4@huawei.com> # message auto-generated for no-merge-commit merge: !3791 merge fix-examples-cstdio into master [fix] examples样例补齐缺失的 #include <cstdio> Created-by: zhangxp1030 Commit-by: zhangxp1030 Merged-by: cann-robot Description: ### 问题背景 关联 issue: https://gitcode.com/cann/hccl/issues/871 examples/ 下 17 个 main.cc(01_point_to_point ×2、02_collectives ×11、04/05/06 custom_ops 系列 testcase ×4)在 ACLCHECK/HCCLCHECK 宏中调用 printf,但均未包含 <cstdio>。 当前能编译依赖两条无标准保证的兜底链: - <iostream> → <cstdio>:libstdc++ 实现的传递包含,C++ 标准不保证; - hccl.h → securec.h → securectype.h → <stdio.h>:CANN 侧头文件内部包含。 两条链均不在本仓控制范围内,且 CI 编译门禁不覆盖 examples,兜底失效时将直接编译报错且无预警。 ### 修改内容 为 17 个 main.cc 各补一行 #include <cstdio>,插入位置与本仓 test/ut/common 既有写法(alg_parse、prepare_ut_env 均在标准头块首位包含 <cstdio>)保持一致。 ### 验证 - g++ 13.3.0 + CANN 9.1.0 头文件,-std=c++17 -fsyntax-only 逐文件编译,17/17 通过; - diff 仅 17 行新增,无逻辑改动,零风险。 See merge request: cann/hccl!3791 | 8 天前 | |
[fix] examples样例补齐缺失的 #include <cstdio> Co-authored-by: zhangxp1030<zhangxingping4@huawei.com> # message auto-generated for no-merge-commit merge: !3791 merge fix-examples-cstdio into master [fix] examples样例补齐缺失的 #include <cstdio> Created-by: zhangxp1030 Commit-by: zhangxp1030 Merged-by: cann-robot Description: ### 问题背景 关联 issue: https://gitcode.com/cann/hccl/issues/871 examples/ 下 17 个 main.cc(01_point_to_point ×2、02_collectives ×11、04/05/06 custom_ops 系列 testcase ×4)在 ACLCHECK/HCCLCHECK 宏中调用 printf,但均未包含 <cstdio>。 当前能编译依赖两条无标准保证的兜底链: - <iostream> → <cstdio>:libstdc++ 实现的传递包含,C++ 标准不保证; - hccl.h → securec.h → securectype.h → <stdio.h>:CANN 侧头文件内部包含。 两条链均不在本仓控制范围内,且 CI 编译门禁不覆盖 examples,兜底失效时将直接编译报错且无预警。 ### 修改内容 为 17 个 main.cc 各补一行 #include <cstdio>,插入位置与本仓 test/ut/common 既有写法(alg_parse、prepare_ut_env 均在标准头块首位包含 <cstdio>)保持一致。 ### 验证 - g++ 13.3.0 + CANN 9.1.0 头文件,-std=c++17 -fsyntax-only 逐文件编译,17/17 通过; - diff 仅 17 行新增,无逻辑改动,零风险。 See merge request: cann/hccl!3791 | 8 天前 | |
fix: reject tuner configs exceeding rule limits(#867) Co-authored-by: aodebiao<18003961989@163.com> # message auto-generated for no-merge-commit merge: !3781 merge fix/tuner-config-rule-limits-20261028 into master fix: reject tuner configs exceeding rule limits(#867) Created-by: gxhgxh2475698 Commit-by: aodebiao Merged-by: cann-robot Description: # Pull Request ## 描述 ### Motivation The tuner configuration generator can report success for more rules than the plugin accepts: rules after the first 2000 per operator are skipped, and over 5000 total rules disables the plugin configuration. ### Changes - Reject configurations exceeding either plugin limit before opening the output file, with a clear error. - Cover the limit boundaries and preservation of an existing output file. - Document the limits and recovery options in the Chinese and English guides. ## 关联的Issue Related Issues: #867 ## 测试 - The baseline generator produces 2001 rules for one operator and 5001 rules across three operators. With real CSV inputs, the fixed CLI rejects both without overwriting an existing output and accepts 2000 for one operator. - All 171 tuner Python tests pass in an offline Linux container, including the added boundary and output-preservation tests. - git diff --check and OAT checks on both Python files pass. Plugin behavior was checked against source; NPU execution and full CANN builds were not run. ## 文档更新 Updated both tuner example guides. ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/hccl!3781 | 7 天前 | |
[feat] examples: 新增 AllGatherV 与 ReduceScatterV 集合通信样例 Co-authored-by: Leewis<liwei945@huawei.com> # message auto-generated for no-merge-commit merge: !3585 merge feature/examples-allgatherv-reducescatterv into master [feat] examples: 新增 AllGatherV 与 ReduceScatterV 集合通信样例 Created-by: Leewis Commit-by: Leewis Merged-by: cann-robot Description: ## 描述 本 PR 在 examples/02_collectives/ 下新增 AllGatherV 与 ReduceScatterV 两个集合通信样例,补齐 examples 中带 V(Variable)语义的集合通信接口样例,方便用户参考使用。 改动原因:现有 examples 的集合通信样例覆盖了 AllGather、ReduceScatter,但缺少支持**变长数据量**的 AllGatherV / ReduceScatterV 样例。社区用户在使用这两个接口时缺少可直接运行的参考。 所采取的方法: - 新增 examples/02_collectives/10_allgatherv/,调用 HcclAllGatherV()。为体现 V 语义,将第 i 个 rank 的 sendCount 设为 i + 1,并据此构造 recvCounts(各 rank 数据长度)与 recvDispls(各 rank 数据在 recvBuf 中的偏移)。 - 新增 examples/02_collectives/11_reduce_scatterv/,调用 HcclReduceScatterV()。将编号为 i 的数据块大小设为 i + 1,并构造 sendCounts / sendDispls(各 rank 保持一致)。 - 两个样例均沿用仓内既有样例(03_allgather / 04_reduce_scatter / 07_alltoallv)的结构与风格:单进程多线程多卡、HcclGetRootInfo + HcclCommInitRootInfo 建链、ACLCHECK / HCCLCHECK 宏、CANN-2.0 许可头,各含 main.cc / Makefile / README.md / README_en.md。 - 在 examples/README.md 与 examples/README_en.md 的「集合通信」章节补充 AllGatherV、ReduceScatterV 索引条目(紧随各自非 V 版本之后)。 ## 关联的Issue NA ## 测试 **已在真实 CANN 环境完成上板验证,两个样例编译、运行、结果校验全部通过。** ### 验证环境 - 硬件:Atlas A3 训练系列产品,8 NPU × 2 die = 16 个 Ascend910 device(驱动 26.1.1,固件 9.0.0.9.220) - CANN:Ascend-cann-toolkit_9.3.0~weekly.20261009.01,并手动安装同周期算子包 Ascend-cann-A3-ops_9.3.0~weekly.20261009.01_linux-aarch64.run(toolkit 包默认不携带 hccl 组件,需安装 ops 包后 libhccl.so、include/hccl/hccl.h、aicpu_hccl.tar.gz 方可就位) - 交叉验证环境:CANN 9.1.0(自带 hccl 组件),两套环境结论一致 ### 编译 两个样例均使用仓内 Makefile 默认编译选项(-std=c++17 -Werror -fstack-protector-strong -fPIE -pie -O2 -s -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack -Wl,--copy-dt-needed-entries),在 9.1.0 与 9.3.0 两套环境编译通过,无任何告警。 ### 运行结果(16 rank 全规模) | 样例 | 结果 | 输出校验 | |---|---|---| | 10_allgatherv | 通过(退出码 0) | 16 个 rank 输出一致,均为 136(= 1+2+…+16)个元素:rank i 贡献 i+1 个值为 i 的元素,按 rank_id 顺序拼接,如 rankId: 0, output: [ 0 1 1 2 2 2 3 3 3 3 4 4 4 4 4 … 15×16 ],与预期完全一致 | | 11_reduce_scatterv | 通过(退出码 0) | rank i 输出 i+1 个元素,每个值均为 120(= 0+1+…+15 的 SUM 归约),如 rankId: 15, output: [ 120×16 ],变长数据块分发语义正确 | 通信域创建/销毁、流同步、Device 内存申请释放均无错误。 ### 复现命令 bash source /usr/local/Ascend/cann-9.3.0/set_env.sh # 需已安装同周期 A3-ops 算子包 export HCCL_HOST_SOCKET_PORT_RANGE=41000-41100 # 与其他 HCCL 业务进程共机时需指定独立端口 export HCCL_NPU_SOCKET_PORT_RANGE=42000-42100 cd examples/02_collectives/10_allgatherv && make && ./allgatherv cd ../11_reduce_scatterv && make && ./reduce_scatterv ### 回归 同环境下仓内其余同构样例(02_collectives/01~09 及 01_point_to_point/01~02,共 11 个)全部编译运行通过,输出符合预期。 ### 环境备注(供复现者参考) - toolkit 包不携带 hccl 组件,运行样例前需安装同周期对应产品型号的 ops 算子包:./Ascend-cann-A3-ops_<version>_linux-aarch64.run --install --install-path=<toolkit安装路径> - 与其他 HCCL 业务进程(如推理服务)共机运行时,默认 host 侧端口(60000)与 NPU 侧端口(16666)可能被占用,导致 HcclCommInitRootInfo 返回 HCCL_E_INTERNAL(4);需通过 HCCL_HOST_SOCKET_PORT_RANGE / HCCL_NPU_SOCKET_PORT_RANGE 为样例进程指定独立端口范围 ## 文档更新 - 新增两个样例的 README.md、README_en.md - 更新 examples/README.md、examples/README_en.md(新增两条索引) ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/hccl!3585 | 23 天前 | |
[feat] examples: 新增 AllGatherV 与 ReduceScatterV 集合通信样例 Co-authored-by: Leewis<liwei945@huawei.com> # message auto-generated for no-merge-commit merge: !3585 merge feature/examples-allgatherv-reducescatterv into master [feat] examples: 新增 AllGatherV 与 ReduceScatterV 集合通信样例 Created-by: Leewis Commit-by: Leewis Merged-by: cann-robot Description: ## 描述 本 PR 在 examples/02_collectives/ 下新增 AllGatherV 与 ReduceScatterV 两个集合通信样例,补齐 examples 中带 V(Variable)语义的集合通信接口样例,方便用户参考使用。 改动原因:现有 examples 的集合通信样例覆盖了 AllGather、ReduceScatter,但缺少支持**变长数据量**的 AllGatherV / ReduceScatterV 样例。社区用户在使用这两个接口时缺少可直接运行的参考。 所采取的方法: - 新增 examples/02_collectives/10_allgatherv/,调用 HcclAllGatherV()。为体现 V 语义,将第 i 个 rank 的 sendCount 设为 i + 1,并据此构造 recvCounts(各 rank 数据长度)与 recvDispls(各 rank 数据在 recvBuf 中的偏移)。 - 新增 examples/02_collectives/11_reduce_scatterv/,调用 HcclReduceScatterV()。将编号为 i 的数据块大小设为 i + 1,并构造 sendCounts / sendDispls(各 rank 保持一致)。 - 两个样例均沿用仓内既有样例(03_allgather / 04_reduce_scatter / 07_alltoallv)的结构与风格:单进程多线程多卡、HcclGetRootInfo + HcclCommInitRootInfo 建链、ACLCHECK / HCCLCHECK 宏、CANN-2.0 许可头,各含 main.cc / Makefile / README.md / README_en.md。 - 在 examples/README.md 与 examples/README_en.md 的「集合通信」章节补充 AllGatherV、ReduceScatterV 索引条目(紧随各自非 V 版本之后)。 ## 关联的Issue NA ## 测试 **已在真实 CANN 环境完成上板验证,两个样例编译、运行、结果校验全部通过。** ### 验证环境 - 硬件:Atlas A3 训练系列产品,8 NPU × 2 die = 16 个 Ascend910 device(驱动 26.1.1,固件 9.0.0.9.220) - CANN:Ascend-cann-toolkit_9.3.0~weekly.20261009.01,并手动安装同周期算子包 Ascend-cann-A3-ops_9.3.0~weekly.20261009.01_linux-aarch64.run(toolkit 包默认不携带 hccl 组件,需安装 ops 包后 libhccl.so、include/hccl/hccl.h、aicpu_hccl.tar.gz 方可就位) - 交叉验证环境:CANN 9.1.0(自带 hccl 组件),两套环境结论一致 ### 编译 两个样例均使用仓内 Makefile 默认编译选项(-std=c++17 -Werror -fstack-protector-strong -fPIE -pie -O2 -s -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack -Wl,--copy-dt-needed-entries),在 9.1.0 与 9.3.0 两套环境编译通过,无任何告警。 ### 运行结果(16 rank 全规模) | 样例 | 结果 | 输出校验 | |---|---|---| | 10_allgatherv | 通过(退出码 0) | 16 个 rank 输出一致,均为 136(= 1+2+…+16)个元素:rank i 贡献 i+1 个值为 i 的元素,按 rank_id 顺序拼接,如 rankId: 0, output: [ 0 1 1 2 2 2 3 3 3 3 4 4 4 4 4 … 15×16 ],与预期完全一致 | | 11_reduce_scatterv | 通过(退出码 0) | rank i 输出 i+1 个元素,每个值均为 120(= 0+1+…+15 的 SUM 归约),如 rankId: 15, output: [ 120×16 ],变长数据块分发语义正确 | 通信域创建/销毁、流同步、Device 内存申请释放均无错误。 ### 复现命令 bash source /usr/local/Ascend/cann-9.3.0/set_env.sh # 需已安装同周期 A3-ops 算子包 export HCCL_HOST_SOCKET_PORT_RANGE=41000-41100 # 与其他 HCCL 业务进程共机时需指定独立端口 export HCCL_NPU_SOCKET_PORT_RANGE=42000-42100 cd examples/02_collectives/10_allgatherv && make && ./allgatherv cd ../11_reduce_scatterv && make && ./reduce_scatterv ### 回归 同环境下仓内其余同构样例(02_collectives/01~09 及 01_point_to_point/01~02,共 11 个)全部编译运行通过,输出符合预期。 ### 环境备注(供复现者参考) - toolkit 包不携带 hccl 组件,运行样例前需安装同周期对应产品型号的 ops 算子包:./Ascend-cann-A3-ops_<version>_linux-aarch64.run --install --install-path=<toolkit安装路径> - 与其他 HCCL 业务进程(如推理服务)共机运行时,默认 host 侧端口(60000)与 NPU 侧端口(16666)可能被占用,导致 HcclCommInitRootInfo 返回 HCCL_E_INTERNAL(4);需通过 HCCL_HOST_SOCKET_PORT_RANGE / HCCL_NPU_SOCKET_PORT_RANGE 为样例进程指定独立端口范围 ## 文档更新 - 新增两个样例的 README.md、README_en.md - 更新 examples/README.md、examples/README_en.md(新增两条索引) ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/hccl!3585 | 23 天前 | |
[fix] 修正接口文档参数名与返回值表缺失、examples构建脚本退出码及CMakeLists残留注释 Co-authored-by: Leewis<liwei945@huawei.com> # message auto-generated for no-merge-commit merge: !3804 merge fix/issue-844-801-823-822-docs-build into master [fix] 修正接口文档参数名与返回值表缺失、examples构建脚本退出码及CMakeLists残留注释 Created-by: Leewis Commit-by: Leewis Merged-by: cann-robot Description: ## 描述 本 PR 一次性修复 4 个已确认的 Issue(#844 #801 #823 #822),均为文档修正与构建脚本/构建配置修复,不涉及算子逻辑变更;另含两轮检视意见(bz_lee、yanzhenghang、atomgit-bot 共 5 条)的修正。 **Issue #844(HCCL_E_PARA 说明引用了不存在的参数名 count):** - zh/en 版 HcclAllGather.md、HcclAllGatherV.md: count 修正为原型实际参数名 sendCount; - 同类问题一并修复:zh/en 版 HcclReduceScatter.md、HcclReduceScatterV.md、HcclScatter.md:count 修正为实际参数名 recvCount; - 检视补充修正:zh/en 版 HcclAlltoAll.md、HcclAlltoAllV.md、HcclAlltoAllVC.md 的 HCCL_E_NOT_SUPPORT 行 dataType 修正为 sendType/recvType(该三个接口原型无 dataType 参数)。 **Issue #801(返回值表缺实际可达错误码):** - zh 14 篇 + en 14 篇(按检视意见同步补齐)接口文档返回值表在 HCCL_E_INTERNAL 后补齐 HCCL_E_UNAVAIL / HCCL_E_RUNTIME / HCCL_E_MEMORY,口径与 hcomm 仓 HcclResult 枚举说明页对齐; - HCCL_E_UNAVAIL 场景描述经检视修正:删除「图模式下」限定——TryReuseResource 允许 OPBASE 单算子模式复用 CCU 资源,HcclExecOp 中「复用线程为空」返回分支无 opMode 守卫,单算子模式同样可达,统一表述为「如CCU资源复用异常(复用线程为空、线程数超限)等」。 **Issue #823(examples/build.sh 两处缺陷):** 1. mkdir -p 创建构建目录,: > build.log 每次运行截断历史日志,消除残留记录干扰失败判定; 2. set -o pipefail,make/make test 改为 if make ... 2>&1 | tee 直接以退出码判定失败并 exit 1,编译输出完整写入 build.log; 3. 检视补充修正(失败传导契约补全):cd 失败与「无 Makefile」分支累加失败计数,循环结束后按计数 exit 1,避免未执行任何构建却返回 0; 4. 检视补充修正(行为变更声明):JOB_NUM="${JOB_NUM:--j$(nproc)}"——外部已设置 JOB_NUM 时沿用外部值,未设置时默认按 CPU 核数并行编译; 5. 统一 tee -a "${BUILD_DIR}/build.log" 引号。 注:make test 运行示例需 NPU 环境,无设备场景下脚本报错退出属预期(失败传导)。 **Issue #822(CMakeLists.txt 无效/无意义注释):** - 删除 # this is a test commit 测试提交残留注释; - 删除 HCCL_JSON 空变量死代码(空 set() 块及 install(FILES ...) 中的引用),HCCL_HEAD 安装行为不变。 **范围说明**:Issue #836(算子调用示例顺序违规)按维护者决策另行跟进,不在本 PR 范围;根 build.sh --cb_test_verify 空转问题需与 CI 环境责任田确认 PreSmoke 运行条件后单独处理(详见 #823 评论),亦不在本 PR 范围。 ## 关联的Issue - Fixes #844 - Fixes #801 - Fixes #823 - Fixes #822 ## 测试 - bash -n examples/build.sh 语法检查通过; - pre-commit(clang-format + OAT 合规)对全部改动文件运行通过; - examples/build.sh 桩 make 沙箱功能验证: - 全新环境(build/ 不存在)+ 构建成功 → 退出码 0; - make 失败 → 退出码 1,make 输出完整入日志; - make 成功 + make test 失败 → 退出码 1; - 目录不存在(cd 失败)→ 退出码 1(失败计数生效); - 目录无 Makefile → 退出码 1(失败计数生效); - 失败后再次成功 → 退出码 0,历史失败记录已截断、不残留误判; - 并行参数:默认 make 收到 -j<CPU核数>,显式 JOB_NUM=-j2 时收到 -j2; - 文档改动 grep 全量核对:参数名与 include/hccl.h 原型逐一比对,剩余 count/dataType 表述的文件均为原型真实参数,无误改; - CMakeLists.txt 改动仅为删除恒为空的变量及其引用,不影响安装产物,由 CI 流水线全量编译验证。 ## 文档更新 - docs/zh/api_ref/comm_op_interface/:14 篇返回值表补齐 3 个错误码;8 篇参数名修正(HCCL_E_PARA 的 count→sendCount/recvCount、AlltoAll 系列 HCCL_E_NOT_SUPPORT 的 dataType→sendType/recvType); - docs/en/api_ref/comm_op_interface/:14 篇返回值表补齐 3 个错误码;8 篇参数名修正(同上)。 ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/hccl!3804 | 4 天前 |
HCCL 代码示例
简体中文 | English
本目录提供了不同场景下使用 HCCL 接口实现集合通信功能的示例代码。
点对点通信
集合通信
- AllReduce
- Broadcast
- AllGather
- AllGatherV
- ReduceScatter
- ReduceScatterV
- Reduce
- AlltoAll
- AlltoAllV
- AlltoAllVC
- Scatter