Pull Request has been successfully merged by CANN-robot.
(Thank you for huanyongben's contribution.)变更摘要
该 PR 主要删除了 pypto_pro 中未被使用、且缺乏后端实现的 tensor.* 算子体系(C++ 与 Python 两侧),并移除了 OpConversionRegistry 中 tensor.* -> block.* 的默认降级转换;同时统一了编译错误首行中枚举名的渲染格式,并在 runtime pipeline 校验中补充了跨核缓冲 tile 数量的检查。
主要改动
- 删除
tensor.*算子实现与注册: 删除framework/src/interface/ir/op/tensor_ops/下的elementwise.cpp、matmul.cpp、memory.cpp、reduction.cpp、transform.cpp、unary.cpp及 Python 的python/pypto_pro/ir/op/tensor_ops.py,移除其中全部REGISTER_OP("tensor.*")注册与register_table项,并从op/__init__.py的__all__与导入中移除tensor命名空间。 - 移除默认算子转换规则:
OpConversionRegistry::OpConversionRegistry()改为= default,不再注册tensor.add -> block.add等默认映射,转换改由使用方通过RegisterSimple/RegisterCustom或register_op_conversion自行注册。 - 统一错误枚举名渲染格式:
framework/src/interface/pypto_pro/error.cpp新增EnumClassName与BareEnumName,ErrHead输出ExternalError::/InternalError::前缀;python/pypto_pro/_errors.py的_first_line相应按0xF0000掩码派生相同前缀,使两侧格式一致。 - pipeline 同步校验新增 tile 数量检查:
validate_sync增加schedule参数并新增_check_slot_counts,按生产者与消费者所在 stage 的距离校验跨核缓冲所需 tile 数;_check_cross_core_users新增跨核缓冲必须交给紧邻后一 stage 的校验。 - 文档与测试同步更新: 注释与文档示例由
tensor.add等改为block.add等,测试用例改用block.*、ptr.make_tensor、make_tile等算子,并删除test_tensor_ops相关测试。


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


compile


| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


compile


| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


/approve


/approve
/lgtm


The following users do not have permission to comment /lgtm or /approve on any module in this PR:
/approve: gaoxiang618


删除废弃的tensor op相关代码