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

[cherry-pick] multithread memory optimize error fix (#37894) #38737

Merged
merged 1 commit into from
Jan 12, 2022

Conversation

JZZ-NOTE
Copy link
Contributor

@JZZ-NOTE JZZ-NOTE commented Jan 6, 2022

PR types

Others

PR changes

Others

Describe

修复多线程下 createpredictor 报错问题。
问题原因:passes 是 单例,但在 memory_optimize_pass 中,graph 和 max_life_cycle 都是成员变量,成为多线程的互斥资源。

@paddle-bot-old
Copy link

paddle-bot-old bot commented Jan 6, 2022

✅ This PR's description meets the template requirements!
Please wait for other CI results.

@paddle-bot-old
Copy link

paddle-bot-old bot commented Jan 6, 2022

Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

Copy link
Contributor

@Superjomn Superjomn left a comment

Choose a reason for hiding this comment

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

LGTM

@Superjomn Superjomn merged commit 5925b82 into PaddlePaddle:release/2.2 Jan 12, 2022
@JZZ-NOTE JZZ-NOTE deleted the jzz_2.2_multithread branch March 17, 2022 09:26
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