CARVIEW |
Navigation Menu
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
[DCU]Fix build error on rocm5.7 #63738
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
Conversation
* add rocm_path to cmake_prefix_path * rm ambiguous apt because rocm has implemented Signed-off-by: jiajuku <jiajuku12@163.com>
* change expression of Xcompiler since clang17 only support "-Xcompiler xxx" instead of "-Xcompiler=xxx" * clang17 check warning mre strictly Signed-off-by: jiajuku <jiajuku12@163.com>
Signed-off-by: jiajuku <jiajuku12@163.com>
rocm5 requires the include path: $ROCM_PATH/include Signed-off-by: jiajuku <jiajuku12@163.com>
你的PR提交成功,感谢你对开源项目的贡献! |
Signed-off-by: jiajuku <jiajuku12@163.com>
@luotao1 关于CI中没有通过的部分,都是在编译cuda的是时候,报出: 但是我本地使用nvidia/cuda:11.6.1-cudnn8-devel-ubuntu20.04镜像编译的时候,并没有报出这个错误来,请问你们的环境有什么不一样的地方吗? |
@qili93 有什么更新吗? |
cmake/hip.cmake
Outdated
@@ -68,7 +69,7 @@ find_hip_version(${HIP_PATH}/include/hip/hip_version.h) | |||
|
|||
macro(find_package_and_include PACKAGE_NAME) | |||
find_package("${PACKAGE_NAME}" REQUIRED) | |||
include_directories("${ROCM_PATH}/${PACKAGE_NAME}/include") | |||
# include_directories("${ROCM_PATH}/${PACKAGE_NAME}/include") |
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.
这个是要删除?可以把注释去掉
@onepick 当前代码的修改无法通过PR-CI-BUILD的CI,建议先修复下现有的CUDA编译问题,保障代码兼容性,谢谢! |
看了下日志里面显示的CUDA版本是
建议可以试试看 registry.baidubce.com/paddlepaddle/paddle:latest-dev-cuda11.8-cudnn8.6-trt8.5-gcc82 的镜像本地编译看下。也辛苦 @risemeup1 确认下 https://xly.bce.baidu.com/paddlepaddle/paddle/newipipe/detail/10589314/job/26072763 这流水线使用的基础编译镜像是什么。 |
Sorry to inform you that 475d533's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually. |
This reverts commit 2b3bb69.
* change build option "-Xcompiler" expression, since clang17 reuqire "-Xcompiler xxx" instead of "-Xcompiler=xxx" * remove Werror from HIP_HCC_FLAGS since clang17 check more strictly. Signed-off-by: onepick <juku.jia@hygon.cn>
@qili93 fail的CI部分没任何错误提示? |
2024-05-02 09:52:08 **************** |
got it. @zhiqiu @luotao1 编译中的warning过多,主要是因为rocm5.7升级编译器到clang17, clang17的检测更加智能/更加严格,所以更多的warning暴露了出来 |
Signed-off-by: onepick <jiauku@hygon.cn>
* sign-compare * bitwise-instead-of-logical * unknown-warning-option * unused-lambda-capture * unused-variable * unused-but-set-variable * reorder-ctor * deprecated-copy-with-user-provided-copy * unused-local-typedef * missing-braces * sometimes-uninitialized Signed-off-by: onepick <jiauku@hygon.cn>
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 for flags.cmake
else() | ||
set(SAFE_GPU_COMMON_FLAGS | ||
"${SAFE_GPU_COMMON_FLAGS} -Xcompiler=\"${flag_name}\"") | ||
endif() |
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.
这里只对 WITH_ROCM 下的编译flag进行修改,不影响 GPU 编译的flag,请 @zhiqiu approve。
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
* [ROCM]Add patch for warprnnt/warpctc * add rocm_path to cmake_prefix_path * rm ambiguous apt because rocm has implemented Signed-off-by: jiajuku <jiajuku12@163.com> * [ROCM] fix build error on rocm5.7 * change expression of Xcompiler since clang17 only support "-Xcompiler xxx" instead of "-Xcompiler=xxx" * clang17 check warning mre strictly Signed-off-by: jiajuku <jiajuku12@163.com> * [ROCM] add dependent rocm lib Signed-off-by: jiajuku <jiajuku12@163.com> * [ROCM]fix build warning rocm5 requires the include path: $ROCM_PATH/include Signed-off-by: jiajuku <jiajuku12@163.com> * clean code style issue Signed-off-by: jiajuku <jiajuku12@163.com> * Revert "[ROCM] fix build error on rocm5.7" This reverts commit 2b3bb69. * [ROCm]:support rocm 57 * change build option "-Xcompiler" expression, since clang17 reuqire "-Xcompiler xxx" instead of "-Xcompiler=xxx" * remove Werror from HIP_HCC_FLAGS since clang17 check more strictly. Signed-off-by: onepick <juku.jia@hygon.cn> * Fix build error Xcompiler expression for clang17 Signed-off-by: onepick <jiauku@hygon.cn> * Fix build warning * sign-compare * bitwise-instead-of-logical * unknown-warning-option * unused-lambda-capture * unused-variable * unused-but-set-variable * reorder-ctor * deprecated-copy-with-user-provided-copy * unused-local-typedef * missing-braces * sometimes-uninitialized Signed-off-by: onepick <jiauku@hygon.cn> --------- Signed-off-by: jiajuku <jiajuku12@163.com> Signed-off-by: onepick <juku.jia@hygon.cn> Signed-off-by: onepick <jiauku@hygon.cn> Co-authored-by: onepick <juku.jia@hygon.cn> Co-authored-by: onepick <jiauku@hygon.cn>
PR Category
Others
PR Types
Bug fixes
Description
fix build error and warning on rocm5.7