-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
[Werror] fix Werror-maybe-uninitialized in roi_align_grad_kernel #51633
Conversation
你的PR提交成功,感谢你对开源项目的贡献! |
❌ The PR is not created using PR's template. You can refer to this Demo. |
@zhiqiu CI都过了 |
@@ -81,7 +81,7 @@ void RoiAlignGradKernel(const Context& dev_ctx, | |||
int sampling_ratio, | |||
bool aligned, | |||
DenseTensor* dx) { | |||
auto in_dims = x.dims(); | |||
auto in_dims = phi::vectorize<int>(x.dims()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
是不是改成const auto&也可以?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
好的,我本地试一下
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zhiqiu 确实可以!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
PR types
Bug fixes
PR changes
Others
Describe
类似于 #51608 ,参考 #51605 #47143
修复 GCC 9.4.0 由于-Werror=maybe-uninitialized 引起的编译失败