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

[clang-tidy] No. 53,54 enable cppcoreguidelines-c-copy-assignment-signature and bugprone-use-after-move #56601

Merged
merged 1 commit into from
Aug 29, 2023

Conversation

@paddle-bot paddle-bot bot added the contributor External developers label Aug 23, 2023
@luotao1 luotao1 added the HappyOpenSource Pro 进阶版快乐开源活动,更具挑战性的任务 label Aug 24, 2023
@@ -637,6 +636,7 @@ void ProgramInterpreter::Convert(
.RecordCapturingDeviceContext(dev_ctx_);
}
#endif
vec_instruction_.emplace_back(op_idx, std::move(op_func_node), *dev_ctx_);
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

@xiaoyewww xiaoyewww Aug 24, 2023

Choose a reason for hiding this comment

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

这里为什么要调整一下顺序?

@zhangbo9674
因为开启了GPU后,op_func_node会在std::move之后调用,并且看到vec_instruction_没有在617-638这块代码里使用,所以调整了一下顺序

@luotao1 luotao1 merged commit cc9e869 into PaddlePaddle:develop Aug 29, 2023
BeingGod pushed a commit to BeingGod/Paddle that referenced this pull request Sep 9, 2023
@xiaoyewww xiaoyewww deleted the fix/clang-tidy branch May 10, 2024 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers HappyOpenSource Pro 进阶版快乐开源活动,更具挑战性的任务
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants