[OPENMP][NVPTX]Fix PR40893: Size doesn't match for
authorAlexey Bataev <a.bataev@hotmail.com>
Wed, 13 Mar 2019 18:21:10 +0000 (18:21 +0000)
committerAlexey Bataev <a.bataev@hotmail.com>
Wed, 13 Mar 2019 18:21:10 +0000 (18:21 +0000)
commit7b3eabdcd2155ecd171ac8d80abe638dd3dc5c65
treea3bb0d99baef7ddc5896f573f2c910445a660831
parent510f26dca8a93068d5dade2ce8d57a6285d6012f
[OPENMP][NVPTX]Fix PR40893: Size doesn't match for
'_openmp_teams_reductions_buffer_$_.

nvlink does not handle weak linkage correctly, same symbols with the
different sizes are reported as erroneous though the largest size must
be chosen instead. Patch fixes this problem by using Internal linkage
instead of the Common.

llvm-svn: 356072
clang/lib/CodeGen/CGOpenMPRuntimeNVPTX.cpp
clang/test/OpenMP/nvptx_teams_reduction_codegen.cpp