已合并
Fix mfusion FX-to-torch-mlir conversion for torch.ops.higher_order.run_and_save_rng_state #38582
shuqian0创建于 6月15日
Fix mfusion FX-to-torch-mlir conversion for torch.ops.higher_order.run_and_save_rng_state #38582
已合并
Pull Request已成功合入, 合并人@ascend-robot
(感谢 shuqian0 的贡献)ascend-robot
6月15日 评论:
6月15日 评论:
6月15日 添加了label:ascend-cla/yes
ascend-robot
6月15日 评论:
6月15日 评论:
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 |
|---|---|---|
| test | ✅ zichun_ye, hbhu_bin (2/2) | ✅ zichun_ye (1/1) |
| torch_npu/_inductor | ✅ zichun_ye, hbhu_bin (2/2) | ✅ zichun_ye (1/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
shuqian0, thanks for your pull request. All authors of the commits have signed the CLA. 👍


6月15日 添加了label:needs-issue
此处折叠了68条消息 查看更多
6月23日 添加了label:approved
6月23日 添加了label:lgtm
6月23日 合入了pull request
ascend-robot
6月23日 评论:
6月23日 评论:
流水线 pytorch_gitcode_PR_multiVersion#11110 [ commitID:1c2ed023 ] 已完成


【合入来源】
【修改方案】
[Feature]: 26.1.0版本图模式功能增强
修复 mfusion 中
torch.ops.higher_order.run_and_save_rng_state算子从FX 到 torch-mlir 的转换报错。失败的案例是:
run_and_save_rng_state = torch.ops.higher_order.run_and_save_rng_state(...) rng_state = run_and_save_rng_state[0] dropout_out = run_and_save_rng_state[1][0]torch-mlir 不直接实现这个 HOP(Higher Order Primitive),其导入器将多输出操作建模为扁平化的 MLIR 结果。本PR将不支持的目标通过 mfusion opaque 自定义操作路由,同时保留足够的结构以便在 MLIR 往返转换后重建原始 FX 图。
变更内容
_import_hop。opaque_registry.Payload中记录每个叶子结果的路径。(Tensor,))添加明确的错误提示,这种输出无法在不改变语义的情况下由当前的扁平化方案表示。【资料变更】
【接口变更】
【功能验证】
【CheckList】