提交 0b02a221 编写于 作者: W wangjiangb

Fix errors for high version GPU.

ISSUE=4622423

git-svn-id: https://svn.baidu.com/idl/trunk/paddle@1503 1ad973e4-5ce8-4261-8a94-b56d1f490c56
上级 6968191e
...@@ -75,12 +75,13 @@ endforeach() ...@@ -75,12 +75,13 @@ endforeach()
# So, don't set these flags here. # So, don't set these flags here.
foreach(capability 30 35 50) foreach(capability 30 35 50)
list(APPEND __arch_flags "-gencode arch=compute_${capability},code=sm_${capability}") list(APPEND __arch_flags " -gencode arch=compute_${capability},code=sm_${capability}")
endforeach() endforeach()
message(${__arch_flags})
if (CUDA_VERSION VERSION_GREATER "7.0") if (CUDA_VERSION VERSION_GREATER "7.0")
list(APPEND __arch_flags "-gencode arch=compute_52,code=sm_52") list(APPEND __arch_flags " -gencode arch=compute_52,code=sm_52")
endif() endif()
set(CUDA_NVCC_FLAGS ${__arch_flags} ${CUDA_NVCC_FLAGS})
set(CUDA_NVCC_FLAGS ${__arch_flags} ${CUDA_NVCC_FLAGS})
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册