Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PIR] Add num_ops() func for block and program #61046

Merged
merged 9 commits into from
Jan 25, 2024

Conversation

chen2016013
Copy link
Contributor

@chen2016013 chen2016013 commented Jan 23, 2024

PR types

Others

PR changes

Others

Description

Pcard-67164
Add num_ops() func for block and program

Copy link

paddle-bot bot commented Jan 23, 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.

Copy link
Contributor

@yuanlehome yuanlehome left a comment

Choose a reason for hiding this comment

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

带控制流的如何处理呢?num_ops接口是否应该对控制流内op计数呢

paddle/fluid/pybind/pir.cc Outdated Show resolved Hide resolved
paddle/pir/core/block.h Outdated Show resolved Hide resolved
paddle/pir/core/block.h Outdated Show resolved Hide resolved
@chen2016013
Copy link
Contributor Author

带控制流的如何处理呢?num_ops接口是否应该对控制流内op计数呢

visitor.cc的Walk方法实现了递归访问,已经实现了对控制流内op计数

@PaddlePaddle PaddlePaddle deleted a comment from paddle-bot bot Jan 23, 2024
zhangbo9674
zhangbo9674 previously approved these changes Jan 23, 2024
@chen2016013 chen2016013 changed the title [PIR] Add GetOpNum func for block and program [PIR] Add num_ops() func for block and program Jan 24, 2024
@chen2016013 chen2016013 merged commit 5ad19e5 into PaddlePaddle:develop Jan 25, 2024
30 checks passed
eee4017 pushed a commit to eee4017/Paddle that referenced this pull request Jan 30, 2024
* add GetOpNum func for block and program

* update

* open test

* update

* add IR_API & delete detail namespace

* fix

* fix

* Update visitors.h
@chen2016013 chen2016013 deleted the test0122 branch February 21, 2024 09:31
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.

None yet

3 participants