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

fix structure infos conflict in static return_list mode #43291

Merged

Conversation

heavengate
Copy link
Contributor

@heavengate heavengate commented Jun 7, 2022

PR types

Bug fixes

PR changes

Others

Describe

fix structure infos conflict in static return_list mode

origin code as follows work as read -> copy -> write, if _sturcture_infos.append called in thread in the read -> copy -> write workflow, may incur conflict and make data of _sturcture_infos wrong,change to use pop which is thread-safe.

self._structure_infos = self._structure_infos[len(self._places):]

and update unit tests to cover this case

@paddle-bot-old
Copy link

paddle-bot-old bot commented Jun 7, 2022

你的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.

@PaddlePaddle PaddlePaddle locked and limited conversation to collaborators Jun 9, 2022
@PaddlePaddle PaddlePaddle unlocked this conversation Jun 9, 2022
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