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

Add cuda compiled arch check #49592

Merged
merged 2 commits into from
Jan 10, 2023
Merged

Add cuda compiled arch check #49592

merged 2 commits into from
Jan 10, 2023

Conversation

MARD1NO
Copy link
Contributor

@MARD1NO MARD1NO commented Jan 6, 2023

PR types

New features

PR changes

Others

Describe

在初始化的时候检查编译的cuda arch和运行时的cuda arch是否一致

image

@paddle-bot
Copy link

paddle-bot bot commented Jan 6, 2023

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

@@ -7,11 +7,117 @@ if(WITH_XBYAK)
list(APPEND BACKENDS_DEPS xbyak)
endif()

function(get_compiled_arch out_variable)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

cuda.cmake里有类似的function,但是拼接的字符串不是这里需要的,因此这里copy了一份删除了不必要的东西,改了下拼接格式,最后大概会是返回 80,86 这样的字符串

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

Choose a reason for hiding this comment

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

已修改cuda.cmake进行复用,感谢review

@MARD1NO MARD1NO marked this pull request as ready for review January 6, 2023 02:47
Copy link
Contributor

@jiweibo jiweibo left a comment

Choose a reason for hiding this comment

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

LGTM

@jiweibo jiweibo merged commit c0d6ec6 into PaddlePaddle:develop Jan 10, 2023
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.

3 participants