| Files | Last commit | Last update |
|---|---|---|
fix: 特殊编译选项改用完整标志/精确 --tiling_key= 前缀识别,避免普通参数中的子串触发调试路由 Co-authored-by: Ethan_Zou<tianjun.zou@foxmail.com> # message auto-generated for no-merge-commit merge: !11855 merge fix/b6-nn-compiler-option-substring-routing-20261013 into master fix: 特殊编译选项改用完整标志/精确 --tiling_key= 前缀识别,避免普通参数中的子串触发调试路由 Created-by: Ethan_Zou Commit-by: Ethan_Zou Merged-by: cann-robot Description: ## 描述 将普通选项、精确debug标志及tiling key解析分离,删除不可达重复分支;文件写入使用O_APPEND,保留原有权限与输出协议。 本轮直接修改并验证实际生产实现,保留仓库原有Huawei版权与CANN许可。没有替换许可证、移除来源信息、屏蔽SCA或降低门禁阈值。SCA以新源流水线实际结果为准。 ## 关联的Issue Fixes [#6591](https://gitcode.com/cann/ops-nn/issues/6591). ## 测试 实际环境:远端Ubuntu22.04.5 x86_64、Python3.12.15、Host回归pytest8.3.2及原生隔离hook固定pytest8.3.5;安装CANN9.1.0。本轮没有执行NPU算子。 - 当前实际生产模块及tests/host完整回归:5项通过,无跳过。新增用例在完整未修改的旧公开生产源上复现失败,修复后通过。 - tiling相关PR对实际生成的完整Host struct/Init进行C++17编译并执行逐字节比较,包括1/4/8/12/13字节尺寸;不代表整个SDK/NPU头编译或设备运行通过。 - Host测试已接入仓库原生pre-commit的隔离Python环境,匹配scripts及tests/host变更;并非仅作者手工执行。 - 最终修改通过正常pre-commit(含ruff/codespell/OAT及Host回归)、正常amend、干净提交树相同回归、diff检查、LFS检查及恢复bundle验证。 当前唯一源提交 60be4500a7581598175c087bd688f0b7c0972374,推送后通过/compile回查当前源CodeCheck、SCA与完整CI。旧源扫描结论不代替新源结果。 ## 文档更新 无文档接口变更;实际修复范围、Host与NPU验证边界如上。 ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他:生产结构改进、真实回归与原生门禁注册 <!-- maintenance-20261027a --> See merge request: cann/ops-nn!11855 | 13 days ago | |
fusion_pass获取npuarch整改 Co-authored-by: zhangquanxin<zhangquanxin7@h-partners.com> # message auto-generated for no-merge-commit merge: !13819 merge fix_fusion_pass into master fusion_pass获取npuarch整改 Created-by: zhangquanxin Commit-by: zhangquanxin Merged-by: cann-robot Description: ## 描述 matmul 域图融合 pass 与 infershape 的平台门控原通过 fe::PlatformInfo 的 soc_info.arch_type 判断 NPU arch,线上真机 Ascend950 环境 ini 配置无该字段,判断恒为 false,融合/infershape 平台门控失效(详见关联 Issue)。 本 MR 将 5 处判断点改为运行时 API 方式:aclplatformGetDeviceInfo(ACL_PLATFORM_NPU_ARCH, buf) 获取 arch 字符串("3510"/"9201"/"9202"),经 std::atoi 与 arch 常量数值比较,不再依赖 arch_type 字段: - matmul/common/op_graph/fusion_pass/matmul_fusion_utils_pass.cpp:IsNpuArch3510Series - matmul/flat_quant/op_host/flat_quant_infershape.cpp:IsFlatQuantMxFp4DavidSupport - matmul/rotate_quant/op_host/rotate_quant_infershape.cpp:IsRotateQuantDav3510Support - matmul/weight_quant_batch_matmul_v2/op_graph/fusion_pass/anti_quant_matmul_fusion_pass.cpp:CheckPlatform 回退段(rtGetSocSpec 第一优先保留) - matmul/transpose_batch_mat_mul/op_graph/fusion_pass/batch_matmul_to_transpose_batch_matmul_fusion_pass.cpp:GetPlatform arch 门控 配套 UT stub(tests/ut/acl_platform_stub.cpp,编进 nn_op_host_ut / nn_op_graph_ut 两个 UT 可执行):stub 内部桥接 fe::PlatformInfoManager mock 数据源,测试 mock 代码零改动,单测语义与修复前一致;生产 so 符号仍走真库,线上行为不受影响。 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/8308 ## 测试 - 二级冒烟 - ophost UT:881/881 全绿(含 rotate_quant/flat_quant infershape 套件) - opgraph UT:537/537 全绿(含 FusedMatMul/TBMM/BMM2Mul 融合 pass 套件) - 生产构建:bash build.sh --opgraph / -u --ophost 均零 error - nm 验证:两个 UT 可执行含 stub T 符号,生产 libopgraph_nn.so 保持 U(真库解析) ## 文档更新 无 ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!13819 | 13 days ago | |
修正UT依赖安装与AddExample调测、安装指引 Co-authored-by: yangyang016<yangyang306@hisilicon.com> # message auto-generated for no-merge-commit merge: !11986 merge master into master 修正UT依赖安装与AddExample调测、安装指引 Created-by: yangyang016 Commit-by: yangyang016 Merged-by: cann-robot Description: ## 描述 修复安装、UT依赖和AddExample调测指引中的不一致,确保文档与当前代码及依赖配置对应。 - tests/requirements.txt 新增 -r ../requirements.txt,使UT依赖安装统一包含项目根目录的依赖及版本约束。 - 安装文档区分仅编译与执行UT两种场景,明确UT依赖已包含根目录依赖,无需重复安装。 - 更新AddExample的printf示例,移除与当前实现不一致的旧Tiling代码,明确在 Init 中的插入位置,使用 AscendC::printf 和与 int64_t blockLength_ 对应的 %lld。 - 补充自定义算子包安装时报 shared library validation failed 的处理说明:确认CANN版本与构建环境兼容后,可按需使用 --force 跳过共享库依赖检查;同时说明运行时加载失败风险,不建议默认使用。 ## 关联的Issue 关联Issue #6699:https://gitcode.com/cann/ops-nn/issues/6699 ## 测试 - 已执行 git diff --check HEAD^ HEAD,通过。 - 已静态核对UT依赖引用路径,以及printf示例中的变量类型与插入位置。 - 未执行实际依赖安装、CANN环境下的编译、UT及算子包安装验证,相关验证待补充。 ## 文档更新 - docs/QUICKSTART.md:更新printf调测示例,补充安装共享库校验失败时的处理说明。 - docs/zh/install/quick_install.md:区分编译依赖与UT依赖的安装场景。 - docs/zh/install/compile.md:明确UT依赖包含根目录依赖约束。 ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!11986 | 1 month ago |
| Files | Last commit | Last update |
|---|---|---|
| 13 days ago | ||
| 13 days ago | ||
| 1 month ago |