Skip to content

Conversation

@liuruyan
Copy link
Contributor

PR Category

CINN

PR Types

New features

Description

  1. Change Expr to IndexExpr in func of IterExpr.
  2. Add TryFuseSameSource func for simplify the iter when comes from same source.
(i_j_k_fused / 16 / 2 * 32 + i_j_k_fused / 16 % 2 * 16 +  i_j_k_fused % 16) / 8
=====>
i_j_k_fused / 8
  1. Add comment for TryFuse and TryFuseSameSource.
  2. Add Hash func for IndexExpr.

Pcard-67164

@paddle-bot
Copy link

paddle-bot bot commented Oct 15, 2024

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

Comment on lines +119 to +120
std::optional<ir::IndexExpr> TryFuse(const ir::IndexExpr& expr);
std::optional<ir::IndexExpr> TryFuseSameSource(const ir::IndexExpr& expr);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这两个函数的注释加到头文件里,具体说明下分别在什么情况使用

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

收到,下一个PR中将进行调整。

@zyfncg zyfncg merged commit abebc8e into PaddlePaddle:develop Oct 16, 2024
27 checks passed
@liuruyan liuruyan deleted the TryFuseSameSource branch October 16, 2024 09:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants